vxe-table 4.3.1 → 4.3.4

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 (97) hide show
  1. package/es/edit/src/hook.js +3 -0
  2. package/es/filter/src/panel.js +2 -1
  3. package/es/form/src/form-item.js +19 -6
  4. package/es/form/src/render.js +2 -1
  5. package/es/loading/index.d.ts +4 -0
  6. package/es/loading/style.css +98 -0
  7. package/es/locale/lang/en-US.js +1 -0
  8. package/es/locale/lang/ja-JP.js +1 -0
  9. package/es/locale/lang/zh-CN.js +1 -0
  10. package/es/locale/lang/zh-TC.js +1 -0
  11. package/es/style.css +1 -1
  12. package/es/style.min.css +1 -1
  13. package/es/table/src/body.js +2 -1
  14. package/es/table/src/table.js +1 -1
  15. package/es/table/style.css +89 -0
  16. package/es/toolbar/src/toolbar.js +2 -2
  17. package/es/tools/log.js +1 -1
  18. package/es/v-x-e-table/index.js +1 -1
  19. package/es/v-x-e-table/style.css +1 -0
  20. package/es/vxe-loading/index.d.ts +4 -0
  21. package/es/vxe-loading/index.js +3 -0
  22. package/es/vxe-loading/style.css +98 -0
  23. package/es/vxe-table/style.css +89 -0
  24. package/lib/edit/src/hook.js +4 -0
  25. package/lib/edit/src/hook.min.js +1 -1
  26. package/lib/filter/src/panel.js +3 -1
  27. package/lib/filter/src/panel.min.js +1 -1
  28. package/lib/form/src/form-item.js +18 -4
  29. package/lib/form/src/form-item.min.js +1 -1
  30. package/lib/form/src/render.js +3 -1
  31. package/lib/form/src/render.min.js +1 -1
  32. package/lib/index.umd.js +37 -15
  33. package/lib/index.umd.min.js +1 -1
  34. package/lib/loading/index.d.ts +4 -0
  35. package/lib/loading/style/index.js +1 -0
  36. package/lib/loading/style/style.css +98 -0
  37. package/lib/loading/style/style.min.css +1 -0
  38. package/lib/locale/lang/en-US.js +1 -0
  39. package/lib/locale/lang/en-US.min.js +1 -1
  40. package/lib/locale/lang/en-US.umd.js +1 -0
  41. package/lib/locale/lang/ja-JP.js +1 -0
  42. package/lib/locale/lang/ja-JP.min.js +1 -1
  43. package/lib/locale/lang/ja-JP.umd.js +1 -0
  44. package/lib/locale/lang/zh-CN.js +1 -0
  45. package/lib/locale/lang/zh-CN.min.js +1 -1
  46. package/lib/locale/lang/zh-CN.umd.js +1 -0
  47. package/lib/locale/lang/zh-HK.min.js +1 -1
  48. package/lib/locale/lang/zh-HK.umd.js +1 -0
  49. package/lib/locale/lang/zh-MO.min.js +1 -1
  50. package/lib/locale/lang/zh-MO.umd.js +1 -0
  51. package/lib/locale/lang/zh-TC.js +1 -0
  52. package/lib/locale/lang/zh-TC.min.js +1 -1
  53. package/lib/locale/lang/zh-TC.umd.js +1 -0
  54. package/lib/locale/lang/zh-TW.min.js +1 -1
  55. package/lib/locale/lang/zh-TW.umd.js +1 -0
  56. package/lib/style.css +1 -1
  57. package/lib/style.min.css +1 -1
  58. package/lib/table/src/body.js +4 -2
  59. package/lib/table/src/body.min.js +1 -1
  60. package/lib/table/src/table.js +1 -1
  61. package/lib/table/src/table.min.js +1 -1
  62. package/lib/table/style/style.css +89 -0
  63. package/lib/table/style/style.min.css +1 -1
  64. package/lib/toolbar/src/toolbar.js +4 -4
  65. package/lib/toolbar/src/toolbar.min.js +1 -1
  66. package/lib/tools/log.js +1 -1
  67. package/lib/tools/log.min.js +1 -1
  68. package/lib/v-x-e-table/index.js +1 -1
  69. package/lib/v-x-e-table/index.min.js +1 -1
  70. package/lib/v-x-e-table/style/style.css +1 -0
  71. package/lib/vxe-loading/index.d.ts +4 -0
  72. package/lib/vxe-loading/index.js +30 -0
  73. package/lib/vxe-loading/index.min.js +1 -0
  74. package/lib/vxe-loading/style/style.css +98 -0
  75. package/lib/vxe-loading/style/style.min.css +1 -0
  76. package/lib/vxe-table/style/style.css +89 -0
  77. package/lib/vxe-table/style/style.min.css +1 -1
  78. package/package.json +4 -4
  79. package/packages/edit/src/hook.ts +3 -0
  80. package/packages/filter/src/panel.ts +2 -1
  81. package/packages/form/src/form-item.ts +19 -6
  82. package/packages/form/src/render.ts +2 -1
  83. package/packages/loading/index.d.ts +4 -0
  84. package/packages/locale/lang/en-US.ts +1 -0
  85. package/packages/locale/lang/ja-JP.ts +1 -0
  86. package/packages/locale/lang/zh-CN.ts +1 -0
  87. package/packages/locale/lang/zh-TC.ts +1 -0
  88. package/packages/table/src/body.ts +2 -1
  89. package/packages/table/src/table.ts +1 -1
  90. package/packages/toolbar/src/toolbar.ts +2 -2
  91. package/styles/footer.scss +0 -22
  92. package/styles/loading.scss +2 -0
  93. package/styles/modules.scss +1 -6
  94. package/styles/table.scss +24 -0
  95. package/types/all.d.ts +4 -2
  96. package/types/loading.d.ts +10 -0
  97. package/types/v-x-e-table/renderer.d.ts +1 -0
