vxe-table 3.8.3 → 3.8.4-beta.0

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 (61) hide show
  1. package/README.md +1 -0
  2. package/lib/button/src/button.js +44 -5
  3. package/lib/button/src/button.min.js +1 -1
  4. package/lib/button/src/group.js +10 -1
  5. package/lib/button/src/group.min.js +1 -1
  6. package/lib/grid/src/grid.js +3 -2
  7. package/lib/grid/src/grid.min.js +1 -1
  8. package/lib/icon/style/style.css +1 -1
  9. package/lib/icon/style/style.min.css +1 -1
  10. package/lib/index.css +1 -1
  11. package/lib/index.umd.js +125 -62
  12. package/lib/index.umd.min.js +1 -1
  13. package/lib/locale/lang/en-US.js +73 -73
  14. package/lib/locale/lang/en-US.min.js +1 -1
  15. package/lib/locale/lang/en-US.umd.js +73 -73
  16. package/lib/locale/lang/es-ES.js +9 -1
  17. package/lib/locale/lang/es-ES.min.js +1 -1
  18. package/lib/locale/lang/es-ES.umd.js +9 -1
  19. package/lib/locale/lang/ja-JP.js +156 -156
  20. package/lib/locale/lang/ja-JP.min.js +1 -1
  21. package/lib/locale/lang/ja-JP.umd.js +156 -156
  22. package/lib/locale/lang/pt-BR.js +197 -189
  23. package/lib/locale/lang/pt-BR.min.js +1 -1
  24. package/lib/locale/lang/pt-BR.umd.js +197 -189
  25. package/lib/locale/lang/zh-CN.js +51 -51
  26. package/lib/locale/lang/zh-CN.min.js +1 -1
  27. package/lib/locale/lang/zh-CN.umd.js +51 -51
  28. package/lib/locale/lang/zh-HK.min.js +1 -1
  29. package/lib/locale/lang/zh-HK.umd.js +58 -58
  30. package/lib/locale/lang/zh-MO.min.js +1 -1
  31. package/lib/locale/lang/zh-MO.umd.js +58 -58
  32. package/lib/locale/lang/zh-TC.js +58 -58
  33. package/lib/locale/lang/zh-TC.min.js +1 -1
  34. package/lib/locale/lang/zh-TC.umd.js +58 -58
  35. package/lib/locale/lang/zh-TW.min.js +1 -1
  36. package/lib/locale/lang/zh-TW.umd.js +58 -58
  37. package/lib/style.css +1 -1
  38. package/lib/style.min.css +1 -1
  39. package/lib/table/src/methods.js +13 -1
  40. package/lib/table/src/methods.min.js +1 -1
  41. package/lib/tools/log.js +1 -1
  42. package/lib/tools/log.min.js +1 -1
  43. package/lib/v-x-e-table/index.js +1 -1
  44. package/lib/v-x-e-table/index.min.js +1 -1
  45. package/package.json +1 -1
  46. package/packages/button/src/button.js +42 -9
  47. package/packages/button/src/group.js +8 -2
  48. package/packages/grid/src/grid.js +2 -2
  49. package/packages/locale/lang/en-US.js +73 -73
  50. package/packages/locale/lang/es-ES.js +9 -1
  51. package/packages/locale/lang/ja-JP.js +156 -156
  52. package/packages/locale/lang/pt-BR.js +198 -190
  53. package/packages/locale/lang/zh-CN.js +51 -51
  54. package/packages/locale/lang/zh-TC.js +58 -58
  55. package/packages/table/src/methods.js +13 -1
  56. /package/lib/icon/style/{iconfont.1714353062133.ttf → iconfont.1714444985876.ttf} +0 -0
  57. /package/lib/icon/style/{iconfont.1714353062133.woff → iconfont.1714444985876.woff} +0 -0
  58. /package/lib/icon/style/{iconfont.1714353062133.woff2 → iconfont.1714444985876.woff2} +0 -0
  59. /package/lib/{iconfont.1714353062133.ttf → iconfont.1714444985876.ttf} +0 -0
  60. /package/lib/{iconfont.1714353062133.woff → iconfont.1714444985876.woff} +0 -0
  61. /package/lib/{iconfont.1714353062133.woff2 → iconfont.1714444985876.woff2} +0 -0
@@ -52,8 +52,41 @@ export default {
52
52
  return false
53
53
  },
