vxe-pc-ui 3.18.2 → 3.18.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 (93) hide show
  1. package/es/button/src/button.js +11 -3
  2. package/es/button/style.css +1 -4
  3. package/es/button/style.min.css +1 -1
  4. package/es/color-picker/src/color-picker.js +14 -1
  5. package/es/date-picker/src/date-picker.js +14 -1
  6. package/es/date-range-picker/src/date-range-picker.js +14 -1
  7. package/es/icon/style.css +1 -1
  8. package/es/icon-picker/src/icon-picker.js +18 -5
  9. package/es/input/src/input.js +14 -1
  10. package/es/modal/src/modal.js +1 -1
  11. package/es/number-input/src/number-input.js +12 -1
  12. package/es/password-input/src/password-input.js +14 -0
  13. package/es/select/src/select.js +20 -7
  14. package/es/space/src/space.js +8 -4
  15. package/es/style.css +1 -1
  16. package/es/style.min.css +1 -1
  17. package/es/ui/index.js +3 -2
  18. package/es/ui/src/log.js +1 -1
  19. package/es/vxe-button/style.css +1 -4
  20. package/es/vxe-button/style.min.css +1 -1
  21. package/lib/button/src/button.js +16 -2
  22. package/lib/button/src/button.min.js +1 -1
  23. package/lib/button/style/style.css +1 -4
  24. package/lib/button/style/style.min.css +1 -1
  25. package/lib/color-picker/src/color-picker.js +14 -1
  26. package/lib/color-picker/src/color-picker.min.js +1 -1
  27. package/lib/date-picker/src/date-picker.js +13 -0
  28. package/lib/date-picker/src/date-picker.min.js +1 -1
  29. package/lib/date-range-picker/src/date-range-picker.js +13 -0
  30. package/lib/date-range-picker/src/date-range-picker.min.js +1 -1
  31. package/lib/icon/style/style.css +1 -1
  32. package/lib/icon/style/style.min.css +1 -1
  33. package/lib/icon-picker/src/icon-picker.js +18 -5
  34. package/lib/icon-picker/src/icon-picker.min.js +1 -1
  35. package/lib/index.umd.js +150 -23
  36. package/lib/index.umd.min.js +1 -1
  37. package/lib/input/src/input.js +13 -0
  38. package/lib/input/src/input.min.js +1 -1
  39. package/lib/modal/src/modal.js +3 -1
  40. package/lib/modal/src/modal.min.js +1 -1
  41. package/lib/number-input/src/number-input.js +11 -0
  42. package/lib/number-input/src/number-input.min.js +1 -1
  43. package/lib/password-input/src/password-input.js +14 -0
  44. package/lib/password-input/src/password-input.min.js +1 -1
  45. package/lib/select/src/select.js +20 -7
  46. package/lib/select/src/select.min.js +1 -1
  47. package/lib/space/src/space.js +9 -4
  48. package/lib/space/src/space.min.js +1 -1
  49. package/lib/style.css +1 -1
  50. package/lib/style.min.css +1 -1
  51. package/lib/ui/index.js +3 -2
  52. package/lib/ui/index.min.js +1 -1
  53. package/lib/ui/src/log.js +1 -1
  54. package/lib/ui/src/log.min.js +1 -1
  55. package/lib/vxe-button/style/style.css +1 -4
  56. package/lib/vxe-button/style/style.min.css +1 -1
  57. package/package.json +1 -1
  58. package/packages/button/src/button.ts +12 -4
  59. package/packages/color-picker/src/color-picker.ts +16 -2
  60. package/packages/date-picker/src/date-picker.ts +16 -2
  61. package/packages/date-range-picker/src/date-range-picker.ts +16 -2
  62. package/packages/icon-picker/src/icon-picker.ts +19 -5
  63. package/packages/input/src/input.ts +15 -1
  64. package/packages/modal/src/modal.ts +1 -1
  65. package/packages/number-input/src/number-input.ts +14 -2
  66. package/packages/password-input/src/password-input.ts +16 -1
  67. package/packages/select/src/select.ts +21 -7
  68. package/packages/space/src/space.ts +8 -4
  69. package/packages/ui/index.ts +2 -1
  70. package/styles/components/button.scss +1 -4
  71. package/types/components/button.d.ts +5 -0
  72. package/types/components/color-picker.d.ts +2 -0
  73. package/types/components/date-picker.d.ts +2 -0
  74. package/types/components/date-range-picker.d.ts +2 -0
  75. package/types/components/icon-picker.d.ts +2 -0
  76. package/types/components/input.d.ts +5 -0
  77. package/types/components/number-input.d.ts +5 -0
  78. package/types/components/password-input.d.ts +5 -0
  79. package/types/components/select.d.ts +5 -0
  80. package/types/components/space.d.ts +5 -0
  81. package/types/ui/global-icon.d.ts +2 -1
  82. /package/es/icon/{iconfont.1788693899721.ttf → iconfont.1788753692225.ttf} +0 -0
  83. /package/es/icon/{iconfont.1788693899721.woff → iconfont.1788753692225.woff} +0 -0
  84. /package/es/icon/{iconfont.1788693899721.woff2 → iconfont.1788753692225.woff2} +0 -0
  85. /package/es/{iconfont.1788693899721.ttf → iconfont.1788753692225.ttf} +0 -0
  86. /package/es/{iconfont.1788693899721.woff → iconfont.1788753692225.woff} +0 -0
  87. /package/es/{iconfont.1788693899721.woff2 → iconfont.1788753692225.woff2} +0 -0
  88. /package/lib/icon/style/{iconfont.1788693899721.ttf → iconfont.1788753692225.ttf} +0 -0
  89. /package/lib/icon/style/{iconfont.1788693899721.woff → iconfont.1788753692225.woff} +0 -0
  90. /package/lib/icon/style/{iconfont.1788693899721.woff2 → iconfont.1788753692225.woff2} +0 -0
  91. /package/lib/{iconfont.1788693899721.ttf → iconfont.1788753692225.ttf} +0 -0
  92. /package/lib/{iconfont.1788693899721.woff → iconfont.1788753692225.woff} +0 -0
  93. /package/lib/{iconfont.1788693899721.woff2 → iconfont.1788753692225.woff2} +0 -0