@@ -712,6 +712,9 @@ var editHook = {
712
712
  if (!autofocus && compRender) {
713
713
  autofocus = compRender.autofocus;
714
714
  }
715
+ if (!autoselect && compRender) {
716
+ autoselect = compRender.autoselect;
717
+ }
715
718
  // 如果指定了聚焦 class
716
719
  if (XEUtils.isFunction(autofocus)) {
717
720
  inputElem = autofocus.call(this, params);
@@ -3,6 +3,7 @@ import GlobalConfig from '../../v-x-e-table/src/conf';
3
3
  import { VXETable } from '../../v-x-e-table';
4
4
  import { formatText } from '../../tools/utils';
5
5
  import { getPropClass } from '../../tools/dom';
6
+ import { getSlotVNs } from '../../tools/vn';
6
7
  export default defineComponent({
7
8
  name: 'VxeTableFilter',
8
9
  props: {
@@ -108,7 +109,7 @@ export default defineComponent({
108
109
  return [
109
110
  h('div', {
110
111
  class: 'vxe-table--filter-template'
111
- }, compConf.renderFilter(filterRender, params))
112
+ }, getSlotVNs(compConf.renderFilter(filterRender, params)))
112
113
  ];
113
114
  }
114
115
  var isAllChecked = multiple ? filterStore.isAllSelected : !filterStore.options.some(function (item) { return item._checked; });
@@ -22,8 +22,14 @@ export var formItemProps = {
22
22
  field: String,
23
23
  span: [String, Number],
24
24
  align: String,
25
- titleAlign: String,
26
- titleWidth: [String, Number],
25
+ titleAlign: {
26
+ type: String,
27
+ default: null
28
+ },
29
+ titleWidth: {
30
+ type: [String, Number],
31
+ default: null
32
+ },
27
33
  titleColon: {
28
34
  type: Boolean,
29
35
  default: null
@@ -33,7 +39,10 @@ export var formItemProps = {
33
39
  default: null
34
40
  },
35
41
  className: [String, Function],
36
- titleOverflow: { type: [Boolean, String], default: null },
42
+ titleOverflow: {
43
+ type: [Boolean, String],
44
+ default: null
45
+ },
37
46
  titlePrefix: Object,
38
47
  titleSuffix: Object,
39
48
  resetValue: { default: null },
@@ -67,7 +76,7 @@ export default defineComponent({
67
76
  });
68
77
  var renderItem = function ($xeform, item) {
69
78
  var props = $xeform.props, reactData = $xeform.reactData;
70
- var data = props.data, rules = props.rules, allTitleOverflow = props.titleOverflow;
79
+ var data = props.data, rules = props.rules, allTitleAlign = props.titleAlign, allTitleWidth = props.titleWidth, allTitleColon = props.titleColon, allTitleAsterisk = props.titleAsterisk, allTitleOverflow = props.titleOverflow;
71
80
  var collapseAll = reactData.collapseAll;
72
81
  var computeValidOpts = $xeform.getComputeMaps().computeValidOpts;
73
82
  var validOpts = computeValidOpts.value;
@@ -78,8 +87,10 @@ export default defineComponent({
78
87
  var titleSlot = slots ? slots.title : null;
79
88
  var span = item.span || props.span;
80
89
  var align = item.align || props.align;
81
- var titleAlign = item.titleAlign || props.titleAlign;
82
- var titleWidth = item.titleWidth || props.titleWidth;
90
+ var titleAlign = XEUtils.eqNull(item.titleAlign) ? allTitleAlign : item.titleAlign;
91
+ var titleWidth = XEUtils.eqNull(item.titleWidth) ? allTitleWidth : item.titleWidth;
92
+ var titleColon = XEUtils.eqNull(item.titleColon) ? allTitleColon : item.titleColon;
93
+ var titleAsterisk = XEUtils.eqNull(item.titleAsterisk) ? allTitleAsterisk : item.titleAsterisk;
83
94
  var itemOverflow = (XEUtils.isUndefined(titleOverflow) || XEUtils.isNull(titleOverflow)) ? allTitleOverflow : titleOverflow;
84
95
  var showEllipsis = itemOverflow === 'ellipsis';
85
96
  var showTitle = itemOverflow === 'title';
@@ -143,6 +154,8 @@ export default defineComponent({
143
154
  itemClassName ? (XEUtils.isFunction(itemClassName) ? itemClassName(params) : itemClassName) : '',
144
155
  {
145
156
  'is--title': title,
157
+ 'is--colon': titleColon,
158
+ 'is--asterisk': titleAsterisk,
146
159
  'is--required': isRequired,
147
160
  'is--hidden': folding && collapseAll,
148
161
  'is--active': isActivetem($xeform, item),
@@ -13,6 +13,7 @@ import { h, resolveComponent } from 'vue';
13
13
  import GlobalConfig from '../../v-x-e-table/src/conf';
14
14
  import { VXETable } from '../../v-x-e-table';
15
15
  import { getFuncText, isEnableConf } from '../../tools/utils';
16
+ import { getSlotVNs } from '../../tools/vn';
16
17
  function renderPrefixIcon(titlePrefix) {
17
18
  return h('span', {
18
19
  class: 'vxe-form--item-title-prefix'
@@ -50,7 +51,7 @@ export function renderTitle($xeform, item) {
50
51
  }
51
52
  titVNs.push(h('span', {
52
53
  class: 'vxe-form--item-title-label'
53
- }, compConf && compConf.renderItemTitle ? compConf.renderItemTitle(itemRender, params) : (titleSlot ? $xeform.callSlot(titleSlot, params) : getFuncText(item.title))));
54
+ }, compConf && compConf.renderItemTitle ? getSlotVNs(compConf.renderItemTitle(itemRender, params)) : (titleSlot ? $xeform.callSlot(titleSlot, params) : getFuncText(item.title))));
54
55
  contVNs.push(h('div', {
55
56
  class: 'vxe-form--item-title-content'
56
57
  }, titVNs));
@@ -0,0 +1,4 @@
1
+ import { VxeLoading } from '../../types/loading'
2
+
3
+ export * from '../../types/loading'
4
+ export default VxeLoading
@@ -0,0 +1,98 @@
1
+ @charset "UTF-8";
2
+ /*font*/
3
+ /*size*/
4
+ /*icon*/
5
+ /*color*/
6
+ /*input/radio/checkbox*/
7
+ /*popup*/
8
+ /*table*/
9
+ /*filter*/
10
+ /*menu*/
11
+ /*loading*/
12
+ /*validate*/
13
+ /*grid*/
14
+ /*toolbar*/
15
+ /*tooltip*/
16
+ /*pager*/
17
+ /*modal*/
18
+ /*checkbox*/
19
+ /*radio*/
20
+ /*button*/
21
+ /*input*/
22
+ /*textarea*/
23
+ /*form*/
24
+ /*select*/
25
+ /*switch*/
26
+ /*pulldown*/
27
+ /*加载中*/
28
+ .vxe-loading {
29
+ display: none;
30
+ position: absolute;
31
+ width: 100%;
32
+ height: 100%;
33
+ top: 0;
34
+ left: 0;
35
+ z-index: 99;
36
+ -webkit-user-select: none;
37
+ -moz-user-select: none;
38
+ -ms-user-select: none;
39
+ user-select: none;
40
+ background-color: rgba(255, 255, 255, 0.5); }
41
+ .vxe-loading.is--visible {
42
+ display: block; }
43
+ .vxe-loading > .vxe-loading--chunk {
44
+ width: 100%;
45
+ position: absolute;
46
+ top: 50%;
47
+ left: 0;
48
+ transform: translateY(-50%);
49
+ text-align: center;
50
+ color: #409eff; }
51
+ .vxe-loading .vxe-loading--default-icon {
52
+ font-size: 1.4em; }
53
+ .vxe-loading .vxe-loading--text {
54
+ padding: 0.4em 0; }
55
+ .vxe-loading .vxe-loading--spinner {
56
+ display: inline-block;
57
+ position: relative;
58
+ width: 56px;
59
+ height: 56px; }
60
+ .vxe-loading .vxe-loading--spinner:before, .vxe-loading .vxe-loading--spinner:after {
61
+ content: "";
62
+ width: 100%;
63
+ height: 100%;
64
+ border-radius: 50%;
65
+ background-color: #409eff;
66
+ opacity: 0.6;
67
+ position: absolute;
68
+ top: 0;
69
+ left: 0;
70
+ -webkit-animation: bounce 2.0s infinite ease-in-out;
71
+ animation: bounce 2.0s infinite ease-in-out; }
72
+ .vxe-loading .vxe-loading--spinner:after {
73
+ -webkit-animation-delay: -1.0s;
74
+ animation-delay: -1.0s; }
75
+
76
+ @-webkit-keyframes bounce {
77
+ 0%, 100% {
78
+ transform: scale(0); }
79
+ 50% {
80
+ transform: scale(1); } }
81
+
82
+ @keyframes bounce {
83
+ 0%, 100% {
84
+ transform: scale(0); }
85
+ 50% {
86
+ transform: scale(1); } }
87
+
88
+ .size--mini .vxe-loading .vxe-loading--spinner {
89
+ width: 38px;
90
+ height: 38px; }
91
+
92
+ .size--small .vxe-loading .vxe-loading--spinner {
93
+ width: 44px;
94
+ height: 44px; }
95
+
96
+ .size--medium .vxe-loading .vxe-loading--spinner {
97
+ width: 50px;
98
+ height: 50px; }
@@ -56,6 +56,7 @@ export default {
56
56
  },
57
57
  combination: {
58
58
  menus: {
59
+ clearSort: 'Clear sort',
59
60
  sortAsc: 'Ascending order',
60
61
  sortDesc: 'Descending order',
61
62
  fixedColumn: 'Fixed column',
@@ -56,6 +56,7 @@ export default {
56
56
  },
57
57
  combination: {
58
58
  menus: {
59
+ clearSort: '清除排序',
59
60
  sortAsc: '升序',
60
61
  sortDesc: '降序',
61
62
  fixedColumn: '锁定列',
@@ -56,6 +56,7 @@ export default {
56
56
  },
57
57
  combination: {
58
58
  menus: {
59
+ clearSort: '清除排序',
59
60
  sortAsc: '升序',
60
61
  sortDesc: '降序',
61
62
  fixedColumn: '锁定列',
@@ -56,6 +56,7 @@ export default {
56
56
  },
57
57
  combination: {
58
58
  menus: {
59
+ clearSort: '清除排序',
59
60
  sortAsc: '昇冪',
60
61
  sortDesc: '降序',
61
62
  fixedColumn: '鎖定列',