vxe-pc-ui 4.15.2 → 4.15.3

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 (127) hide show
  1. package/dist/all.esm.js +774 -211
  2. package/es/backtop/src/backtop.js +2 -1
  3. package/es/button/src/button.js +3 -2
  4. package/es/calendar/src/calendar.js +2 -1
  5. package/es/cascader/src/cascader.js +2 -1
  6. package/es/checkbox/src/group.js +5 -1
  7. package/es/date-panel/src/util.js +27 -16
  8. package/es/date-picker/src/date-picker.js +572 -74
  9. package/es/date-range-picker/src/date-range-picker.js +3 -2
  10. package/es/drawer/src/drawer.js +2 -0
  11. package/es/form/render/index.js +3 -2
  12. package/es/form/src/form.js +6 -5
  13. package/es/form/src/itemInfo.js +6 -5
  14. package/es/input/src/input.js +2 -1
  15. package/es/menu/src/menu.js +2 -1
  16. package/es/modal/src/modal.js +5 -2
  17. package/es/pager/src/pager.js +4 -3
  18. package/es/radio/src/group.js +5 -1
  19. package/es/select/src/select.js +25 -20
  20. package/es/splitter/src/splitter.js +7 -6
  21. package/es/table-select/src/table-select.js +21 -16
  22. package/es/tabs/src/tabs.js +4 -3
  23. package/es/textarea/src/textarea.js +2 -1
  24. package/es/tree/src/tree.js +3 -2
  25. package/es/tree-select/src/tree-select.js +2 -1
  26. package/es/ui/index.js +1 -1
  27. package/es/ui/src/log.js +7 -1
  28. package/es/upload/src/upload.js +12 -3
  29. package/lib/backtop/src/backtop.js +5 -2
  30. package/lib/backtop/src/backtop.min.js +1 -1
  31. package/lib/button/src/button.js +4 -1
  32. package/lib/button/src/button.min.js +1 -1
  33. package/lib/calendar/src/calendar.js +4 -1
  34. package/lib/calendar/src/calendar.min.js +1 -1
  35. package/lib/cascader/src/cascader.js +4 -1
  36. package/lib/cascader/src/cascader.min.js +1 -1
  37. package/lib/checkbox/src/group.js +5 -1
  38. package/lib/checkbox/src/group.min.js +1 -1
  39. package/lib/date-panel/src/util.js +37 -19
  40. package/lib/date-panel/src/util.min.js +1 -1
  41. package/lib/date-picker/src/date-picker.js +620 -77
  42. package/lib/date-picker/src/date-picker.min.js +1 -1
  43. package/lib/date-range-picker/src/date-range-picker.js +4 -1
  44. package/lib/date-range-picker/src/date-range-picker.min.js +1 -1
  45. package/lib/drawer/src/drawer.js +2 -0
  46. package/lib/drawer/src/drawer.min.js +1 -1
  47. package/lib/form/render/index.js +4 -1
  48. package/lib/form/render/index.min.js +1 -1
  49. package/lib/form/src/form.js +8 -4
  50. package/lib/form/src/form.min.js +1 -1
  51. package/lib/form/src/itemInfo.js +7 -4
  52. package/lib/form/src/itemInfo.min.js +1 -1
  53. package/lib/index.umd.js +847 -177
  54. package/lib/index.umd.min.js +1 -1
  55. package/lib/input/src/input.js +6 -3
  56. package/lib/input/src/input.min.js +1 -1
  57. package/lib/menu/src/menu.js +4 -1
  58. package/lib/menu/src/menu.min.js +1 -1
  59. package/lib/modal/src/modal.js +8 -2
  60. package/lib/modal/src/modal.min.js +1 -1
  61. package/lib/pager/src/pager.js +6 -2
  62. package/lib/pager/src/pager.min.js +1 -1
  63. package/lib/radio/src/group.js +5 -1
  64. package/lib/radio/src/group.min.js +1 -1
  65. package/lib/select/src/select.js +27 -20
  66. package/lib/select/src/select.min.js +1 -1
  67. package/lib/splitter/src/splitter.js +12 -8
  68. package/lib/splitter/src/splitter.min.js +1 -1
  69. package/lib/table-select/src/table-select.js +22 -15
  70. package/lib/table-select/src/table-select.min.js +1 -1
  71. package/lib/tabs/src/tabs.js +7 -3
  72. package/lib/tabs/src/tabs.min.js +1 -1
  73. package/lib/textarea/src/textarea.js +4 -1
  74. package/lib/textarea/src/textarea.min.js +1 -1
  75. package/lib/tree/src/tree.js +7 -4
  76. package/lib/tree/src/tree.min.js +1 -1
  77. package/lib/tree-select/src/tree-select.js +7 -3
  78. package/lib/tree-select/src/tree-select.min.js +1 -1
  79. package/lib/ui/index.js +1 -1
  80. package/lib/ui/index.min.js +1 -1
  81. package/lib/ui/src/log.js +8 -1
  82. package/lib/ui/src/log.min.js +1 -1
  83. package/lib/upload/src/upload.js +20 -3
  84. package/lib/upload/src/upload.min.js +1 -1
  85. package/package.json +1 -1
  86. package/packages/backtop/src/backtop.ts +3 -1
  87. package/packages/button/src/button.ts +4 -2
  88. package/packages/calendar/src/calendar.ts +3 -1
  89. package/packages/cascader/src/cascader.ts +3 -1
  90. package/packages/checkbox/src/group.ts +6 -2
  91. package/packages/date-panel/src/util.ts +28 -16
  92. package/packages/date-picker/src/date-picker.ts +583 -75
  93. package/packages/date-range-picker/src/date-range-picker.ts +4 -2
  94. package/packages/drawer/src/drawer.ts +2 -0
  95. package/packages/form/render/index.ts +4 -2
  96. package/packages/form/src/form.ts +7 -5
  97. package/packages/form/src/itemInfo.ts +7 -5
  98. package/packages/input/src/input.ts +3 -1
  99. package/packages/menu/src/menu.ts +3 -1
  100. package/packages/modal/src/modal.ts +6 -2
  101. package/packages/pager/src/pager.ts +5 -3
  102. package/packages/radio/src/group.ts +6 -2
  103. package/packages/select/src/select.ts +29 -22
  104. package/packages/splitter/src/splitter.ts +8 -6
  105. package/packages/table-select/src/table-select.ts +24 -17
  106. package/packages/tabs/src/tabs.ts +5 -3
  107. package/packages/textarea/src/textarea.ts +3 -1
  108. package/packages/tree/src/tree.ts +4 -2
  109. package/packages/tree-select/src/tree-select.ts +3 -1
  110. package/packages/ui/src/log.ts +7 -0
  111. package/packages/upload/src/upload.ts +14 -3
  112. package/types/components/date-picker.d.ts +14 -6
  113. package/types/components/drawer.d.ts +2 -0
  114. package/types/components/modal.d.ts +2 -0
  115. package/types/components/upload.d.ts +28 -1
  116. /package/es/icon/{iconfont.1781753592499.ttf → iconfont.1781852740683.ttf} +0 -0
  117. /package/es/icon/{iconfont.1781753592499.woff → iconfont.1781852740683.woff} +0 -0
  118. /package/es/icon/{iconfont.1781753592499.woff2 → iconfont.1781852740683.woff2} +0 -0
  119. /package/es/{iconfont.1781753592499.ttf → iconfont.1781852740683.ttf} +0 -0
  120. /package/es/{iconfont.1781753592499.woff → iconfont.1781852740683.woff} +0 -0
  121. /package/es/{iconfont.1781753592499.woff2 → iconfont.1781852740683.woff2} +0 -0
  122. /package/lib/icon/style/{iconfont.1781753592499.ttf → iconfont.1781852740683.ttf} +0 -0
  123. /package/lib/icon/style/{iconfont.1781753592499.woff → iconfont.1781852740683.woff} +0 -0
  124. /package/lib/icon/style/{iconfont.1781753592499.woff2 → iconfont.1781852740683.woff2} +0 -0
  125. /package/lib/{iconfont.1781753592499.ttf → iconfont.1781852740683.ttf} +0 -0
  126. /package/lib/{iconfont.1781753592499.woff → iconfont.1781852740683.woff} +0 -0
  127. /package/lib/{iconfont.1781753592499.woff2 → iconfont.1781852740683.woff2} +0 -0
package/lib/index.umd.js CHANGED
@@ -4646,7 +4646,13 @@ function checkDynamic() {
4646
4646
  }
4647
4647
  ;// ./packages/ui/src/log.ts
4648
4648
 
4649
- const log_version = `ui v${"4.15.2"}`;
4649
+ const log_version = `ui v${"4.15.3"}`;
4650
+ function createComponentLog(name) {
4651
+ return {
4652
+ warnLog: log.create('warn', `${log_version} ${name}`),
4653
+ errLog: log.create('error', `${log_version} ${name}`)
4654
+ };
4655
+ }
4650
4656
  const warnLog = log.create('warn', log_version);
4651
4657
  const errLog = log.create('error', log_version);
4652
4658
  ;// ./packages/ui/index.ts
@@ -4654,7 +4660,7 @@ const errLog = log.create('error', log_version);
4654
4660
 
4655
4661
 
4656
4662
 
4657
- const ui_version = "4.15.2";
4663
+ const ui_version = "4.15.3";
4658
4664
  VxeUI.uiVersion = ui_version;
4659
4665
  VxeUI.dynamicApp = dynamicApp;