@@ -3,6 +3,7 @@ import XEUtils from 'xe-utils';
3
3
  import { getConfig, getIcon, getI18n, createEvent, globalMixins, renderEmptyElement } from '../../ui';
4
4
  import { getFuncText, getText } from '../../ui/src/utils';
5
5
  import { getSlotVNs } from '../../ui/src/vn';
6
+ import { toCssUnit } from '../../ui/src/dom';
6
7
  export default {
7
8
  name: 'VxePasswordInput',
8
9
  mixins: [
@@ -44,6 +45,7 @@ export default {
44
45
  type: String,
45
46
  default: () => getConfig().passwordInput.inputClassName
46
47
  },
48
+ width: [String, Number],
47
49
  size: {
48
50
  type: String,
49
51
  default: () => getConfig().passwordInput.size || getConfig().size
@@ -153,6 +155,16 @@ export default {
153
155
  const { editable } = props;
154
156
  const formReadonly = $xePasswordInput.computeFormReadonly;
155
157
  return formReadonly || !editable;
158
+ },
159
+ computeCurrStyle() {
160
+ const $xePasswordInput = this;
161
+ const props = $xePasswordInput;
162
+ const { width } = props;
163
+ const stys = {};
164
+ if (width) {
165
+ stys.width = toCssUnit(width);
166
+ }
167
+ return stys;
156
168
  } }),
157
169
  methods: {
158
170
  //
@@ -413,6 +425,7 @@ export default {
413
425
  class: ['vxe-password-input--readonly', className]
414
426
  }, getText(inputValue));
415
427
  }
428
+ const currStyle = $xePasswordInput.computeCurrStyle;
416
429
  const vSize = $xePasswordInput.computeSize;
417
430
  const inputType = $xePasswordInput.computeInputType;
418
431
  const inpPlaceholder = $xePasswordInput.computeInpPlaceholder;
@@ -432,6 +445,7 @@ export default {
432
445
  'is--active': isActivated,
433
446
  'show--clear': isClearable && !isDisabled && !(inputValue === '' || XEUtils.eqNull(inputValue))
434
447
  }],
448
+ style: currStyle,
435
449
  attrs: {
436
450
  spellcheck: false
437
451
  }