54
54
  btnMode () {
55
- const { mode, type } = this
56
- return (mode === 'text' || type === 'text') ? 'text' : 'button'
55
+ const { $xebuttonggroup, mode, type } = this
56
+ if (mode === 'text' || type === 'text' || ($xebuttonggroup && $xebuttonggroup.mode === 'text')) {
57
+ return 'text'
58
+ }
59
+ return 'button'
60
+ },
61
+ btnStatus () {
62
+ const { $xebuttonggroup, status } = this
63
+ if (status) {
64
+ return status
65
+ }
66
+ if ($xebuttonggroup) {
67
+ return $xebuttonggroup.status
68
+ }
69
+ return ''
70
+ },
71
+ btnRound () {
72
+ const { $xebuttonggroup, round } = this
73
+ if (round) {
74
+ return round
75
+ }
76
+ if ($xebuttonggroup) {
77
+ return $xebuttonggroup.round
78
+ }
79
+ return false
80
+ },
81
+ btnCircle () {
82
+ const { $xebuttonggroup, circle } = this
83
+ if (circle) {
84
+ return circle
85
+ }
86
+ if ($xebuttonggroup) {
87
+ return $xebuttonggroup.circle
88
+ }
89
+ return false
57
90
  }
58
91
  },
59
92
  created () {
@@ -75,7 +108,7 @@ export default {
75
108
  GlobalEvent.off(this, 'mousewheel')
76
109
  },
77
110
  render (h) {
78
- const { $scopedSlots, className, popupClassName, title, inited, type, destroyOnClose, isFormBtn, status, btnMode, vSize, name, disabled, loading, showPanel, animatVisible, panelPlacement } = this
111
+ const { $scopedSlots, className, popupClassName, title, inited, type, destroyOnClose, isFormBtn, btnMode, btnStatus, btnRound, btnCircle, vSize, name, disabled, loading, showPanel, animatVisible, panelPlacement } = this
79
112
  const downsSlot = $scopedSlots.dropdowns
80
113
  return downsSlot ? h('div', {
81
114
  class: ['vxe-button--dropdown', className ? (XEUtils.isFunction(className) ? className({ $button: this }) : className) : '', {
@@ -87,9 +120,9 @@ export default {
87
120
  ref: 'xBtn',
88
121
  class: ['vxe-button', `type--${btnMode}`, {
89
122
  [`size--${vSize}`]: vSize,
90
- [`theme--${status}`]: status,
91
- 'is--round': this.round,
92
- 'is--circle': this.circle,
123
+ [`theme--${btnStatus}`]: btnStatus,
124
+ 'is--round': btnRound,
125
+ 'is--circle': btnCircle,
93
126
  'is--disabled': disabled || loading,
94
127
  'is--loading': loading
95
128
  }],
@@ -135,9 +168,9 @@ export default {
135
168
  ref: 'xBtn',
136
169
  class: ['vxe-button', `type--${btnMode}`, className ? (XEUtils.isFunction(className) ? className({ $button: this }) : className) : '', {
137
170
  [`size--${vSize}`]: vSize,
138
- [`theme--${status}`]: status,
139
- 'is--round': this.round,
140
- 'is--circle': this.circle,
171
+ [`theme--${btnStatus}`]: btnStatus,
172
+ 'is--round': btnRound,
173
+ 'is--circle': btnCircle,
141
174
  'is--disabled': disabled || loading,
142
175
  'is--loading': loading
143
176
  }],
@@ -1,9 +1,15 @@
1
1
  import GlobalConfig from '../../v-x-e-table/src/conf'
2
+ import XEUtils from 'xe-utils'
2
3
 
3
4
  export default {
4
5
  name: 'VxeButtonGroup',
5
6
  props: {
6
7
  options: Array,
8
+ mode: String,
9
+ status: String,
10
+ round: Boolean,
11
+ circle: Boolean,
12
+ className: [String, Function],
7
13
  disabled: Boolean,
8
14
  size: { type: String, default: () => GlobalConfig.buttonGroup.size || GlobalConfig.size }
9
15
  },
@@ -18,10 +24,10 @@ export default {
18
24
  }
19
25
  },
20
26
  render (h) {
21
- const { $scopedSlots, options } = this
27
+ const { $scopedSlots, className, options } = this
22
28
  const defaultSlot = $scopedSlots.default
23
29
  return h('div', {
24
- class: 'vxe-button-group'
30
+ class: ['vxe-button-group', className ? (XEUtils.isFunction(className) ? className({ $buttonGroup: this }) : className) : '']
25
31
  }, defaultSlot ? defaultSlot.cell(this, {}) : (options ? options.map(item => h('vxe-button', { props: item })) : []))
26
32
  },
27
33
  methods: {
@@ -524,7 +524,7 @@ export default {
524
524
  * @param {String/Object} code 字符串或对象
525
525
  */
526
526
  commitProxy (proxyTarget, ...args) {
527
- const { $refs, toolbar, toolbarConfig, toolbarOpts, proxyOpts, tablePage, pagerConfig, editRules, formData, isMsg } = this
527
+ const { $refs, toolbar, toolbarConfig, toolbarOpts, proxyOpts, tablePage, pagerConfig, editRules, formData, isMsg, validConfig } = this
528
528
  const { beforeQuery, afterQuery, beforeDelete, afterDelete, beforeSave, afterSave, ajax = {}, props: proxyProps = {} } = proxyOpts
529
529
  const $xetable = $refs.xTable
530
530
  let button
@@ -745,7 +745,7 @@ export default {
745
745
  let restPromise = Promise.resolve()
746
746
  if (editRules) {
747
747
  // 只校验新增和修改的数据
748
- restPromise = this.validate(body.insertRecords.concat(updateRecords))
748
+ restPromise = this[validConfig && validConfig.msgMode === 'full' ? 'fullValidate' : 'validate'](body.insertRecords.concat(updateRecords))
749
749
  }
750
750
  return restPromise.then((errMap) => {
751
751
  if (errMap) {
@@ -268,105 +268,105 @@ export default {
268
268
  plugins: {
269
269
  extendCellArea: {
270
270
  area: {
271
- mergeErr: '无法对合并单元格进行该操作',
272
- multiErr: '无法对多重选择区域进行该操作',
273
- extendErr: '如果延伸的区域包含被合并的单元格,所有合并的单元格需大小相同',
274
- pasteMultiErr: '无法粘贴,需要相同大小的复制的区域和粘贴的区域才能执行此操作',
275
- cpInvalidErr: '该操作无法进行,您选择的区域中存在被禁止的列({0})'
271
+ mergeErr: 'The operation cannot be performed on merged cells',
272
+ multiErr: 'The operation cannot be performed on multiple selection areas',
273
+ extendErr: 'If the extended area contains merged cells, all merged cells need to be the same size',
274
+ pasteMultiErr: 'Cannot paste, copied area and pasted area of the same size are required to perform this operation',
275
+ cpInvalidErr: 'This operation cannot be performed because there are prohibited columns in the area you selected ({0})'
276
276
  },
277
277
  fnr: {
278
- title: '查找和替换',
279
- findLabel: '查找',
280
- replaceLabel: '替换',
281
- findTitle: '查找内容:',
282
- replaceTitle: '替换为:',
278
+ title: 'Find and replace',
279
+ findLabel: 'Find',
280
+ replaceLabel: 'Replace',
281
+ findTitle: 'What to find:',
282
+ replaceTitle: 'Replace with:',
283
283
  tabs: {
284
- find: '查找',
285
- replace: '替换'
284
+ find: 'Find',
285
+ replace: 'Replace'
286
286
  },
287
287
  filter: {
288
- re: '正则表达式',
289
- whole: '全词匹配',
290
- sensitive: '区分大小写'
288
+ re: 'Regular Expression',
289
+ whole: 'Whole word',
290
+ sensitive: 'Case sensitive'
291
291
  },
292
292
  btns: {
293
- findNext: '查找下一个',
294
- findAll: '查找全部',
295
- replace: '替换',
296
- replaceAll: '替换全部',
297
- cancel: '取消'
293
+ findNext: 'Find next',
294
+ findAll: 'Find all',
295
+ replace: 'Replace',
296
+ replaceAll: 'Replace all',
297
+ cancel: 'Cancel'
298
298
  },
299
299
  header: {
300
300
  seq: '#',
301
- cell: '单元格',
302
- value: '值'
301
+ cell: 'Cell',
302
+ value: 'Value'
303
303
  },
304
- empty: '(空值)',
305
- reError: '无效的正则表达式',
306
- recordCount: '已找到 {0} 个单元格',
307
- notCell: '找不到匹配的单元格',
308
- replaceSuccess: '成功替换 {0} 个单元格'
304
+ empty: '(Empty)',
305
+ reError: 'Invalid regular expression',
306
+ recordCount: 'Found {0} cells',
307
+ notCell: 'No matching cells were found',
308
+ replaceSuccess: 'Successfully replaced {0} cells'
309
309
  }
310
310
  },
311
311
  filterComplexInput: {
312
312
  menus: {
313
- fixedColumn: '锁定列',
314
- fixedGroup: '锁定组',
315
- cancelFixed: '取消锁定',
316
- fixedLeft: '锁定左侧',
317
- fixedRight: '锁定右侧'
313
+ fixedColumn: 'Freeze column',
314
+ fixedGroup: 'Freeze group',
315
+ cancelFixed: 'Clear freeze',
316
+ fixedLeft: 'Freeze the left',
317
+ fixedRight: 'Freeze the right'
318
318
  },
319
319
  cases: {
320
- equal: '等于',
321
- gt: '大于',
322
- lt: '小于',
323
- begin: '开头是',
324
- endin: '结尾是',
325
- include: '包含',
326
- isSensitive: '区分大小写'
320
+ equal: 'Equal',
321
+ gt: 'Greater than',
322
+ lt: 'Less than',
323
+ begin: 'Beginning is',
324
+ endin: 'End is',
325
+ include: 'Include',
326
+ isSensitive: 'Case sensitive'
327
327
  }
328
328
  },
329
329
  filterCombination: {
330
330
  menus: {
331
- clearSort: '清除排序',
332
- sortAsc: '升序',
333
- sortDesc: '降序',
334
- fixedColumn: '锁定列',
335
- fixedGroup: '锁定组',
336
- cancelFixed: '取消锁定',
337
- fixedLeft: '锁定左侧',
338
- fixedRight: '锁定右侧',
339
- clearFilter: '清除筛选',
340
- textOption: '文本筛选',
341
- numberOption: '数值筛选'
331
+ clearSort: 'Clear sort',
332
+ sortAsc: 'Ascending order',
333
+ sortDesc: 'Descending order',
334
+ fixedColumn: 'Freeze column',
335
+ fixedGroup: 'Freeze group',
336
+ cancelFixed: 'Clear freeze',
337
+ fixedLeft: 'Freeze the left',
338
+ fixedRight: 'Freeze the right',
339
+ clearFilter: 'Clear filter',
340
+ textOption: 'Text filter',
341
+ numberOption: 'Number filter'
342
342
  },
343
343
  popup: {
344
- title: '自定义筛选的方式',
345
- currColumnTitle: '当前列:',
346
- and: '与',
347
- or: '或',
348
- describeHtml: '可用 ? 代表单个字符<br/>用 * 代表任意多个字符'
344
+ title: 'Custom filtering',
345
+ currColumnTitle: 'Current column:',
346
+ and: 'And',
347
+ or: 'Or',
348
+ describeHtml: 'Use ? To represent a single character <br/> use * to represent any number of characters'
349
349
  },
350
350
  cases: {
351
- equal: '等于',
352
- unequal: '不等于',
353
- gt: '大于',
354
- ge: '大于或等于',
355
- lt: '小于',
356
- le: '小于或等于',
357
- begin: '开头是',
358
- notbegin: '开头不是',
359
- endin: '结尾是',
360
- notendin: '结尾不是',
361
- include: '包含',
362
- exclude: '不包含',
363
- between: '介于',
364
- custom: '自定义筛选',
365
- insensitive: '不区分大小写',
366
- isSensitive: '区分大小写'
351
+ equal: 'Equal',
352
+ unequal: 'Not equal',
353
+ gt: 'Greater than',
354
+ ge: 'Greater than or equal',
355
+ lt: 'Less than',
356
+ le: 'Less than or equal',
357
+ begin: 'Beginning is',
358
+ notbegin: 'Beginning is not',
359
+ endin: 'End is',
360
+ notendin: 'End is not',
361
+ include: 'Include',
362
+ exclude: 'Exclusive',
363
+ between: 'Betweenness',
364
+ custom: 'Custom filter',
365
+ insensitive: 'Case insensitive',
366
+ isSensitive: 'Case sensitive'
367
367
  },
368
- empty: '(空白)',
369
- notData: '无匹配项'
368
+ empty: '(Empty)',
369
+ notData: 'No data'
370
370
  }
371
371
  },
372
372
 
@@ -82,10 +82,18 @@ export default {
82
82
  pagesize: '{0}/página',
83
83
  total: 'Total {0} registro',
84
84
  pageClassifier: '',
85
+ homePage: 'Home',
86
+ homePageTitle: 'Home page',
85
87
  prevPage: 'Página anterior',
88
+ prevPageTitle: 'Previous page',
86
89
  nextPage: 'Siguiente página',
90
+ nextPageTitle: 'next page',
87
91
  prevJump: 'Saltar página anterior',
88
- nextJump: 'Saltar siguiente página'
92
+ prevJumpTitle: 'Jump previous page',
93
+ nextJump: 'Saltar siguiente página',
94
+ nextJumpTitle: 'Jump next page',
95
+ endPage: 'End page',
96
+ endPageTitle: 'End'
89
97
  },
90
98
  alert: {
91
99
  title: 'System messages'