4660
4666
  function config(options) {
@@ -7818,6 +7824,9 @@ const Tooltip = VxeTooltip;
7818
7824
 
7819
7825
 
7820
7826
 
7827
+ const {
7828
+ warnLog: button_warnLog
7829
+ } = createComponentLog('button');
7821
7830
  const VxeButtonComponent = defineVxeComponent({
7822
7831
  name: 'VxeButton',
7823
7832
  props: {
@@ -8615,7 +8624,7 @@ const VxeButtonComponent = defineVxeComponent({
8615
8624
  $xeButton.renderVN = renderVN;
8616
8625
  (0,external_commonjs_vue_commonjs2_vue_root_Vue_.onMounted)(() => {
8617
8626
  if (props.type === 'text') {
8618
- warnLog('vxe.error.delProp', ['[button] type=text', 'mode=text']);
8627
+ button_warnLog('vxe.error.delProp', ['type=text', 'mode=text']);
8619
8628
  }
8620
8629
  globalEvents.on($xeButton, 'mousewheel', handleGlobalMousewheelEvent);
8621
8630
  globalEvents.on($xeButton, 'mousedown', handleGlobalMousedownEvent);
@@ -8655,6 +8664,9 @@ const Button = VxeButton;
8655
8664
 
8656
8665
 
8657
8666
 
8667
+ const {
8668
+ errLog: backtop_errLog
8669
+ } = createComponentLog('backtop');
8658
8670
  function createInternalData() {
8659
8671
  return {
8660
8672
  targetEl: null
@@ -8857,13 +8869,13 @@ function createReactData() {
8857
8869
  } = props;
8858
8870
  if (!target) {
8859
8871
  removeScrollEvent();
8860
- errLog('vxe.error.reqProp', ['target']);
8872
+ backtop_errLog('vxe.error.reqProp', ['target']);
8861
8873
  return;
8862
8874
  }
8863
8875
  if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isString(target)) {
8864
8876
  const tEl = document.querySelector(target);
8865
8877
  if (!tEl) {
8866
- errLog('vxe.error.errProp', [`target=${target}`, 'body']);
8878
+ backtop_errLog('vxe.error.errProp', [`target=${target}`, 'body']);
8867
8879
  }
8868
8880
  const {
8869
8881
  targetEl
@@ -9379,6 +9391,24 @@ const ButtonGroup = VxeButtonGroup;
9379
9391
  /* harmony default export */ var packages_button_group = (VxeButtonGroup);
9380
9392
  ;// ./packages/date-panel/src/util.ts
9381
9393
 
9394
+ function getChunkDefaultNum(selectKey) {
9395
+ const currDate = new Date();
9396
+ switch (selectKey) {
9397
+ case 'y':
9398
+ return currDate.getFullYear();
9399
+ case 'M':
9400
+ return currDate.getMonth() + 1;
9401
+ case 'd':
9402
+ return currDate.getDate();
9403
+ case 'H':
9404
+ return currDate.getHours();
9405
+ case 'm':
9406
+ return currDate.getMinutes();
9407
+ case 's':
9408
+ return currDate.getSeconds();
9409
+ }
9410
+ return 0;
9411
+ }
9382
9412
  function hasTimestampValueType(valueFormat) {
9383
9413
  return valueFormat === 'timestamp';
9384
9414
  }
@@ -9399,18 +9429,6 @@ function handleValueFormat(type, valueFormat) {
9399
9429
  }
9400
9430
  return 'yyyy-MM-dd';
9401
9431
  }
9402
- function handleInputFormat(type, inputFormat) {
9403
- if (inputFormat) {
9404
- return inputFormat;
9405
- }
9406
- if (type === 'time') {
9407
- return 'HH:mm:ss';
9408
- }
9409
- if (type === 'datetime') {
9410
- return 'yyyy-MM-dd HH:mm:ss';
9411
- }
9412
- return 'yyyy-MM-dd';
9413
- }
9414
9432
  function toStringTimeDate(str) {
9415
9433
  const rest = new Date(2e3, 0, 1);
9416
9434
  if (str) {
@@ -9451,7 +9469,7 @@ function getDateQuarter(date) {
9451
9469
  }
9452
9470
  return 4;
9453
9471
  }
9454
- const parseDateValue = (val, type, options) => {
9472
+ function parseDateValue(val, type, options) {
9455
9473
  const {
9456
9474
  valueFormat
9457
9475
  } = options;
@@ -9468,7 +9486,7 @@ const parseDateValue = (val, type, options) => {
9468
9486
  return external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toStringDate(val, valueFormat);
9469
9487
  }
9470
9488
  return null;
9471
- };
9489
+ }
9472
9490
  const parseDateString = (val, type, options) => {
9473
9491
  const dValue = parseDateValue(val, type, options);
9474
9492
  return dValue ? external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toDateString(dValue, options.valueFormat) : '';
@@ -9620,9 +9638,20 @@ function getRangeDateByCode(code, val, type, options) {
9620
9638
  /**
9621
9639
  * 判断周的年份是否跨年
9622
9640
  */
9623
- const checkWeekOfsetYear = (W, M) => {
9641
+ function checkWeekOfsetYear(W, M) {
9624
9642
  return `${W}` === '1' && `${M}` === '12';
9625
- };
9643
+ }
9644
+ function isAllSameChar(str, char) {
9645
+ if (str.length === 0) {
9646
+ return false;
9647
+ }
9648
+ for (let i = 0; i < str.length; i++) {
9649
+ if (str[i] !== char) {
9650
+ return false;
9651
+ }
9652
+ }
9653
+ return true;
9654
+ }
9626
9655
  ;// ./packages/calendar/src/calendar.ts
9627
9656
 
9628
9657
 
@@ -9639,6 +9668,9 @@ const checkWeekOfsetYear = (W, M) => {
9639
9668
 
9640
9669
 
9641
9670
 
9671
+ const {
9672
+ errLog: calendar_errLog
9673
+ } = createComponentLog('calendar');
9642
9674
  const {
9643
9675
  menus: calendar_menus,
9644
9676
  getConfig: calendar_getConfig,
@@ -11027,7 +11059,7 @@ const {
11027
11059
  } = props;
11028
11060
  const VxeUIContextMenu = VxeUI.getComponent('VxeContextMenu');
11029
11061
  if (menuConfig && !VxeUIContextMenu) {
11030
- errLog('vxe.error.reqComp', ['vxe-context-menu']);
11062
+ calendar_errLog('vxe.error.reqComp', ['vxe-context-menu']);
11031
11063
  }
11032
11064
  dateOpenPanel();
11033
11065
  });
@@ -12365,6 +12397,9 @@ function toFloatValueFixed(inputValue, type, digitsValue, roundingMode) {
12365
12397
 
12366
12398
 
12367
12399
 
12400
+ const {
12401
+ warnLog: input_warnLog
12402
+ } = createComponentLog('input');
12368
12403
  /* harmony default export */ var input = (defineVxeComponent({
12369
12404
  name: 'VxeInput',
12370
12405
  props: {
@@ -15125,11 +15160,11 @@ function toFloatValueFixed(inputValue, type, digitsValue, roundingMode) {
15125
15160
  type
15126
15161
  } = props;
15127
15162
  if (['date', 'time', 'datetime', 'week', 'month', 'quarter', 'year'].includes(type)) {
15128
- warnLog('vxe.error.useNew', [`<vxe-input type="${type}" ... />`, `<vxe-date-picker type="${type}" ... />`]);
15163
+ input_warnLog('vxe.error.useNew', [`<vxe-input type="${type}" ... />`, `<vxe-date-picker type="${type}" ... />`]);
15129
15164
  } else if (['number', 'integer', 'float'].includes(type)) {
15130
- warnLog('vxe.error.useNew', [`<vxe-input type="${type}" ... />`, `<vxe-number-input type="${type}" ... />`]);
15165
+ input_warnLog('vxe.error.useNew', [`<vxe-input type="${type}" ... />`, `<vxe-number-input type="${type}" ... />`]);
15131
15166
  } else if (['password'].includes(type)) {
15132
- warnLog('vxe.error.useNew', [`<vxe-input type="${type}" ... />`, '<vxe-password-input ... />']);
15167
+ input_warnLog('vxe.error.useNew', [`<vxe-input type="${type}" ... />`, '<vxe-password-input ... />']);
15133
15168
  }
15134
15169
  const inputElem = refInputTarget.value;
15135
15170
  if (inputElem) {
@@ -15180,6 +15215,9 @@ function toFloatValueFixed(inputValue, type, digitsValue, roundingMode) {
15180
15215
 
15181
15216
 
15182
15217
 
15218
+ const {
15219
+ errLog: cascader_errLog
15220
+ } = createComponentLog('cascader');
15183
15221
  /**
15184
15222
  * 生成节点的唯一主键
15185
15223
  */
@@ -17096,7 +17134,7 @@ function cascader_createInternalData() {
17096
17134
  loadData(props.options || []);
17097
17135
  (0,external_commonjs_vue_commonjs2_vue_root_Vue_.onMounted)(() => {
17098
17136
  if (props.filterable) {
17099
- errLog('vxe.error.notProp', ['filterable']);
17137
+ cascader_errLog('vxe.error.notProp', ['filterable']);
17100
17138
  }
17101
17139
  globalEvents.on($xeCascader, 'mousewheel', handleGlobalMousewheelEvent);
17102
17140
  globalEvents.on($xeCascader, 'mousedown', handleGlobalMousedownEvent);
@@ -17504,6 +17542,9 @@ const CheckboxButton = VxeCheckboxButton;
17504
17542
 
17505
17543
 
17506
17544
 
17545
+ function group_createReactData() {
17546
+ return {};
17547
+ }
17507
17548
  function group_createInternalData() {
17508
17549
  return {
17509
17550
  // isLoaded: false
@@ -17542,7 +17583,7 @@ function group_createInternalData() {
17542
17583
  const $xeForm = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.inject)('$xeForm', null);
17543
17584
  const formItemInfo = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.inject)('xeFormItemInfo', null);
17544
17585
  const xID = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().uniqueId();
17545
- const reactData = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.reactive)({});
17586
+ const reactData = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.reactive)(group_createReactData());
17546
17587
  const internalData = group_createInternalData();
17547
17588
  const computeIsReadonly = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
17548
17589
  const {
@@ -17721,6 +17762,7 @@ function group_createInternalData() {
17721
17762
  });
17722
17763
  });
17723
17764
  (0,external_commonjs_vue_commonjs2_vue_root_Vue_.onUnmounted)(() => {
17765
+ external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().assign(reactData, group_createReactData());
17724
17766
  external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().assign(internalData, group_createInternalData());
17725
17767
  });
17726
17768
  (0,external_commonjs_vue_commonjs2_vue_root_Vue_.provide)('$xeCheckboxGroup', $xeCheckboxGroup);
@@ -23820,6 +23862,40 @@ const DatePanel = VxeDatePanel;
23820
23862
 
23821
23863
 
23822
23864
 
23865
+
23866
+
23867
+
23868
+
23869
+ const {
23870
+ warnLog: date_picker_warnLog,
23871
+ errLog: date_picker_errLog
23872
+ } = createComponentLog('date-picker');
23873
+ const maskedTypes = ['year', 'month', 'date', 'datetime', 'time'];
23874
+ const inputMaskedKeys = ['y', 'M', 'd', 'H', 'm', 'n', 's'];
23875
+ const parseInputKayMaps = {};
23876
+ inputMaskedKeys.forEach(key => {
23877
+ parseInputKayMaps[key] = true;
23878
+ });
23879
+ function date_picker_createReactData() {
23880
+ return {
23881
+ initialized: false,
23882
+ panelIndex: 0,
23883
+ visiblePanel: false,
23884
+ isAniVisible: false,
23885
+ panelStyle: {},
23886
+ panelPlacement: '',
23887
+ isActivated: false,
23888
+ inputValue: '',
23889
+ labelFlag: 0
23890
+ };
23891
+ }
23892
+ function date_picker_createInternalData() {
23893
+ return {
23894
+ // hpTimeout: undefined,
23895
+ inputLabel: '',
23896
+ laseFocusMasked: 0
23897
+ };
23898
+ }
23823
23899
  /* harmony default export */ var date_picker = (defineVxeComponent({
23824
23900
  name: 'VxeDatePicker',
23825
23901
  props: {
@@ -23882,7 +23958,6 @@ const DatePanel = VxeDatePanel;
23882
23958
  labelFormat: String,
23883
23959
  valueFormat: String,
23884
23960
  timeFormat: String,
23885
- inputFormat: String,
23886
23961
  editable: {
23887
23962
  type: Boolean,
23888
23963
  default: true
@@ -23912,7 +23987,7 @@ const DatePanel = VxeDatePanel;
23912
23987
  type: Boolean,
23913
23988
  default: () => getConfig().datePicker.autoClose
23914
23989
  },
23915
- controlConfig: Object,
23990
+ maskedConfig: Object,
23916
23991
  prefixIcon: String,
23917
23992
  suffixIcon: String,
23918
23993
  placement: String,
@@ -23941,21 +24016,8 @@ const DatePanel = VxeDatePanel;
23941
24016
  const {
23942
24017
  computeSize
23943
24018
  } = useSize(props);
23944
- const reactData = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.reactive)({
23945
- initialized: false,
23946
- panelIndex: 0,
23947
- visiblePanel: false,
23948
- isAniVisible: false,
23949
- panelStyle: {},
23950
- panelPlacement: '',
23951
- isActivated: false,
23952
- inputValue: '',
23953
- inputLabel: ''
23954
- });
23955
- const internalData = {
23956
- // hpTimeout: undefined,
23957
- parseInputKayMaps: {}
23958
- };
24019
+ const reactData = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.reactive)(date_picker_createReactData());
24020
+ const internalData = date_picker_createInternalData();
23959
24021
  const refElem = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)();
23960
24022
  const refInputTarget = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)();
23961
24023
  const refInputPanel = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)();
@@ -24029,6 +24091,50 @@ const DatePanel = VxeDatePanel;
24029
24091
  const computeIsClearable = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
24030
24092
  return props.clearable;
24031
24093
  });
24094
+ const computeIsDatePanelType = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
24095
+ const isDateTimeType = computeIsDateTimeType.value;
24096
+ return isDateTimeType || ['date', 'week', 'month', 'quarter', 'year'].indexOf(props.type) > -1;
24097
+ });
24098
+ const computeDateListValue = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
24099
+ const {
24100
+ modelValue,
24101
+ type,
24102
+ multiple
24103
+ } = props;
24104
+ const isDatePanelType = computeIsDatePanelType.value;
24105
+ const dateValueFormat = computeDateValueFormat.value;
24106
+ if (multiple && modelValue && isDatePanelType) {
24107
+ return external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toValueString(modelValue).split(',').map(item => {
24108
+ const date = parseDateValue(item, type, {
24109
+ valueFormat: dateValueFormat
24110
+ });
24111
+ if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isValidDate(date)) {
24112
+ return date;
24113
+ }
24114
+ return date;
24115
+ });
24116
+ }
24117
+ return [];
24118
+ });
24119
+ const computeLimitMaxCount = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
24120
+ return props.multiple ? external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toNumber(props.limitCount) : 0;
24121
+ });
24122
+ const computeDateMultipleValue = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
24123
+ const dateListValue = computeDateListValue.value;
24124
+ const dateValueFormat = computeDateValueFormat.value;
24125
+ return dateListValue.map(date => external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toDateString(date, dateValueFormat));
24126
+ });
24127
+ const computeOverCount = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
24128
+ const {
24129
+ multiple
24130
+ } = props;
24131
+ const limitMaxCount = computeLimitMaxCount.value;
24132
+ const dateMultipleValue = computeDateMultipleValue.value;
24133
+ if (multiple && limitMaxCount) {
24134
+ return dateMultipleValue.length >= limitMaxCount;
24135
+ }
24136
+ return false;
24137
+ });
24032
24138
  const computeInputReadonly = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
24033
24139
  const {
24034
24140
  type,
@@ -24093,12 +24199,9 @@ const DatePanel = VxeDatePanel;
24093
24199
  } = props;
24094
24200
  return handleValueFormat(type, valueFormat);
24095
24201
  });
24096
- const computeDateInputFormat = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
24097
- const {
24098
- type,
24099
- inputFormat
24100
- } = props;
24101
- return handleInputFormat(type, inputFormat);
24202
+ const computeDateMaskedFormat = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
24203
+ const dateLabelFormat = computeDateLabelFormat.value;
24204
+ return dateLabelFormat;
24102
24205
  });
24103
24206
  const computeFirstDayOfWeek = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
24104
24207
  const {
@@ -24127,8 +24230,15 @@ const DatePanel = VxeDatePanel;
24127
24230
  return dateObj.label;
24128
24231
  }).join(', ');
24129
24232
  });