@@ -111,6 +111,7 @@ export default {
111
111
  * @deprecated
112
112
  */
113
113
  popupClassName: [String, Function],
114
+ width: [String, Number],
114
115
  max: {
115
116
  type: [String, Number],
116
117
  default: null
@@ -372,6 +373,16 @@ export default {
372
373
  const props = $xeSelect;
373
374
  return XEUtils.toNumber(props.multiCharOverflow);
374
375
  },
376
+ computeCurrStyle() {
377
+ const $xeSelect = this;
378
+ const props = $xeSelect;
379
+ const { width } = props;
380
+ const stys = {};
381
+ if (width) {
382
+ stys.width = toCssUnit(width);
383
+ }
384
+ return stys;
385
+ },
375
386
  computePopupWrapperStyle() {
376
387
  const $xeSelect = this;
377
388
  const popupOpts = $xeSelect.computePopupOpts;
@@ -1793,13 +1804,7 @@ export default {
1793
1804
  const btnTransfer = $xeSelect.computeBtnTransfer;
1794
1805
  const formReadonly = $xeSelect.computeFormReadonly;
1795
1806
  const inpPlaceholder = $xeSelect.computeInpPlaceholder;
1796
- const popupOpts = $xeSelect.computePopupOpts;
1797
- const popupWrapperStyle = $xeSelect.computePopupWrapperStyle;
1798
1807
  const defaultSlot = slots.default;
1799
- const headerSlot = slots.header;
1800
- const footerSlot = slots.footer;
1801
- const prefixSlot = slots.prefix;
1802
- const ppClassName = popupOpts.className || props.popupClassName;
1803
1808
  if (formReadonly) {
1804
1809
  return h('div', {
1805
1810
  ref: 'refElem',
@@ -1817,7 +1822,14 @@ export default {
1817
1822
  }, selectLabel)
1818
1823
  ]);
1819
1824
  }
1825
+ const currStyle = $xeSelect.computeCurrStyle;
1820
1826
  const selectVals = $xeSelect.computeSelectVals;
1827
+ const popupOpts = $xeSelect.computePopupOpts;
1828
+ const popupWrapperStyle = $xeSelect.computePopupWrapperStyle;
1829
+ const headerSlot = slots.header;
1830
+ const footerSlot = slots.footer;
1831
+ const prefixSlot = slots.prefix;
1832
+ const ppClassName = popupOpts.className || props.popupClassName;
1821
1833
  return h('div', {
1822
1834
  ref: 'refElem',
1823
1835
  class: ['vxe-select', className ? (XEUtils.isFunction(className) ? className({ $select: $xeSelect }) : className) : '', {
@@ -1827,7 +1839,8 @@ export default {
1827
1839
  'is--filter': filterable,
1828
1840
  'is--loading': loading,
1829
1841
  'is--active': isActivated
1830
- }]
1842
+ }],
1843
+ style: currStyle
1831
1844
  }, [
1832
1845
  h('div', {
1833
1846
  class: 'vxe-select-slots',
@@ -18,6 +18,7 @@ export default {
18
18
  type: Boolean,
19
19
  default: () => getConfig().space.wrap
20
20
  },
21
+ width: [Number, String],
21
22
  gap: {
22
23
  type: [Number, String, Array, Object],
23
24
  default: () => getConfig().space.gap
@@ -73,10 +74,10 @@ export default {
73
74
  reactData
74
75
  };
75
76
  },
76
- computed: Object.assign(Object.assign({}, {}), { computeWrapperStyle() {
77
+ computed: Object.assign(Object.assign({}, {}), { computeCurrStyle() {
77
78
  const $xeSpace = this;
78
79
  const props = $xeSpace;
79
- const { align, gap } = props;
80
+ const { align, gap, width } = props;
80
81
  const stys = {};
81
82
  let rowGap = '';
82
83
  let columGap = '';
@@ -94,6 +95,9 @@ export default {
94
95
  columGap = gap.columGap || '';
95
96
  }
96
97
  }
98
+ if (width) {
99
+ stys.width = toCssUnit(width);
100
+ }
97
101
  if (align) {
98
102
  stys['align-items'] = align;
99
103
  }
@@ -158,7 +162,7 @@ export default {
158
162
  const $xeSpace = this;
159
163
  const props = $xeSpace;
160
164
  const { vertical, wrap, className, fill, itemWidth, itemMinWidth, itemMaxWidth } = props;
161
- const wrapperStyle = $xeSpace.computeWrapperStyle;
165
+ const currStyle = $xeSpace.computeCurrStyle;
162
166
  const vSize = $xeSpace.computeSize;
163
167
  return h('div', {
164
168
  ref: 'refElem',
@@ -169,7 +173,7 @@ export default {
169
173
  'is--fill': fill,
170
174
  'is--width': itemWidth || itemMinWidth || itemMaxWidth
171
175
  }],
172
- style: wrapperStyle
176
+ style: currStyle
173
177
  }, $xeSpace.renderItems(h));
174
178
  }
175
179
  },