24130
- const computeControlOpts = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
24131
- return Object.assign({}, getConfig().datePicker.controlConfig, props.controlConfig);
24233
+ const computeMaskedOpts = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
24234
+ return Object.assign({}, getConfig().datePicker.maskedConfig, props.maskedConfig);
24235
+ });
24236
+ const computeMaskChar = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
24237
+ const maskedOpts = computeMaskedOpts.value;
24238
+ const {
24239
+ maskPlaceholder
24240
+ } = maskedOpts;
24241
+ return (maskPlaceholder ? ('' + maskPlaceholder)[0] : '') || '*';
24132
24242
  });
24133
24243
  const updateModelValue = () => {
24134
24244
  const {
@@ -24144,6 +24254,12 @@ const DatePanel = VxeDatePanel;
24144
24254
  }
24145
24255
  reactData.inputValue = val;
24146
24256
  };
24257
+ const handleInputLabel = (text, isUpdate) => {
24258
+ internalData.inputLabel = text;
24259
+ if (isUpdate) {
24260
+ reactData.labelFlag++;
24261
+ }
24262
+ };
24147
24263
  const triggerEvent = evnt => {
24148
24264
  const {
24149
24265
  inputValue
@@ -24205,7 +24321,7 @@ const DatePanel = VxeDatePanel;
24205
24321
  const inputEvent = evnt => {
24206
24322
  const inputElem = evnt.target;
24207
24323
  const value = inputElem.value;
24208
- reactData.inputLabel = value;
24324
+ handleInputLabel(value, true);
24209
24325
  dispatchEvent('input', {
24210
24326
  value
24211
24327
  }, evnt);
@@ -24216,19 +24332,6 @@ const DatePanel = VxeDatePanel;
24216
24332
  triggerEvent(evnt);
24217
24333
  }
24218
24334
  };
24219
- const focusEvent = evnt => {
24220
- const popupOpts = computePopupOpts.value;
24221
- const {
24222
- trigger
24223
- } = popupOpts;
24224
- reactData.isActivated = true;
24225
- if (!trigger || trigger === 'default') {
24226
- datePickerOpenEvent(evnt);
24227
- } else if (trigger === 'icon') {
24228
- hidePanel();
24229
- }
24230
- triggerEvent(evnt);
24231
- };
24232
24335
  const clickPrefixEvent = evnt => {
24233
24336
  const isDisabled = computeIsDisabled.value;
24234
24337
  if (!isDisabled) {
@@ -24249,6 +24352,125 @@ const DatePanel = VxeDatePanel;
24249
24352
  }, 350);
24250
24353
  });
24251
24354
  };
24355
+ const dateChange = (date, isReload) => {
24356
+ const {
24357
+ modelValue,
24358
+ multiple
24359
+ } = props;
24360
+ const isDateTimeType = computeIsDateTimeType.value;
24361
+ const dateValueFormat = computeDateValueFormat.value;
24362
+ const firstDayOfWeek = computeFirstDayOfWeek.value;
24363
+ if (props.type === 'week') {
24364
+ const sWeek = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toNumber(props.selectDay);
24365
+ date = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().getWhatWeek(date, 0, sWeek, firstDayOfWeek);
24366
+ }
24367
+ const inpVal = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toDateString(date, dateValueFormat, {
24368
+ firstDay: firstDayOfWeek
24369
+ });
24370
+ if (multiple) {
24371
+ const overCount = computeOverCount.value;
24372
+ // 如果为多选
24373
+ if (isDateTimeType) {
24374
+ // 如果是datetime特殊类型
24375
+ const dateListValue = isReload ? [] : [...computeDateListValue.value];
24376
+ const datetimeRest = [];
24377
+ const eqIndex = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().findIndexOf(dateListValue, val => external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isDateSame(date, val, 'yyyyMMdd'));
24378
+ if (eqIndex === -1) {
24379
+ if (overCount) {
24380
+ // 如果超出最大多选数量
24381
+ return;
24382
+ }
24383
+ dateListValue.push(date);
24384
+ } else {
24385
+ dateListValue.splice(eqIndex, 1);
24386
+ }
24387
+ dateListValue.forEach(item => {
24388
+ if (item) {
24389
+ datetimeRest.push(item);
24390
+ }
24391
+ });
24392
+ handleChange(datetimeRest.map(date => external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toDateString(date, dateValueFormat)).join(','), {
24393
+ type: 'update'
24394
+ });
24395
+ } else {
24396
+ const dateMultipleValue = isReload ? [] : computeDateMultipleValue.value;
24397
+ // 如果是日期类型
24398
+ if (dateMultipleValue.some(val => external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isEqual(val, inpVal))) {
24399
+ handleChange(dateMultipleValue.filter(val => !external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isEqual(val, inpVal)).join(','), {
24400
+ type: 'update'
24401
+ });
24402
+ } else {
24403
+ if (overCount) {
24404
+ // 如果超出最大多选数量
24405
+ return;
24406
+ }
24407
+ handleChange(dateMultipleValue.concat([inpVal]).join(','), {
24408
+ type: 'update'
24409
+ });
24410
+ }
24411
+ }
24412
+ } else {
24413
+ // 如果为单选
24414
+ if (!external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isEqual(modelValue, inpVal)) {
24415
+ handleChange(inpVal, {
24416
+ type: 'update'
24417
+ });
24418
+ }
24419
+ }
24420
+ };
24421
+ const dateRevert = () => {
24422
+ const panelLabel = computePanelLabel.value;
24423
+ handleInputLabel(panelLabel, true);
24424
+ };
24425
+ const afterCheckValue = inpVal => {
24426
+ const {
24427
+ type
24428
+ } = props;
24429
+ const {
24430
+ inputLabel
24431
+ } = internalData;
24432
+ const dateLabelFormat = computeDateLabelFormat.value;
24433
+ if (!inpVal) {
24434
+ handleChange('', {
24435
+ type: 'check'
24436
+ });
24437
+ return;
24438
+ }
24439
+ let inpDateVal = parseDateValue(inpVal, type, {
24440
+ valueFormat: dateLabelFormat
24441
+ });
24442
+ if (!external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isValidDate(inpDateVal)) {
24443
+ dateRevert();
24444
+ return;
24445
+ }
24446
+ if (type === 'time') {
24447
+ inpDateVal = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toDateString(inpDateVal, dateLabelFormat);
24448
+ if (inputLabel !== inpDateVal) {
24449
+ handleChange(inpDateVal, {
24450
+ type: 'check'
24451
+ });
24452
+ }
24453
+ handleInputLabel(inpDateVal, true);
24454
+ return;
24455
+ }
24456
+ let isChange = false;
24457
+ const firstDayOfWeek = computeFirstDayOfWeek.value;
24458
+ if (type === 'datetime') {
24459
+ const dateValue = reactData.inputValue;
24460
+ if (inpVal !== external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toDateString(dateValue, dateLabelFormat) || inpVal !== external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toDateString(inpDateVal, dateLabelFormat)) {
24461
+ isChange = true;
24462
+ }
24463
+ } else {
24464
+ isChange = true;
24465
+ }
24466
+ const label = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toDateString(inpDateVal, dateLabelFormat, {
24467
+ firstDay: firstDayOfWeek
24468
+ });
24469
+ handleInputLabel(label, true);
24470
+ if (isChange) {
24471
+ dateChange(inpDateVal);
24472
+ }
24473
+ };
24252
24474
  const clearValueEvent = (evnt, value) => {
24253
24475
  const isDatePickerType = computeIsDatePickerType.value;
24254
24476
  if (isDatePickerType) {
@@ -24270,17 +24492,225 @@ const DatePanel = VxeDatePanel;
24270
24492
  }, evnt);
24271
24493
  }
24272
24494
  };
24273
- const handleArrowInputDate = (evnt, isUpArrow) => {
24495
+ const handleArrowInputDate = (evnt, isUpArrow, isDwArrow, isLtArrow, isRtArrow) => {
24496
+ const {
24497
+ type,
24498
+ multiple
24499
+ } = props;
24500
+ if (multiple) {
24501
+ return;
24502
+ }
24503
+ const targetElem = refInputTarget.value;
24504
+ if (!targetElem) {
24505
+ return;
24506
+ }
24507
+ const inpValue = targetElem.value;
24508
+ if (!inpValue) {
24509
+ return;
24510
+ }
24511
+ const dateMaskedFormat = computeDateMaskedFormat.value;
24512
+ const dateLabelFormat = computeDateLabelFormat.value;
24513
+ const firstDayOfWeek = computeFirstDayOfWeek.value;
24514
+ const maskChar = computeMaskChar.value;
24515
+ const selectionStart = targetElem.selectionStart || 0;
24516
+ let selectKey = dateMaskedFormat[selectionStart];
24517
+ if (!parseInputKayMaps[selectKey]) {
24518
+ selectKey = dateMaskedFormat[selectionStart - 1];
24519
+ }
24520
+ const skRest = dateMaskedFormat.match(new RegExp(selectKey + '+'));
24521
+ if (!skRest) {
24522
+ return;
24523
+ }
24524
+ if (isUpArrow || isDwArrow) {
24525
+ const chunkFormat = skRest[0] || '';
24526
+ const chunkStartIndex = skRest.index || 0;
24527
+ const chunkEndIndex = chunkStartIndex + chunkFormat.length;
24528
+ const chunkValue = inpValue.slice(chunkStartIndex, chunkEndIndex);
24529
+ if (parseInputKayMaps[selectKey]) {
24530
+ const chunkNum = (isAllSameChar(chunkValue, maskChar) ? getChunkDefaultNum(selectKey) : external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toNumber(chunkValue)) + (isUpArrow ? 1 : -1);
24531
+ const restValue = inpValue.slice(0, chunkStartIndex) + external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().padStart(chunkNum, chunkFormat.length, '0') + inpValue.slice(chunkEndIndex);
24532
+ evnt.preventDefault();
24533
+ if (restValue.indexOf(maskChar) === -1) {
24534
+ // 解析日期
24535
+ const inpDateVal = parseDateValue(restValue, type, {
24536
+ valueFormat: dateLabelFormat
24537
+ });
24538
+ if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isValidDate(inpDateVal)) {
24539
+ const label = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toDateString(inpDateVal, dateLabelFormat, {
24540
+ firstDay: firstDayOfWeek
24541
+ });
24542
+ targetElem.value = label;
24543
+ handleInputLabel(label, false);
24544
+ }
24545
+ } else {
24546
+ targetElem.value = restValue;
24547
+ handleInputLabel(restValue, false);
24548
+ }
24549
+ }
24550
+ targetElem.setSelectionRange(chunkStartIndex, chunkEndIndex);
24551
+ } else if (isLtArrow || isRtArrow) {
24552
+ const currKeyIndex = inputMaskedKeys.indexOf(selectKey);
24553
+ if (currKeyIndex > -1) {
24554
+ const allMaskedKeys = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().map(dateMaskedFormat.match(new RegExp(`(${inputMaskedKeys.join('|')})+`, 'g')) || [], fullKey => fullKey[0]);
24555
+ const currIndex = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().findIndexOf(allMaskedKeys, key => selectKey === key[0]);
24556
+ const targetFormatKey = isLtArrow ? allMaskedKeys[currIndex - 1] || allMaskedKeys[0] : allMaskedKeys[currIndex + 1] || allMaskedKeys[allMaskedKeys.length - 1];
24557
+ const targetKey = targetFormatKey ? targetFormatKey[0] : '';
24558
+ const sktRest = dateMaskedFormat.match(new RegExp(targetKey + '+'));
24559
+ if (sktRest) {
24560
+ evnt.preventDefault();
24561
+ const mtStartIndex = sktRest.index || 0;
24562
+ const mtEndIndex = mtStartIndex + sktRest[0].length;
24563
+ targetElem.setSelectionRange(mtStartIndex, mtEndIndex);
24564
+ }
24565
+ }
24566
+ }
24567
+ internalData.isTriggerMasked = true;
24568
+ };
24569
+ const handleMaskedInputDate = evnt => {
24274
24570
  const {
24275
24571
  multiple
24276
24572
  } = props;
24277
24573
  if (multiple) {
24278
24574
  return;
24279
24575
  }
24576
+ const targetElem = refInputTarget.value;
24577
+ if (!targetElem) {
24578
+ return;
24579
+ }
24580
+ const isControlKey = hasControlKey(evnt);
24581
+ if (isControlKey) {
24582
+ return;
24583
+ }
24584
+ evnt.preventDefault();
24585
+ const eKey = evnt.key;
24586
+ const isDeleleKey = globalEvents.hasKey(evnt, GLOBAL_EVENT_KEYS.DELETE);
24587
+ const isBackspaceKey = globalEvents.hasKey(evnt, GLOBAL_EVENT_KEYS.BACKSPACE);
24588
+ const isNumKey = eKey >= '0' && eKey <= '9';
24589
+ const numKey = isNumKey ? evnt.key : '';
24590
+ if (!(isDeleleKey || isBackspaceKey || isNumKey)) {
24591
+ return;
24592
+ }
24280
24593
  const {
24281
- inputValue
24282
- } = reactData;
24283
- if (!inputValue) {
24594
+ isTriggerMasked
24595
+ } = internalData;
24596
+ const dateMaskedFormat = computeDateMaskedFormat.value;
24597
+ const maskChar = computeMaskChar.value;
24598
+ let inpValue = targetElem.value || dateMaskedFormat;
24599
+ const selectionStart = targetElem.selectionStart || 0;
24600
+ const selectionEnd = targetElem.selectionEnd || 0;
24601
+ let selectKey = dateMaskedFormat[selectionStart];
24602
+ if (!parseInputKayMaps[selectKey]) {
24603
+ selectKey = dateMaskedFormat[selectionStart - 1];
24604
+ }
24605
+ const skRest = dateMaskedFormat.match(new RegExp(selectKey + '+'));
24606
+ if (!skRest) {
24607
+ return;
24608
+ }
24609
+ const allMaskedKeys = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().map(dateMaskedFormat.match(new RegExp(`(${inputMaskedKeys.join('|')})+`, 'g')) || [], fullKey => fullKey[0]);
24610
+ const chunkFormat = skRest[0] || '';
24611
+ const chunkStartIndex = skRest.index || 0;
24612
+ const chunkEndIndex = chunkStartIndex + chunkFormat.length;
24613
+ const currKeyIndex = allMaskedKeys.indexOf(selectKey);
24614
+ // 全选 | 如果无效字符
24615
+ const isAllSelected = !selectionStart && selectionEnd === inpValue.length;
24616
+ const isNotMasked = inpValue && inpValue.length !== dateMaskedFormat.length;
24617
+ if (isAllSelected || isNotMasked) {
24618
+ inpValue = dateMaskedFormat;
24619
+ }
24620
+ let chunkValue = isDeleleKey ? '' : inpValue.slice(chunkStartIndex, chunkEndIndex);
24621
+ const chunkNums = chunkValue.match(/\d/g) || [];
24622
+ const chunkNumList = isTriggerMasked && !isBackspaceKey ? [] : chunkNums.slice(0);
24623
+ if (isNumKey) {
24624
+ chunkNumList.push(numKey);
24625
+ } else if (isBackspaceKey) {
24626
+ chunkNumList.pop();
24627
+ }
24628
+ chunkValue = chunkNumList.join('').padEnd(chunkFormat.length, maskChar);
24629
+ let restValue = inpValue.slice(0, chunkStartIndex) + chunkValue + inpValue.slice(chunkEndIndex);
24630
+ restValue = restValue.replace(new RegExp(`(${inputMaskedKeys.join('|')})`, 'g'), maskChar);
24631
+ targetElem.value = restValue;
24632
+ handleInputLabel(restValue, false);
24633
+ // 如果是全选/删除
24634
+ if (isAllSelected) {
24635
+ if (isBackspaceKey || isDeleleKey) {
24636
+ const firstMaskedKeys = allMaskedKeys[0];
24637
+ const firstSkRest = dateMaskedFormat.match(new RegExp(`${firstMaskedKeys}+`));
24638
+ if (firstSkRest) {
24639
+ const firstChunkFormat = firstSkRest[0];
24640
+ targetElem.setSelectionRange(0, firstChunkFormat.length);
24641
+ internalData.isTriggerMasked = true;
24642
+ return;
24643
+ }
24644
+ }
24645
+ } else {
24646
+ if (isBackspaceKey && !chunkNums.length) {
24647
+ // 回退到上一个数字块
24648
+ for (let i = currKeyIndex - 1; i >= 0; i--) {
24649
+ const prveChunkKey = allMaskedKeys[i];
24650
+ const prveSkRest = dateMaskedFormat.match(new RegExp(`${prveChunkKey}+`));
24651
+ if (prveSkRest) {
24652
+ const prveChunkFormat = prveSkRest[0];
24653
+ const prveChunkStartIndex = prveSkRest.index || 0;
24654
+ const prveChunkEndIndex = prveChunkStartIndex + prveChunkFormat.length;
24655
+ let prveChunkValue = restValue.slice(prveChunkStartIndex, prveChunkEndIndex);
24656
+ const prveChunkNums = prveChunkValue.match(/\d/g) || [];
24657
+ if (prveChunkNums.length) {
24658
+ prveChunkNums.pop();
24659
+ prveChunkValue = prveChunkNums.join('').padEnd(prveChunkFormat.length, maskChar);
24660
+ restValue = restValue.slice(0, prveChunkStartIndex) + prveChunkValue + restValue.slice(prveChunkEndIndex);
24661
+ targetElem.value = restValue;
24662
+ handleInputLabel(restValue, false);
24663
+ targetElem.setSelectionRange(prveChunkStartIndex, prveChunkEndIndex);
24664
+ return;
24665
+ }
24666
+ }
24667
+ }
24668
+ const firstMaskedKeys = allMaskedKeys[0];
24669
+ const firstSkRest = dateMaskedFormat.match(new RegExp(`${firstMaskedKeys}+`));
24670
+ if (firstSkRest) {
24671
+ const firstChunkFormat = firstSkRest[0];
24672
+ restValue = dateMaskedFormat.replace(new RegExp(`(${inputMaskedKeys.join('|')})`, 'g'), maskChar);
24673
+ targetElem.value = restValue;
24674
+ handleInputLabel(restValue, false);
24675
+ targetElem.setSelectionRange(0, firstChunkFormat.length);
24676
+ internalData.isTriggerMasked = true;
24677
+ return;
24678
+ }
24679
+ return;
24680
+ }
24681
+ }
24682
+ let maskStartIndex = skRest.index || 0;
24683
+ let maskEndIndex = maskStartIndex + skRest[0].length;
24684
+ // 如果输入完成,跳转下一个
24685
+ if (chunkNumList.length >= chunkValue.length) {
24686
+ const nextKeys = allMaskedKeys.slice(currKeyIndex + 1);
24687
+ if (currKeyIndex > -1) {
24688
+ const nextRest = nextKeys.length ? dateMaskedFormat.match(new RegExp(`(${nextKeys.join('|')})+`)) : null;
24689
+ // 如果当前数字块已输入,则跳转下一个数字块
24690
+ if (nextRest) {
24691
+ maskStartIndex = nextRest.index || 0;
24692
+ maskEndIndex = maskStartIndex + nextRest[0].length;
24693
+ targetElem.setSelectionRange(maskStartIndex, maskEndIndex);
24694
+ } else {
24695
+ targetElem.setSelectionRange(maskStartIndex, maskEndIndex);
24696
+ }
24697
+ }
24698
+ internalData.isTriggerMasked = true;
24699
+ return;
24700
+ }
24701
+ targetElem.setSelectionRange(maskStartIndex, maskEndIndex);
24702
+ internalData.isTriggerMasked = false;
24703
+ };
24704
+ const handleMaskedSelectedDate = (evnt, isFocus) => {
24705
+ const {
24706
+ type,
24707
+ multiple,
24708
+ modelValue
24709
+ } = props;
24710
+ if (multiple) {
24711
+ return;
24712
+ }
24713
+ if (!maskedTypes.includes(type)) {
24284
24714
  return;
24285
24715
  }
24286
24716
  const targetElem = refInputTarget.value;
@@ -24288,17 +24718,79 @@ const DatePanel = VxeDatePanel;
24288
24718
  return;
24289
24719
  }
24290
24720
  const {
24291
- parseInputKayMaps
24721
+ laseFocusMasked
24292
24722
  } = internalData;
24293
- const inputFormat = computeDateInputFormat.value;
24723
+ if (laseFocusMasked && Date.now() - laseFocusMasked < 100) {
24724
+ return;
24725
+ }
24726
+ const dateMaskedFormat = computeDateMaskedFormat.value;
24727
+ const maskChar = computeMaskChar.value;
24294
24728
  const selectionStart = targetElem.selectionStart || 0;
24295
- let selectKey = inputFormat[selectionStart];
24729
+ const selectionEnd = targetElem.selectionEnd || 0;
24730
+ const inpValue = targetElem.value;
24731
+ const allMaskedKeys = external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().map(dateMaskedFormat.match(new RegExp(`(${inputMaskedKeys.join('|')})+`, 'g')) || [], fullKey => fullKey[0]);
24732
+ // 如果为空
24733
+ if (!inpValue) {
24734
+ let restValue = dateMaskedFormat.replace(new RegExp(`(${inputMaskedKeys.join('|')})`, 'g'), maskChar);
24735
+ // 还原值
24736
+ if (isFocus && modelValue) {
24737
+ const chunkNums = ('' + external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().toNumber(modelValue)).match(/\d/g) || [];
24738
+ let useNumIndex = 0;
24739
+ restValue = dateMaskedFormat.replace(new RegExp(`(${inputMaskedKeys.join('|')})`, 'g'), txt => chunkNums[useNumIndex++] || txt);
24740
+ }
24741
+ const firstMaskedKeys = allMaskedKeys[0];
24742
+ const firstSkRest = dateMaskedFormat.match(new RegExp(`${firstMaskedKeys}+`));
24743
+ if (firstSkRest) {
24744
+ evnt.preventDefault();
24745
+ const firstChunkFormat = firstSkRest[0];
24746
+ targetElem.value = restValue;
24747
+ handleInputLabel(restValue, false);
24748
+ targetElem.setSelectionRange(0, firstChunkFormat.length);
24749
+ internalData.laseFocusMasked = Date.now();
24750
+ return;
24751
+ }
24752
+ }
24753
+ // 全选 | 如果无效字符
24754
+ const isAllSelected = !selectionStart && selectionEnd === inpValue.length;
24755
+ const isNotMasked = inpValue && inpValue.length !== dateMaskedFormat.length;
24756
+ if (isAllSelected || isNotMasked) {
24757
+ let restValue = '';
24758
+ // 还原值
24759
+ if (isNotMasked && inpValue) {
24760
+ const chunkNums = inpValue.match(/\d/g) || [];
24761
+ let useNumIndex = 0;
24762
+ restValue = dateMaskedFormat.replace(new RegExp(`(${inputMaskedKeys.join('|')})`, 'g'), () => chunkNums[useNumIndex++] || maskChar);
24763
+ } else {
24764
+ dateMaskedFormat.replace(new RegExp(`(${inputMaskedKeys.join('|')})`, 'g'), maskChar);
24765
+ }
24766
+ const firstMaskedKeys = allMaskedKeys[0];
24767
+ const firstSkRest = dateMaskedFormat.match(new RegExp(`${firstMaskedKeys}+`));
24768
+ if (firstSkRest) {
24769
+ evnt.preventDefault();
24770
+ const firstChunkFormat = firstSkRest[0];
24771
+ targetElem.value = restValue;
24772
+ handleInputLabel(restValue, false);
24773
+ targetElem.setSelectionRange(0, firstChunkFormat.length);
24774
+ internalData.laseFocusMasked = Date.now();
24775
+ return;
24776
+ }
24777
+ }
24778
+ // 是否选择数字块
24779
+ let selectKey = dateMaskedFormat[selectionStart];
24296
24780
  if (!parseInputKayMaps[selectKey]) {
24297
- selectKey = inputFormat[selectionStart - 1];
24781
+ selectKey = dateMaskedFormat[selectionStart - 1];
24298
24782
  }
24299
- const inputPaesrFn = parseInputKayMaps[selectKey];
24300
- if (inputPaesrFn) {
24301
- inputPaesrFn(evnt, targetElem, isUpArrow);
24783
+ if (selectKey) {
24784
+ evnt.preventDefault();
24785
+ const skRest = dateMaskedFormat.match(new RegExp(selectKey + '+'));
24786
+ if (skRest) {
24787
+ const chunkFormat = skRest[0] || '';
24788
+ const chunkStartIndex = skRest.index || 0;
24789
+ const chunkEndIndex = chunkStartIndex + chunkFormat.length;
24790
+ targetElem.setSelectionRange(chunkStartIndex, chunkEndIndex);
24791
+ internalData.isTriggerMasked = true;
24792
+ internalData.laseFocusMasked = Date.now();
24793
+ }
24302
24794
  }
24303
24795
  };
24304
24796
  const blurEvent = evnt => {
@@ -24312,10 +24804,15 @@ const DatePanel = VxeDatePanel;
24312
24804
  handleChange(value, evnt);
24313
24805
  }
24314
24806
  if (!reactData.visiblePanel) {
24807
+ const {
24808
+ inputLabel
24809
+ } = internalData;
24315
24810
  reactData.isActivated = false;
24316
24811
  // 未打开面板时才校验
24317
24812
  if ($datePanel) {
24318
- $datePanel.checkValue(reactData.inputLabel);
24813
+ $datePanel.checkValue(inputLabel);
24814
+ } else {
24815
+ afterCheckValue(inputLabel);
24319
24816
  }
24320
24817
  }
24321
24818
  dispatchEvent('blur', {
@@ -24326,15 +24823,92 @@ const DatePanel = VxeDatePanel;
24326
24823
  $xeForm.triggerItemEvent(evnt, formItemInfo.itemConfig.field, value);
24327
24824
  }
24328
24825
  };
24826
+ const focusEvent = evnt => {
24827
+ const {
24828
+ multiple,
24829
+ editable,
24830
+ maskedConfig
24831
+ } = props;
24832
+ const maskedOpts = computeMaskedOpts.value;
24833
+ const popupOpts = computePopupOpts.value;
24834
+ const {
24835
+ trigger
24836
+ } = popupOpts;
24837
+ reactData.isActivated = true;
24838
+ if (!trigger || trigger === 'default') {
24839
+ datePickerOpenEvent(evnt);
24840
+ setTimeout(() => {
24841
+ if (editable && !multiple && (isEnableConf(maskedConfig) || maskedOpts.enabled)) {
24842
+ handleMaskedSelectedDate(evnt, true);
24843
+ }
24844
+ }, 15);
24845
+ } else if (trigger === 'icon') {
24846
+ hidePanel();
24847
+ setTimeout(() => {
24848
+ if (editable && !multiple && (isEnableConf(maskedConfig) || maskedOpts.enabled)) {
24849
+ handleMaskedSelectedDate(evnt, true);
24850
+ }
24851
+ }, 15);
24852
+ } else {
24853
+ if (editable && !multiple && (isEnableConf(maskedConfig) || maskedOpts.enabled)) {
24854
+ handleMaskedSelectedDate(evnt, true);
24855
+ }
24856
+ }
24857
+ triggerEvent(evnt);
24858
+ };
24859
+ const clickEvent = evnt => {
24860
+ const {
24861
+ editable,
24862
+ maskedConfig
24863
+ } = props;
24864
+ const maskedOpts = computeMaskedOpts.value;
24865
+ if (editable && (isEnableConf(maskedConfig) || maskedOpts.enabled)) {
24866
+ handleMaskedSelectedDate(evnt);
24867
+ }
24868
+ triggerEvent(evnt);
24869
+ };
24329
24870
  const keydownEvent = evnt => {
24330
24871
  const {
24331
- controlConfig
24872
+ type,
24873
+ editable,
24874
+ maskedConfig
24332
24875
  } = props;
24333
- const controlOpts = computeControlOpts.value;
24876
+ const {
24877
+ visiblePanel
24878
+ } = reactData;
24879
+ const maskedOpts = computeMaskedOpts.value;
24334
24880
  const isUpArrow = globalEvents.hasKey(evnt, GLOBAL_EVENT_KEYS.ARROW_UP);
24335
24881
  const isDwArrow = globalEvents.hasKey(evnt, GLOBAL_EVENT_KEYS.ARROW_DOWN);
24336
- if ((isUpArrow || isDwArrow) && controlOpts.isArrow && (controlConfig || controlOpts.enabled)) {
24337
- handleArrowInputDate(evnt, isUpArrow);
24882
+ const isLtArrow = globalEvents.hasKey(evnt, GLOBAL_EVENT_KEYS.ARROW_LEFT);
24883
+ const isRtArrow = globalEvents.hasKey(evnt, GLOBAL_EVENT_KEYS.ARROW_RIGHT);
24884
+ const isEnter = globalEvents.hasKey(evnt, GLOBAL_EVENT_KEYS.ENTER);
24885
+ if (editable) {
24886
+ if (isEnter) {
24887
+ const $datePanel = refDatePanel.value;
24888
+ const {
24889
+ inputLabel
24890
+ } = internalData;
24891
+ const targetElem = refInputTarget.value;
24892
+ if (visiblePanel) {
24893
+ hidePanel();
24894
+ }
24895
+ if ($datePanel) {
24896
+ $datePanel.checkValue(inputLabel);
24897
+ } else {
24898
+ afterCheckValue(inputLabel);
24899
+ }
24900
+ if (targetElem) {
24901
+ targetElem.blur();
24902
+ }
24903
+ } else if (maskedTypes.includes(type)) {
24904
+ if (isEnableConf(maskedConfig) || maskedOpts.enabled) {
24905
+ if (maskedOpts.isArrow && (isUpArrow || isDwArrow || isLtArrow || isRtArrow)) {
24906
+ handleArrowInputDate(evnt, isUpArrow, isDwArrow, isLtArrow, isRtArrow);
24907
+ } else if (maskedOpts.isMasked) {
24908
+ handleMaskedInputDate(evnt);
24909
+ }
24910
+ }
24911
+ }
24338
24912
  }
24339
24913
  triggerEvent(evnt);
24340
24914
  };
@@ -24369,7 +24943,7 @@ const DatePanel = VxeDatePanel;
24369
24943
  dispatchEvent('confirm', params, params.$event);
24370
24944
  };
24371
24945
  const panelRevertEvent = params => {
24372
- reactData.inputLabel = params.label;
24946
+ handleInputLabel(params.label, true);
24373
24947
  };
24374
24948
  // 全局事件
24375
24949
  const handleGlobalMousedownEvent = evnt => {
@@ -24382,12 +24956,20 @@ const DatePanel = VxeDatePanel;
24382
24956
  const panelWrapperElem = refPanelWrapper.value;
24383
24957
  const isDisabled = computeIsDisabled.value;
24384
24958
  if (!isDisabled && isActivated) {
24385
- reactData.isActivated = getEventTargetNode(evnt, el).flag || getEventTargetNode(evnt, panelWrapperElem).flag;
24386
- if (!reactData.isActivated) {
24959
+ const currActivated = getEventTargetNode(evnt, el).flag || getEventTargetNode(evnt, panelWrapperElem).flag;
24960
+ if (currActivated !== isActivated) {
24961
+ reactData.isActivated = currActivated;
24962
+ }
24963
+ if (!currActivated) {
24387
24964
  if (visiblePanel) {
24388
24965
  hidePanel();
24966
+ const {
24967
+ inputLabel
24968
+ } = internalData;
24389
24969
  if ($datePanel) {
24390
- $datePanel.checkValue(reactData.inputLabel);
24970
+ $datePanel.checkValue(inputLabel);
24971
+ } else {
24972
+ afterCheckValue(inputLabel);
24391
24973
  }
24392
24974
  }
24393
24975
  }
@@ -24395,6 +24977,7 @@ const DatePanel = VxeDatePanel;
24395
24977
  };
24396
24978
  const handleGlobalKeydownEvent = evnt => {
24397
24979
  const {
24980
+ isActivated,
24398
24981
  visiblePanel
24399
24982
  } = reactData;
24400
24983
  const isDisabled = computeIsDisabled.value;
@@ -24402,7 +24985,9 @@ const DatePanel = VxeDatePanel;
24402
24985
  const isTab = globalEvents.hasKey(evnt, GLOBAL_EVENT_KEYS.TAB);
24403
24986
  const isEsc = globalEvents.hasKey(evnt, GLOBAL_EVENT_KEYS.ESCAPE);
24404
24987
  if (isTab) {
24405
- reactData.isActivated = false;
24988
+ if (isActivated) {
24989
+ reactData.isActivated = false;
24990
+ }
24406
24991
  }
24407
24992
  if (visiblePanel) {
24408
24993
  if (isEsc || isTab) {
@@ -24441,7 +25026,7 @@ const DatePanel = VxeDatePanel;
24441
25026
  }
24442
25027
  if (visiblePanel || isActivated) {
24443
25028
  if ($datePanel) {
24444
- $datePanel.checkValue(reactData.inputLabel);
25029
+ $datePanel.checkValue(internalData.inputLabel);
24445
25030
  }
24446
25031
  const targetElem = refInputTarget.value;
24447
25032
  if (targetElem) {
@@ -24543,9 +25128,6 @@ const DatePanel = VxeDatePanel;
24543
25128
  }
24544
25129
  }
24545
25130
  };
24546
- const clickEvent = evnt => {
24547
- triggerEvent(evnt);
24548
- };
24549
25131
  const handleShortcutEvent = ({
24550
25132
  option,
24551
25133
  $event
@@ -24596,7 +25178,7 @@ const DatePanel = VxeDatePanel;
24596
25178
  break;
24597
25179
  }
24598
25180
  default:
24599
- errLog('vxe.error.notCommands', [`[date-picker] ${code}`]);
25181
+ date_picker_errLog('vxe.error.notCommands', [code]);
24600
25182
  break;
24601
25183
  }
24602
25184
  }
@@ -24847,10 +25429,13 @@ const DatePanel = VxeDatePanel;
24847
25429
  } = props;
24848
25430
  const {
24849
25431
  inputValue,
24850
- inputLabel,
24851
25432
  visiblePanel,
24852
- isActivated
25433
+ isActivated,
25434
+ labelFlag
24853
25435
  } = reactData;
25436
+ const {
25437
+ inputLabel
25438
+ } = internalData;
24854
25439
  const vSize = computeSize.value;
24855
25440
  const isDisabled = computeIsDisabled.value;
24856
25441
  const formReadonly = computeFormReadonly.value;
@@ -24883,7 +25468,7 @@ const DatePanel = VxeDatePanel;
24883
25468
  }, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.h)('input', {
24884
25469
  ref: refInputTarget,
24885
25470
  class: 'vxe-date-picker--inner',
24886
- value: inputLabel,
25471
+ value: labelFlag ? inputLabel : '',
24887
25472
  name,
24888
25473
  type: 'text',
24889
25474
  placeholder: inpPlaceholder,
@@ -24902,7 +25487,7 @@ const DatePanel = VxeDatePanel;
24902
25487
  renderPanel()]);
24903
25488
  };
24904
25489
  (0,external_commonjs_vue_commonjs2_vue_root_Vue_.watch)(computePanelLabel, val => {
24905
- reactData.inputLabel = val;
25490
+ handleInputLabel(val, true);
24906
25491
  });
24907
25492
  (0,external_commonjs_vue_commonjs2_vue_root_Vue_.watch)(() => props.modelValue, () => {
24908
25493
  updateModelValue();
@@ -24916,14 +25501,18 @@ const DatePanel = VxeDatePanel;
24916
25501
  });
24917
25502
  (0,external_commonjs_vue_commonjs2_vue_root_Vue_.onMounted)(() => {
24918
25503
  const {
24919
- parseInputKayMaps
24920
- } = internalData;
24921
- const inputKeys = ['y', 'M', 'd', 'H', 'm', 'n'];
24922
- inputKeys.forEach(key => {
24923
- parseInputKayMaps[key] = evnt => {
24924
- evnt.preventDefault();
24925
- };
24926
- });
25504
+ type,
25505
+ multiple,
25506
+ maskedConfig
25507
+ } = props;
25508
+ if (isEnableConf(maskedConfig)) {
25509
+ if (multiple) {
25510
+ date_picker_errLog('vxe.error.notSupportProp', ['multiple', 'control-config.enabled=true', 'control-config.enabled=false']);
25511
+ }
25512
+ if (!maskedTypes.includes(type)) {
25513
+ date_picker_warnLog('vxe.error.notSupportProp', ['control-config.enabled=true', `type=${type}`, `type=${maskedTypes.join('|')}`]);
25514
+ }
25515
+ }
24927
25516
  });
24928
25517
  (0,external_commonjs_vue_commonjs2_vue_root_Vue_.onUnmounted)(() => {
24929
25518
  globalEvents.off($xeDatePicker, 'mousewheel');
@@ -24968,6 +25557,9 @@ const DatePicker = VxeDatePicker;
24968
25557
 
24969
25558
 
24970
25559
 
25560
+ const {
25561
+ errLog: date_range_picker_errLog
25562
+ } = createComponentLog('date-range-picker');
24971
25563
  /* harmony default export */ var date_range_picker = (defineVxeComponent({
24972
25564
  name: 'VxeDateRangePicker',
24973
25565
  props: {
@@ -25979,7 +26571,7 @@ const DatePicker = VxeDatePicker;
25979
26571
  break;
25980
26572
  }
25981
26573
  default:
25982
- errLog('vxe.error.notCommands', [`[date-range-picker] ${code}`]);
26574
+ date_range_picker_errLog('vxe.error.notCommands', [code]);
25983
26575
  break;
25984
26576
  }
25985
26577
  }
@@ -26488,6 +27080,7 @@ const allActiveDrawers = [];
26488
27080
  type: Boolean,
26489
27081
  default: () => getConfig().drawer.showTitleOverflow
26490
27082
  },
27083
+ preload: Boolean,
26491
27084
  width: [Number, String],
26492
27085
  height: [Number, String],
26493
27086
  resize: {
@@ -27036,6 +27629,7 @@ const allActiveDrawers = [];
27036
27629
  }
27037
27630
  });
27038
27631
  (0,external_commonjs_vue_commonjs2_vue_root_Vue_.onMounted)(() => {
27632
+ reactData.initialized = !!props.preload;
27039
27633
  (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)(() => {
27040
27634
  if (props.modelValue) {
27041
27635
  openDrawer();
@@ -27225,6 +27819,9 @@ const Empty = VxeEmpty;
27225
27819
 
27226
27820
 
27227
27821
 
27822
+ const {
27823
+ errLog: itemInfo_errLog
27824
+ } = createComponentLog('form');
27228
27825
  class ItemInfo {
27229
27826
  constructor($xeForm, item) {
27230
27827
  const {
@@ -27236,21 +27833,21 @@ class ItemInfo {
27236
27833
  if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isString(formatter)) {
27237
27834
  const gFormatOpts = formats.get(formatter);
27238
27835
  if (!gFormatOpts || !gFormatOpts.formItemFormatMethod) {
27239
- errLog('vxe.error.notFormats', [`[form] ${formatter}`]);
27836
+ itemInfo_errLog('vxe.error.notFormats', [formatter]);
27240
27837
  }
27241
27838
  } else if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isArray(formatter)) {
27242
27839
  const gFormatOpts = formats.get(formatter[0]);
27243
27840
  if (!gFormatOpts || !gFormatOpts.formItemFormatMethod) {
27244
- errLog('vxe.error.notFormats', [`[form] ${formatter[0]}`]);
27841
+ itemInfo_errLog('vxe.error.notFormats', [formatter[0]]);
27245
27842
  }
27246
27843
  }
27247
27844
  }
27248
27845
  if (field && itemRender) {
27249
27846
  if (itemRender.startField && `${itemRender.startField}`.indexOf(field) >= 0) {
27250
- errLog('vxe.error.modelConflicts', [`[form] field=${field}`, `item-render.startField=${itemRender.startField}`]);
27847
+ itemInfo_errLog('vxe.error.modelConflicts', [`field=${field}`, `item-render.startField=${itemRender.startField}`]);
27251
27848
  }
27252
27849
  if (itemRender.endField && `${itemRender.endField}`.indexOf(field) >= 0) {
27253
- errLog('vxe.error.modelConflicts', [`[form] field=${field}`, `item-render.endField=${itemRender.endField}`]);
27850
+ itemInfo_errLog('vxe.error.modelConflicts', [`field=${field}`, `item-render.endField=${itemRender.endField}`]);
27254
27851
  }
27255
27852
  }
27256
27853
  Object.assign(this, {
@@ -28183,6 +28780,9 @@ const VxeFormConfigItem = defineVxeComponent({
28183
28780
 
28184
28781
 
28185
28782
 
28783
+ const {
28784
+ errLog: render_errLog
28785
+ } = createComponentLog('form');
28186
28786
  const componentDefaultModelProp = 'modelValue';
28187
28787
  /**
28188
28788
  * 已废弃
@@ -28287,7 +28887,7 @@ function getComponentOns(renderOpts, params, eFns, eventOns) {
28287
28887
  external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().objectEach(events, (func, key) => {
28288
28888
  ons[getOnName(key)] = function (...args) {
28289
28889
  if (!external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(func)) {
28290
- errLog('vxe.error.errFunc', [`[form] ${func}`]);
28890
+ render_errLog('vxe.error.errFunc', [func]);
28291
28891
  }
28292
28892
  func(params, ...args);
28293
28893
  };
@@ -28896,6 +29496,10 @@ renderer.mixin({
28896
29496
 
28897
29497
 
28898
29498
 
29499
+ const {
29500
+ warnLog: form_warnLog,
29501
+ errLog: form_errLog
29502
+ } = createComponentLog('form');
28899
29503
  class Rule {
28900
29504
  constructor(rule) {
28901
29505
  Object.assign(this, {
@@ -29216,7 +29820,7 @@ function form_createInternalData() {
29216
29820
  external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().each(item.slots, func => {
29217
29821
  if (!external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(func)) {
29218
29822
  if (!slots[func]) {
29219
- errLog('vxe.error.notSlot', [`[form] ${func}`]);
29823
+ form_errLog('vxe.error.notSlot', [func]);
29220
29824
  }
29221
29825
  }
29222
29826
  });
@@ -29499,10 +30103,10 @@ function form_createInternalData() {
29499
30103
  if (validatorMethod) {
29500
30104
  customValid = validatorMethod(validParams);
29501
30105
  } else {
29502
- warnLog('vxe.error.notValidators', [`[form] ${validator}`]);
30106
+ form_warnLog('vxe.error.notValidators', [validator]);
29503
30107
  }
29504
30108
  } else {
29505
- errLog('vxe.error.notValidators', [`[form] ${validator}`]);
30109
+ form_errLog('vxe.error.notValidators', [validator]);
29506
30110
  }
29507
30111
  } else {
29508
30112
  customValid = validator(validParams);
@@ -29934,7 +30538,7 @@ function form_createInternalData() {
29934
30538
  (0,external_commonjs_vue_commonjs2_vue_root_Vue_.onMounted)(() => {
29935
30539
  (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)(() => {
29936
30540
  if (props.customLayout && props.items) {
29937
- errLog('vxe.error.errConflicts', ['[form] custom-layout', 'items']);
30541
+ form_errLog('vxe.error.errConflicts', ['custom-layout', 'items']);
29938
30542
  }
29939
30543
  });
29940
30544
  globalEvents.on($xeForm, 'resize', handleGlobalResizeEvent);
@@ -32618,6 +33222,9 @@ const List = VxeList;
32618
33222
 
32619
33223
 
32620
33224
 
33225
+ const {
33226
+ errLog: menu_errLog
33227
+ } = createComponentLog('menu');
32621
33228
  const {
32622
33229
  menus: menu_menus,
32623
33230
  getConfig: menu_getConfig,
@@ -33166,7 +33773,7 @@ const {
33166
33773
  } = props;
33167
33774
  const VxeUIContextMenu = VxeUI.getComponent('VxeContextMenu');
33168
33775
  if (menuConfig && !VxeUIContextMenu) {
33169
- errLog('vxe.error.reqComp', ['vxe-context-menu']);
33776
+ menu_errLog('vxe.error.reqComp', ['vxe-context-menu']);
33170
33777
  }
33171
33778
  globalEvents.on($xeMenu, 'resize', updateCollapseStyle);
33172
33779
  updateCollapseStyle();
@@ -33219,6 +33826,10 @@ const Menu = VxeMenu;
33219
33826
 
33220
33827
 
33221
33828
 
33829
+ const {
33830
+ warnLog: modal_warnLog,
33831
+ errLog: modal_errLog
33832
+ } = createComponentLog('modal');
33222
33833
  const allActiveModals = [];
33223
33834
  const msgQueue = [];
33224
33835
  const notifyQueue = [];
@@ -33305,6 +33916,7 @@ const lockScrollCssWidthKey = '--vxe-ui-modal-lock-scroll-view-width';
33305
33916
  type: Boolean,
33306
33917
  default: () => getConfig().modal.showFooter
33307
33918
  },
33919
+ preload: Boolean,
33308
33920
  showZoom: Boolean,
33309
33921
  zoomConfig: Object,
33310
33922
  showMaximize: {
@@ -34701,11 +35313,12 @@ const lockScrollCssWidthKey = '--vxe-ui-modal-lock-scroll-view-width';
34701
35313
  });
34702
35314
  (0,external_commonjs_vue_commonjs2_vue_root_Vue_.onMounted)(() => {
34703
35315
  if (props.type === 'modal' && props.showFooter && !(props.showConfirmButton || props.showCancelButton || slots.footer)) {
34704
- warnLog('vxe.modal.footPropErr');
35316
+ modal_warnLog('vxe.modal.footPropErr');
34705
35317
  }
35318
+ reactData.initialized = !!props.preload;
34706
35319
  (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)(() => {
34707
35320
  if (props.storage && !props.id) {
34708
- errLog('vxe.error.reqProp', ['[modal] id']);
35321
+ modal_errLog('vxe.error.reqProp', ['id']);
34709
35322
  }
34710
35323
  if (props.modelValue) {
34711
35324
  openModal();
@@ -35246,12 +35859,36 @@ const Option = VxeOption;
35246
35859
 
35247
35860
 
35248
35861
 
35862
+ const {
35863
+ errLog: select_errLog
35864
+ } = createComponentLog('select');
35249
35865
  function isOptionVisible(option) {
35250
35866
  return option.visible !== false;
35251
35867
  }
35252
35868
  function getOptUniqueId() {
35253
35869
  return external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().uniqueId('opt_');
35254
35870
  }
35871
+ function select_createReactData() {
35872
+ return {
35873
+ initialized: false,
35874
+ scrollYLoad: false,
35875
+ bodyHeight: 0,
35876
+ topSpaceHeight: 0,
35877
+ optList: [],
35878
+ staticOptions: [],
35879
+ reactFlag: 0,
35880
+ currentOption: null,
35881
+ searchValue: '',
35882
+ searchLoading: false,
35883
+ panelIndex: 0,
35884
+ panelStyle: {},
35885
+ panelPlacement: null,
35886
+ triggerFocusPanel: false,
35887
+ visiblePanel: false,
35888
+ isAniVisible: false,
35889
+ isActivated: false
35890
+ };
35891
+ }
35255
35892
  function select_createInternalData() {
35256
35893
  return {
35257
35894
  // isLoaded: false,
@@ -35421,25 +36058,7 @@ function select_createInternalData() {
35421
36058
  const {
35422
36059
  computeSize
35423
36060
  } = useSize(props);
35424
- const reactData = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.reactive)({
35425
- initialized: false,
35426
- scrollYLoad: false,
35427
- bodyHeight: 0,
35428
- topSpaceHeight: 0,
35429
- optList: [],
35430
- staticOptions: [],
35431
- reactFlag: 0,
35432
- currentOption: null,
35433
- searchValue: '',
35434
- searchLoading: false,
35435
- panelIndex: 0,
35436
- panelStyle: {},
35437
- panelPlacement: null,
35438
- triggerFocusPanel: false,
35439
- visiblePanel: false,
35440
- isAniVisible: false,
35441
- isActivated: false
35442
- });
36061
+ const reactData = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.reactive)(select_createReactData());
35443
36062
  const internalData = select_createInternalData();
35444
36063
  const refMaps = {
35445
36064
  refElem
@@ -36645,7 +37264,7 @@ function select_createInternalData() {
36645
37264
  emitDefaultValue(datas.map(item => item[valueField]));
36646
37265
  });
36647
37266
  } else {
36648
- errLog('vxe.error.notConflictProp', ['default-config.selectMode=all', 'multiple=true']);
37267
+ select_errLog('vxe.error.notConflictProp', ['default-config.selectMode=all', 'multiple=true']);
36649
37268
  }
36650
37269
  } else if (selectMode === 'first' || selectMode === 'last') {
36651
37270
  const selectItem = (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default())[selectMode](datas);
@@ -37117,6 +37736,7 @@ function select_createInternalData() {
37117
37736
  globalEvents.off($xeSelect, 'keydown');
37118
37737
  globalEvents.off($xeSelect, 'blur');
37119
37738
  globalEvents.off($xeSelect, 'resize');
37739
+ external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().assign(reactData, select_createReactData());
37120
37740
  external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().assign(internalData, select_createInternalData());
37121
37741
  });
37122
37742
  (0,external_commonjs_vue_commonjs2_vue_root_Vue_.provide)('$xeSelect', $xeSelect);
@@ -37139,6 +37759,10 @@ function select_createInternalData() {
37139
37759
 
37140
37760
 
37141
37761
 
37762
+ const {
37763
+ warnLog: pager_warnLog,
37764
+ errLog: pager_errLog
37765
+ } = createComponentLog('pager');
37142
37766
  /* harmony default export */ var pager = (defineVxeComponent({
37143
37767
  name: 'VxePager',
37144
37768
  props: {
@@ -37848,7 +38472,7 @@ function select_createInternalData() {
37848
38472
  * @deprecated
37849
38473
  */
37850
38474
  jumpPage(currentPage) {
37851
- warnLog('vxe.error.delFunc', ['[pager] jumpPage', 'setCurrentPage']);
38475
+ pager_warnLog('vxe.error.delFunc', ['jumpPage', 'setCurrentPage']);
37852
38476
  return $xePager.setCurrentPage(currentPage);
37853
38477
  }
37854
38478
  };
@@ -37924,7 +38548,7 @@ function select_createInternalData() {
37924
38548
  if (renderFn) {
37925
38549
  childNodes.push(renderFn());
37926
38550
  } else {
37927
- errLog('vxe.error.notProp', [`[pager] layouts -> ${name}`]);
38551
+ pager_errLog('vxe.error.notProp', [`layouts -> ${name}`]);
37928
38552
  }
37929
38553
  });
37930
38554
  if (slots.right) {
@@ -39851,6 +40475,9 @@ const RadioButton = VxeRadioButton;
39851
40475
 
39852
40476
 
39853
40477
 
40478
+ function src_group_createReactData() {
40479
+ return {};
40480
+ }
39854
40481
  function src_group_createInternalData() {
39855
40482
  return {
39856
40483
  // isLoaded: false
@@ -39893,7 +40520,7 @@ function src_group_createInternalData() {
39893
40520
  const {
39894
40521
  computeSize
39895
40522
  } = useSize(props);
39896
- const reactData = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.reactive)({});
40523
+ const reactData = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.reactive)(src_group_createReactData());
39897
40524
  const internalData = src_group_createInternalData();
39898
40525
  const computeIsReadonly = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
39899
40526
  const {
@@ -40051,6 +40678,7 @@ function src_group_createInternalData() {
40051
40678
  });
40052
40679
  });
40053
40680
  (0,external_commonjs_vue_commonjs2_vue_root_Vue_.onUnmounted)(() => {
40681
+ external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().assign(reactData, src_group_createReactData());
40054
40682
  external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().assign(internalData, src_group_createInternalData());
40055
40683
  });
40056
40684
  (0,external_commonjs_vue_commonjs2_vue_root_Vue_.provide)('$xeRadioGroup', $xeRadioGroup);
@@ -40769,6 +41397,10 @@ const Select = VxeSelect;
40769
41397
 
40770
41398
 
40771
41399
 
41400
+ const {
41401
+ warnLog: splitter_warnLog,
41402
+ errLog: splitter_errLog
41403
+ } = createComponentLog('splitter');
40772
41404
  /* harmony default export */ var splitter = (defineVxeComponent({
40773
41405
  name: 'VxeSplitter',
40774
41406
  props: {
@@ -40989,13 +41621,13 @@ const Select = VxeSelect;
40989
41621
  };
40990
41622
  reactData.itemList = list.map(item => {
40991
41623
  if (item.showAction) {
40992
- warnLog('vxe.error.removeProp', ['[splitter] show-action']);
41624
+ splitter_warnLog('vxe.error.removeProp', ['show-action']);
40993
41625
  }
40994
41626
  if (item.slots) {
40995
41627
  external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().each(item.slots, func => {
40996
41628
  if (!external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isFunction(func)) {
40997
41629
  if (!slots[func]) {
40998
- errLog('vxe.error.notSlot', [`[splitter] ${func}`]);
41630
+ splitter_errLog('vxe.error.notSlot', [func]);
40999
41631
  }
41000
41632
  }
41001
41633
  });
@@ -41005,10 +41637,10 @@ const Select = VxeSelect;
41005
41637
  });
41006
41638
  });
41007
41639
  if (staticItems.length) {
41008
- errLog('vxe.error.errConflicts', ['<vxe-splitter-panel ...>', 'items']);
41640
+ splitter_errLog('vxe.error.errConflicts', ['<vxe-splitter-panel ...>', 'items']);
41009
41641
  }
41010
41642
  if ((showPrevButton || showNextButton) && reactData.itemList.length > 2) {
41011
- errLog('vxe.error.errConflicts', ['action-config.showPrevButton | action-config.showNextButton', 'Only supports 2 item']);
41643
+ splitter_errLog('vxe.error.errConflicts', ['action-config.showPrevButton | action-config.showNextButton', 'Only supports 2 item']);
41012
41644
  }
41013
41645
  return recalculate();
41014
41646
  };
@@ -41748,15 +42380,15 @@ const Select = VxeSelect;
41748
42380
  showNextButton
41749
42381
  } = actionOpts;
41750
42382
  if (props.items && props.items.length) {
41751
- errLog('vxe.error.errConflicts', ['<vxe-splitter-panel ...>', 'items']);
42383
+ splitter_errLog('vxe.error.errConflicts', ['<vxe-splitter-panel ...>', 'items']);
41752
42384
  }
41753
42385
  reactData.itemList = val || [];
41754
42386
  if ((showPrevButton || showNextButton) && reactData.itemList.length > 2) {
41755
- errLog('vxe.error.modelConflicts', ['[splitter] action-config.showPrevButton | action-config.showNextButton', '<vxe-splitter-panel ...> Only supports 2 panel']);
42387
+ splitter_errLog('vxe.error.modelConflicts', ['action-config.showPrevButton | action-config.showNextButton', '<vxe-splitter-panel ...> Only supports 2 panel']);
41756
42388
  }
41757
42389
  reactData.itemList.forEach(item => {
41758
42390
  if (item.showAction) {
41759
- warnLog('vxe.error.removeProp', ['[splitter] showAction']);
42391
+ splitter_warnLog('vxe.error.removeProp', ['showAction']);
41760
42392
  }
41761
42393
  });
41762
42394
  recalculate();
@@ -41775,7 +42407,7 @@ const Select = VxeSelect;
41775
42407
  }
41776
42408
  const actionOpts = computeActionOpts.value;
41777
42409
  if (actionOpts.direction) {
41778
- errLog('vxe.error.delProp', ['[splitter] action-config.direction', 'action-config.showPrevButton | action-config.showNextButton']);
42410
+ splitter_errLog('vxe.error.delProp', ['action-config.direction', 'action-config.showPrevButton | action-config.showNextButton']);
41779
42411
  }
41780
42412
  globalEvents.on($xeSplitter, 'resize', handleGlobalResizeEvent);
41781
42413
  });
@@ -42723,9 +43355,26 @@ const TabPane = VxeTabPane;
42723
43355
 
42724
43356
 
42725
43357
 
43358
+ const {
43359
+ errLog: table_select_errLog
43360
+ } = createComponentLog('table-select');
42726
43361
  function getRowUniqueId() {
42727
43362
  return external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().uniqueId('row_');
42728
43363
  }
43364
+ function table_select_createReactData() {
43365
+ return {
43366
+ initialized: false,
43367
+ tableColumns: [],
43368
+ fullOptionList: [],
43369
+ panelIndex: 0,
43370
+ panelStyle: {},
43371
+ panelPlacement: null,
43372
+ triggerFocusPanel: false,
43373
+ visiblePanel: false,
43374
+ isAniVisible: false,
43375
+ isActivated: false
43376
+ };
43377
+ }
42729
43378
  function table_select_createInternalData() {
42730
43379
  return {
42731
43380
  // hpTimeout: undefined,
@@ -42799,18 +43448,7 @@ function table_select_createInternalData() {
42799
43448
  const refGridWrapper = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)();
42800
43449
  const refOptionPanel = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)();
42801
43450
  const refGrid = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)();
42802
- const reactData = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.reactive)({
42803
- initialized: false,
42804
- tableColumns: [],
42805
- fullOptionList: [],
42806
- panelIndex: 0,
42807
- panelStyle: {},
42808
- panelPlacement: null,
42809
- triggerFocusPanel: false,
42810
- visiblePanel: false,
42811
- isAniVisible: false,
42812
- isActivated: false
42813
- });
43451
+ const reactData = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.reactive)(table_select_createReactData());
42814
43452
  const internalData = table_select_createInternalData();
42815
43453
  const refMaps = {
42816
43454
  refElem
@@ -43101,12 +43739,12 @@ function table_select_createInternalData() {
43101
43739
  rowid = getRowUniqueId();
43102
43740
  }
43103
43741
  if (keyMaps[rowid]) {
43104
- errLog('vxe.error.repeatKey', [`[table-select] ${rowKeyField}`, rowid]);
43742
+ table_select_errLog('vxe.error.repeatKey', [rowKeyField, rowid]);
43105
43743
  }
43106
43744
  keyMaps[rowid] = true;
43107
43745
  const value = item[valueField];
43108
43746
  if (rowMaps[value]) {
43109
- errLog('vxe.error.repeatKey', [`[table-select] ${valueField}`, value]);
43747
+ table_select_errLog('vxe.error.repeatKey', [valueField, value]);
43110
43748
  }
43111
43749
  rowMaps[value] = {
43112
43750
  item,
@@ -43484,11 +44122,12 @@ function table_select_createInternalData() {
43484
44122
  globalEvents.off($xeTableSelect, 'mousedown');
43485
44123
  globalEvents.off($xeTableSelect, 'blur');
43486
44124
  globalEvents.off($xeTableSelect, 'resize');
44125
+ external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().assign(reactData, table_select_createReactData());
43487
44126
  external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().assign(internalData, table_select_createInternalData());
43488
44127
  });
43489
44128
  (0,external_commonjs_vue_commonjs2_vue_root_Vue_.nextTick)(() => {
43490
44129
  if (!VxeTableGridComponent) {
43491
- errLog('vxe.error.reqComp', ['[table-select] vxe-grid']);
44130
+ table_select_errLog('vxe.error.reqComp', ['vxe-grid']);
43492
44131
  }
43493
44132
  });
43494
44133
  (0,external_commonjs_vue_commonjs2_vue_root_Vue_.provide)('$xeTableSelect', $xeTableSelect);
@@ -43529,6 +44168,10 @@ const TableSelect = VxeTableSelect;
43529
44168
 
43530
44169
 
43531
44170
 
44171
+ const {
44172
+ warnLog: tabs_warnLog,
44173
+ errLog: tabs_errLog
44174
+ } = createComponentLog('tabs');
43532
44175
  const scrollbarOffsetSize = 20;
43533
44176
  /* harmony default export */ var tabs = (defineVxeComponent({
43534
44177
  name: 'VxeTabs',
@@ -43963,7 +44606,7 @@ const scrollbarOffsetSize = 20;
43963
44606
  cacheItem.loading = false;
43964
44607
  });
43965
44608
  } else {
43966
- errLog('vxe.error.notFunc', ['refresh-config.queryMethod']);
44609
+ tabs_errLog('vxe.error.notFunc', ['refresh-config.queryMethod']);
43967
44610
  }
43968
44611
  }
43969
44612
  };
@@ -44180,11 +44823,11 @@ const scrollbarOffsetSize = 20;
44180
44823
  return handlePrevNext(true);
44181
44824
  },
44182
44825
  prevTab() {
44183
- warnLog('vxe.error.delFunc', ['[tabs] prevTab', 'prev']);
44826
+ tabs_warnLog('vxe.error.delFunc', ['prevTab', 'prev']);
44184
44827
  return tabsMethods.prev();
44185
44828
  },
44186
44829
  nextTab() {
44187
- warnLog('vxe.error.delFunc', ['[tabs] nextTab', 'next']);
44830
+ tabs_warnLog('vxe.error.delFunc', ['nextTab', 'next']);
44188
44831
  return tabsMethods.next();
44189
44832
  }
44190
44833
  };
@@ -45007,6 +45650,9 @@ const Text = VxeText;
45007
45650
 
45008
45651
 
45009
45652
 
45653
+ const {
45654
+ warnLog: textarea_warnLog
45655
+ } = createComponentLog('textarea');
45010
45656
  let autoTxtElem;
45011
45657
  /* harmony default export */ var src_textarea = (defineVxeComponent({
45012
45658
  name: 'VxeTextarea',
@@ -45423,7 +46069,7 @@ let autoTxtElem;
45423
46069
  autoSize
45424
46070
  } = props;
45425
46071
  if (autosize) {
45426
- warnLog('vxe.error.delProp', ['autosize', 'auto-size']);
46072
+ textarea_warnLog('vxe.error.delProp', ['autosize', 'auto-size']);
45427
46073
  }
45428
46074
  if (autosize || autoSize) {
45429
46075
  updateAutoTxt();
@@ -45905,6 +46551,9 @@ function clearColAnimate(elem, clss) {
45905
46551
 
45906
46552
 
45907
46553
 
46554
+ const {
46555
+ errLog: tree_errLog
46556
+ } = createComponentLog('tree');
45908
46557
  const {
45909
46558
  menus: tree_menus,
45910
46559
  getConfig: tree_getConfig,
@@ -46692,7 +47341,7 @@ function tree_createReactData() {
46692
47341
  handleData(true);
46693
47342
  if (sYLoad) {
46694
47343
  if (!(props.height || props.maxHeight)) {
46695
- errLog('vxe.error.reqProp', ['[tree] height | max-height | virtual-y-config.enabled=false']);
47344
+ tree_errLog('vxe.error.reqProp', ['height | max-height | virtual-y-config.enabled=false']);
46696
47345
  }
46697
47346
  }
46698
47347
  return computeScrollLoad().then(() => {
@@ -48934,17 +49583,17 @@ function tree_createReactData() {
48934
49583
  } = props;
48935
49584
  const dragOpts = computeDragOpts.value;
48936
49585
  if (drag && !transform) {
48937
- errLog('vxe.error.notSupportProp', ['drag', 'transform=false', 'transform=true']);
49586
+ tree_errLog('vxe.error.notSupportProp', ['drag', 'transform=false', 'transform=true']);
48938
49587
  }
48939
49588
  if (dragOpts.isCrossTreeDrag) {
48940
- errLog('vxe.error.notProp', ['drag-config.isCrossTreeDrag']);
49589
+ tree_errLog('vxe.error.notProp', ['drag-config.isCrossTreeDrag']);
48941
49590
  }
48942
49591
  // if (valueField) {
48943
49592
  // errLog('vxe.error.delProp', ['value-field', 'value-field'])
48944
49593
  // }
48945
49594
  const VxeUIContextMenu = VxeUI.getComponent('VxeContextMenu');
48946
49595
  if (menuConfig && !VxeUIContextMenu) {
48947
- errLog('vxe.error.reqComp', ['vxe-context-menu']);
49596
+ tree_errLog('vxe.error.reqComp', ['vxe-context-menu']);
48948
49597
  }
48949
49598
  if (props.autoResize) {
48950
49599
  const el = refElem.value;
@@ -49013,6 +49662,10 @@ const Tree = VxeTree;
49013
49662
 
49014
49663
 
49015
49664
 
49665
+ const {
49666
+ warnLog: tree_select_warnLog,
49667
+ errLog: tree_select_errLog
49668
+ } = createComponentLog('tree-select');
49016
49669
  function tree_select_getOptUniqueId() {
49017
49670
  return external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().uniqueId('node_');
49018
49671
  }
@@ -49406,12 +50059,12 @@ function tree_select_createInternalData() {
49406
50059
  nodeid = tree_select_getOptUniqueId();
49407
50060
  }
49408
50061
  if (keyMaps[nodeid]) {
49409
- errLog('vxe.error.repeatKey', [nodeKeyField, nodeid]);
50062
+ tree_select_errLog('vxe.error.repeatKey', [nodeKeyField, nodeid]);
49410
50063
  }
49411
50064
  keyMaps[nodeid] = true;
49412
50065
  const value = item[valueField];
49413
50066
  if (nodeMaps[value]) {
49414
- errLog('vxe.error.repeatKey', [valueField, value]);
50067
+ tree_select_errLog('vxe.error.repeatKey', [valueField, value]);
49415
50068
  }
49416
50069
  nodeMaps[value] = {
49417
50070
  item,
@@ -50044,7 +50697,7 @@ function tree_select_createInternalData() {
50044
50697
  cacheLazyDataMap();
50045
50698
  (0,external_commonjs_vue_commonjs2_vue_root_Vue_.onMounted)(() => {
50046
50699
  if (external_root_XEUtils_commonjs_xe_utils_commonjs2_xe_utils_amd_xe_utils_default().isBoolean(props.autoClose)) {
50047
- warnLog('vxe.error.delProp', ['auto-close', 'checked-closable | clear-closable']);
50700
+ tree_select_warnLog('vxe.error.delProp', ['auto-close', 'checked-closable | clear-closable']);
50048
50701
  }
50049
50702
  globalEvents.on($xeTreeSelect, 'mousewheel', handleGlobalMousewheelEvent);
50050
50703
  globalEvents.on($xeTreeSelect, 'mousedown', handleGlobalMousedownEvent);
@@ -50222,6 +50875,10 @@ const saveLocalFile = options => {
50222
50875
 
50223
50876
 
50224
50877
 
50878
+ const {
50879
+ warnLog: upload_warnLog,
50880
+ errLog: upload_errLog
50881
+ } = createComponentLog('upload');
50225
50882
  function upload_createReactData() {
50226
50883
  return {
50227
50884
  isDragUploadStatus: false,
@@ -50422,7 +51079,7 @@ function upload_createInternalData() {
50422
51079
  default: () => getConfig().upload.size || getConfig().size
50423
51080
  }
50424
51081
  },
50425
- emits: ['update:modelValue', 'add', 'remove', 'remove-fail', 'download', 'download-fail', 'upload-success', 'upload-error', 'sort-dragend', 'more-visible'],
51082
+ emits: ['update:modelValue', 'add', 'remove', 'remove-fail', 'download', 'download-fail', 'upload-start', 'upload-success', 'upload-error', 'upload-end', 'upload-queue-start', 'upload-queue-end', 'sort-dragend', 'more-visible'],
50426
51083
  setup(props, context) {
50427
51084
  const {
50428
51085
  emit,
@@ -50803,6 +51460,9 @@ function upload_createInternalData() {
50803
51460
  const fileKey = getFieldKey(item);
50804
51461
  const uploadFn = props.uploadMethod || getConfig().upload.uploadMethod;
50805
51462
  if (uploadFn) {
51463
+ dispatchEvent('upload-start', {
51464
+ option: item
51465
+ }, null);
50806
51466
  return Promise.resolve(uploadFn({
50807
51467
  $upload: $xeUpload,
50808
51468
  file,
@@ -50856,6 +51516,9 @@ function upload_createInternalData() {
50856
51516
  if (cacheItem) {
50857
51517
  cacheItem.loading = false;
50858
51518
  }
51519
+ dispatchEvent('upload-end', {
51520
+ option: item
51521
+ }, null);
50859
51522
  });
50860
51523
  } else {
50861
51524
  const {
@@ -50982,6 +51645,9 @@ function upload_createInternalData() {
50982
51645
  }
50983
51646
  }
50984
51647
  }
51648
+ dispatchEvent('upload-queue-start', {
51649
+ files: selectFiles
51650
+ }, evnt);
50985
51651
  const cacheMaps = Object.assign({}, reactData.fileCacheMaps);
50986
51652
  const newFileList = multiple ? fileList : [];
50987
51653
  const uploadPromiseRests = [];
@@ -51025,6 +51691,10 @@ function upload_createInternalData() {
51025
51691
  });
51026
51692
  Promise.all(urlMode ? uploadPromiseRests : []).then(() => {
51027
51693
  const restFileList = reactData.fileList;
51694
+ dispatchEvent('upload-queue-end', {
51695
+ options: restFileList,
51696
+ files: selectFiles
51697
+ }, evnt);
51028
51698
  handleChange(restFileList);
51029
51699
  // 自动更新校验状态
51030
51700
  if ($xeForm && formItemInfo) {
@@ -52149,10 +52819,10 @@ function upload_createInternalData() {
52149
52819
  });
52150
52820
  (0,external_commonjs_vue_commonjs2_vue_root_Vue_.onMounted)(() => {
52151
52821
  if (props.multiple && props.singleMode) {
52152
- errLog('vxe.error.errConflicts', ['[upload] multiple', 'single-mode']);
52822
+ upload_errLog('vxe.error.errConflicts', ['multiple', 'single-mode']);
52153
52823
  }
52154
52824
  if (props.imageStyle) {
52155
- warnLog('vxe.error.delProp', ['[upload] image-style', 'image-config']);
52825
+ upload_warnLog('vxe.error.delProp', ['image-style', 'image-config']);
52156
52826
  }
52157
52827
  if (props.dragSort) {
52158
52828
  initTpImg();