dfish-widget 0.1.357 → 0.1.361

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.
package/lib/index.esm.js CHANGED
@@ -202,7 +202,7 @@ var loc = {
202
202
  jigsaw_required: '请完成滑块验证',
203
203
  jigsaw_errorimg: '图片数据异常',
204
204
  upload_loading: '正在上传,请稍候..',
205
- upload_invalid_file: '无效文件',
205
+ upload_invalid_file: '存在无效文件',
206
206
  no_files: '<没有文件>',
207
207
  upload_error: '(上传失败)',
208
208
  upload_limit: '上传数量超过上限(最多{0}个)',
@@ -2132,7 +2132,7 @@ window.addEventListener('unhandledrejection', function (event) {
2132
2132
  });
2133
2133
  var bindCache = {};
2134
2134
  var script$1m = {
2135
- props: ['id', 'data', 'template', 'preload', 'width', 'height', 'minWidth', 'minHeight', 'maxWidth', 'maxHeight', 'colspan', 'rowspan', 'on', 'tip', 'ownproperty', 'orientUid', 'templateWrapper', 'preloadWrapper'],
2135
+ props: ['id', 'data', 'template', 'preload', 'width', 'height', 'colspan', 'rowspan', 'on', 'tip', 'ownproperty', 'orientUid', 'templateWrapper', 'preloadWrapper'],
2136
2136
  beforeCreate: function beforeCreate() {
2137
2137
  this.isWidget = true;
2138
2138
 
@@ -2147,7 +2147,6 @@ var script$1m = {
2147
2147
  created: function created() {
2148
2148
  var _this3 = this;
2149
2149
 
2150
- //if (this.$options.name=='w-dialog') console.log(this.templateWrapper, this.preloadWrapper, this.$attrs.class, this.isEntity)
2151
2150
  var propsEntity = !(this.template || this.preload);
2152
2151
  var dftopt = !this.ownproperty && propsEntity && this.getDefaultOption(this.$attrs.class);
2153
2152
  var dftoptEntity = !(dftopt.template || dftopt.preload);
@@ -2452,10 +2451,6 @@ var script$1m = {
2452
2451
  style: [{
2453
2452
  width: this.x.width && $$1.unitSize(this.x.width),
2454
2453
  height: this.x.height && $$1.unitSize(this.x.height),
2455
- minWidth: this.x.minWidth && $$1.unitSize(this.x.minWidth),
2456
- minHeight: this.x.minHeight && $$1.unitSize(this.x.minHeight),
2457
- maxWidth: this.x.maxWidth && $$1.unitSize(this.x.maxWidth),
2458
- maxHeight: this.x.maxHeight && $$1.unitSize(this.x.maxHeight),
2459
2454
  '--w-grid-colspan': !this.x.colspan || this.x.colspan == -1 ? null : "span ".concat(this.x.colspan),
2460
2455
  '--w-grid-rowspan': !this.x.rowspan || this.x.rowspan == -1 ? null : "span ".concat(this.x.rowspan)
2461
2456
  }, this.html_style, this.x.style]
@@ -5600,7 +5595,7 @@ var script$Q = {
5600
5595
  },
5601
5596
  data: function data() {
5602
5597
  return {
5603
- rowspan: null
5598
+ rows: null
5604
5599
  };
5605
5600
  },
5606
5601
  methods: {
@@ -5630,7 +5625,7 @@ var script$Q = {
5630
5625
  }
5631
5626
  }
5632
5627
 
5633
- this.rowspan = {};
5628
+ this.rows = {};
5634
5629
  return h$1('div', {
5635
5630
  class: 'w-table-tbl-wrap'
5636
5631
  }, h$1('table', {
@@ -5817,7 +5812,7 @@ var script$O = {
5817
5812
  },
5818
5813
  html_slots: function html_slots() {
5819
5814
  var ri = this.rowIndex;
5820
- var rs = this.pubParent.rowspan;
5815
+ var rs = this.pubParent.rows;
5821
5816
  var ci = 0;
5822
5817
  return this.slots_children().map(function (td) {
5823
5818
  if (rs[ri] && rs[ri][ci]) {
@@ -9666,6 +9661,34 @@ var script$f = {
9666
9661
  }
9667
9662
  },
9668
9663
  computed: {
9664
+ validHooks: function validHooks() {
9665
+ var _this57 = this;
9666
+
9667
+ return {
9668
+ valid: function valid(v) {
9669
+ var _iterator5 = _createForOfIteratorHelper(_this57.list),
9670
+ _step5;
9671
+
9672
+ try {
9673
+ for (_iterator5.s(); !(_step5 = _iterator5.n()).done;) {
9674
+ var item = _step5.value;
9675
+
9676
+ if (item.loading) {
9677
+ return _this57.formErr('upload_loading');
9678
+ }
9679
+
9680
+ if (item.error) {
9681
+ return _this57.formErr('upload_invalid_file');
9682
+ }
9683
+ }
9684
+ } catch (err) {
9685
+ _iterator5.e(err);
9686
+ } finally {
9687
+ _iterator5.f();
9688
+ }
9689
+ }
9690
+ };
9691
+ },
9669
9692
  input_value: function input_value() {
9670
9693
  var v = this.val();
9671
9694
  return v.length == 0 ? '' : JSON.stringify(v);
@@ -9684,11 +9707,11 @@ var script$f = {
9684
9707
  };
9685
9708
  },
9686
9709
  html_on: function html_on() {
9687
- var _this57 = this;
9710
+ var _this58 = this;
9688
9711
 
9689
9712
  return {
9690
9713
  onclick: function onclick() {
9691
- return _this57.warn(false);
9714
+ return _this58.warn(false);
9692
9715
  }
9693
9716
  };
9694
9717
  }
@@ -9708,30 +9731,30 @@ var script$e = {
9708
9731
  this.provideUpload.clickItem(e, this.item);
9709
9732
  },
9710
9733
  createImageThumbnail: function createImageThumbnail() {
9711
- var _this58 = this;
9734
+ var _this59 = this;
9712
9735
 
9713
9736
  var r = new FileReader();
9714
9737
 
9715
9738
  r.onload = function (e) {
9716
- if (_this58.item.loaded) return;
9717
- _this58.dataURL = e.target.result;
9739
+ if (_this59.item.loaded) return;
9740
+ _this59.dataURL = e.target.result;
9718
9741
  };
9719
9742
 
9720
9743
  r.readAsDataURL(this.item.file);
9721
9744
  },
9722
9745
  createVideoThumbnail: function createVideoThumbnail() {
9723
- var _this59 = this;
9746
+ var _this60 = this;
9724
9747
 
9725
9748
  var video = document.createElement('video');
9726
9749
  video.addEventListener('loadeddata', function () {
9727
9750
  setTimeout(function () {
9728
- if (_this59.item.loaded) return;
9751
+ if (_this60.item.loaded) return;
9729
9752
  var cvs = document.createElement('canvas');
9730
9753
  var ctx = cvs.getContext('2d');
9731
9754
  cvs.width = video.videoWidth;
9732
9755
  cvs.height = video.videoHeight;
9733
9756
  ctx.drawImage(video, 0, 0);
9734
- _this59.dataURL = cvs.toDataURL('image/png');
9757
+ _this60.dataURL = cvs.toDataURL('image/png');
9735
9758
  video.pause();
9736
9759
  $$1.q(video).remove();
9737
9760
  }, 150);
@@ -9786,14 +9809,14 @@ var script$e = {
9786
9809
  }
9787
9810
  },
9788
9811
  mounted: function mounted() {
9789
- var _this60 = this;
9812
+ var _this61 = this;
9790
9813
 
9791
9814
  if (!this.item.loaded && this.item.file) {
9792
9815
  this.upload.isVideo(this.item) ? this.createVideoThumbnail() : this.upload.isImage(this.item) ? this.createImageThumbnail() : null;
9793
9816
  this.$watch(function () {
9794
- return _this60.item.progress;
9817
+ return _this61.item.progress;
9795
9818
  }, function (v) {
9796
- return _this60.setProgress(v);
9819
+ return _this61.setProgress(v);
9797
9820
  }, {
9798
9821
  immediate: true
9799
9822
  });
@@ -9890,7 +9913,7 @@ var script$d = {
9890
9913
  });
9891
9914
  },
9892
9915
  html_input_button: function html_input_button() {
9893
- var _this61 = this;
9916
+ var _this62 = this;
9894
9917
 
9895
9918
  return h$1(script$I, {
9896
9919
  ref: 'uploadbbr',
@@ -9898,16 +9921,16 @@ var script$d = {
9898
9921
  gap: 10
9899
9922
  }, {
9900
9923
  default: function _default() {
9901
- return [_this61.$slots.button ? _this61.$slots.button() : h$1(script$$, {
9924
+ return [_this62.$slots.button ? _this62.$slots.button() : h$1(script$$, {
9902
9925
  ref: 'uploadbutton',
9903
9926
  title: $$1.loc.form.choose_image,
9904
9927
  icon: '.f-i .f-i-plus',
9905
9928
  class: 'w-mediaupload-button',
9906
9929
  style: {
9907
- width: $$1.unitSize(_this61.x.thumbnailWidth),
9908
- height: $$1.unitSize(_this61.x.thumbnailHeight)
9930
+ width: $$1.unitSize(_this62.x.thumbnailWidth),
9931
+ height: $$1.unitSize(_this62.x.thumbnailHeight)
9909
9932
  },
9910
- onclick: _this61.chooseFile
9933
+ onclick: _this62.chooseFile
9911
9934
  })];
9912
9935
  }
9913
9936
  });
@@ -10089,7 +10112,7 @@ var script$a = {
10089
10112
  return this.$refs.btns && this.$refs.btns.contains(el);
10090
10113
  },
10091
10114
  html_button: function html_button() {
10092
- var _this62 = this;
10115
+ var _this63 = this;
10093
10116
 
10094
10117
  return h$1('div', {
10095
10118
  class: 'w-spinner-step w-input-bbr f-flex-column f-oh',
@@ -10098,14 +10121,14 @@ var script$a = {
10098
10121
  class: 'w-spinner-step-btn f-rel',
10099
10122
  disabled: this.x.disabled,
10100
10123
  onclick: function onclick(e) {
10101
- return _this62.stepBy(1);
10124
+ return _this63.stepBy(1);
10102
10125
  },
10103
10126
  innerHTML: '<i class="f-abs-center f-i f-i-caret-up"></i>'
10104
10127
  }), h$1('button', {
10105
10128
  class: 'w-spinner-step-btn f-rel',
10106
10129
  disabled: this.x.disabled,
10107
10130
  onclick: function onclick(e) {
10108
- return _this62.stepBy(-1);
10131
+ return _this63.stepBy(-1);
10109
10132
  },
10110
10133
  innerHTML: '<i class="f-abs-center f-i f-i-caret-down"></i>'
10111
10134
  })]);
@@ -10113,24 +10136,24 @@ var script$a = {
10113
10136
  },
10114
10137
  computed: {
10115
10138
  validHooks: function validHooks() {
10116
- var _this63 = this;
10139
+ var _this64 = this;
10117
10140
 
10118
10141
  return {
10119
10142
  compare: function compare(v, c, d) {
10120
- return !$$1.eval('v' + (_this63.x.compare.mode || '==') + 'd', {
10143
+ return !$$1.eval('v' + (_this64.x.compare.mode || '==') + 'd', {
10121
10144
  v: v,
10122
10145
  d: d
10123
10146
  });
10124
10147
  },
10125
10148
  valid: function valid(v) {
10126
- _this63.x.format && (v = v.replace(RegExp(_this63.x.format.separator || ',', 'g'), ''));
10149
+ _this64.x.format && (v = v.replace(RegExp(_this64.x.format.separator || ',', 'g'), ''));
10127
10150
 
10128
10151
  if (v) {
10129
- if (isNaN(v) || /\s/.test(v)) return _this63.formErr('number_invalid');
10130
- var d = _this63.x.decimal;
10131
- if (!d && ~v.indexOf('.')) return _this63.formErr('number_integer');
10132
- if (d && d > 0 && $$1.strFrom(v, '.').length > d) return _this63.formErr('number_decimal_digit', [d]);
10133
- if (_this63.provideRangeParent) return _this63.provideRangeParent.validHooks.valid();
10152
+ if (isNaN(v) || /\s/.test(v)) return _this64.formErr('number_invalid');
10153
+ var d = _this64.x.decimal;
10154
+ if (!d && ~v.indexOf('.')) return _this64.formErr('number_integer');
10155
+ if (d && d > 0 && $$1.strFrom(v, '.').length > d) return _this64.formErr('number_decimal_digit', [d]);
10156
+ if (_this64.provideRangeParent) return _this64.provideRangeParent.validHooks.valid();
10134
10157
  }
10135
10158
  }
10136
10159
  };
@@ -10201,7 +10224,7 @@ var script$9 = {
10201
10224
  };
10202
10225
  },
10203
10226
  html_button: function html_button() {
10204
- var _this64 = this;
10227
+ var _this65 = this;
10205
10228
 
10206
10229
  var r = [];
10207
10230
  if (!this.x.noButton) r.push(h$1('button', {
@@ -10218,28 +10241,28 @@ var script$9 = {
10218
10241
  autoHide: true,
10219
10242
  snap: {
10220
10243
  target: function target() {
10221
- return _this64.snapElem();
10244
+ return _this65.snapElem();
10222
10245
  },
10223
10246
  position: 'v',
10224
10247
  indent: 1
10225
10248
  },
10226
10249
  on: {
10227
10250
  close: function close() {
10228
- _this64.showDrop = false, _this64.currentDate = null;
10251
+ _this65.showDrop = false, _this65.currentDate = null;
10229
10252
  }
10230
10253
  }
10231
10254
  }, {
10232
10255
  default: function _default() {
10233
10256
  return h$1(script$q, _objectSpread(_objectSpread({
10234
10257
  pad: true,
10235
- current: _this64.currentDate || _this64.x.modelValue || '',
10236
- value: _this64.x.modelValue,
10237
- format: _this64.x.format
10238
- }, _this64.getPeriod()), {}, {
10239
- success: _this64.calendarCallback,
10258
+ current: _this65.currentDate || _this65.x.modelValue || '',
10259
+ value: _this65.x.modelValue,
10260
+ format: _this65.x.format
10261
+ }, _this65.getPeriod()), {}, {
10262
+ success: _this65.calendarCallback,
10240
10263
  on: {
10241
10264
  'click:item': function clickItem(e, item) {
10242
- return _this64.currentDate = item.value;
10265
+ return _this65.currentDate = item.value;
10243
10266
  }
10244
10267
  }
10245
10268
  }));
@@ -10252,46 +10275,46 @@ var script$9 = {
10252
10275
  },
10253
10276
  computed: {
10254
10277
  validHooks: function validHooks() {
10255
- var _this65 = this;
10278
+ var _this66 = this;
10256
10279
 
10257
10280
  return {
10258
10281
  minValue: function minValue(v) {
10259
- return $$1.dateParse(v, _this65.x.format) < $$1.dateParse(_this65.vv('minValue'), _this65.x.format);
10282
+ return $$1.dateParse(v, _this66.x.format) < $$1.dateParse(_this66.vv('minValue'), _this66.x.format);
10260
10283
  },
10261
10284
  maxValue: function maxValue(v) {
10262
- return $$1.dateParse(v, _this65.x.format) > $$1.dateParse(_this65.vv('maxValue'), _this65.x.format);
10285
+ return $$1.dateParse(v, _this66.x.format) > $$1.dateParse(_this66.vv('maxValue'), _this66.x.format);
10263
10286
  },
10264
10287
  compare: function compare(v, c, d) {
10265
- if (_this65.x.format && c.x.format) {
10266
- var f = (_this65.x.format.length > c.x.format.length ? _this65 : c).x.format;
10267
- v = $$1.dateFormat($$1.dateParse(v, _this65.x.format), f);
10288
+ if (_this66.x.format && c.x.format) {
10289
+ var f = (_this66.x.format.length > c.x.format.length ? _this66 : c).x.format;
10290
+ v = $$1.dateFormat($$1.dateParse(v, _this66.x.format), f);
10268
10291
  d = $$1.dateFormat($$1.dateParse(d, c.x.format), f);
10269
10292
  }
10270
10293
 
10271
- return !$$1.eval('v' + (_this65.x.compare.mode || '==') + 'd', {
10294
+ return !$$1.eval('v' + (_this66.x.compare.mode || '==') + 'd', {
10272
10295
  v: v,
10273
10296
  d: d
10274
10297
  });
10275
10298
  },
10276
10299
  valid: function valid(v) {
10277
- if (_this65.x.multiple) return;
10300
+ if (_this66.x.multiple) return;
10278
10301
 
10279
10302
  if (v) {
10280
10303
  var _c4 = v;
10281
- var d = $$1.dateParse(_c4, _this65.x.format);
10304
+ var d = $$1.dateParse(_c4, _this66.x.format);
10282
10305
  var y = d.getFullYear();
10283
10306
  var m = 9999;
10284
10307
  var n = 1000;
10285
- if (y > m || y < n) return _this65.formErr('time_exceed', [n, m]);
10308
+ if (y > m || y < n) return _this66.formErr('time_exceed', [n, m]);
10286
10309
 
10287
- if (_c4 != $$1.dateFormat(d, _this65.x.format)) {
10288
- return _this65.formErr('time_format', [$$1.dateFormat(d, _this65.x.format)]);
10310
+ if (_c4 != $$1.dateFormat(d, _this66.x.format)) {
10311
+ return _this66.formErr('time_format', [$$1.dateFormat(d, _this66.x.format)]);
10289
10312
  }
10290
10313
  }
10291
10314
 
10292
- if (_this65.vv('beforeNow') && v && v > $$1.dateFormat(new Date(), _this65.x.format)) return _this65.formErr('beforeNow', [_this65.x.beforeNow]);
10293
- if (_this65.vv('afterNow') && v && v < $$1.dateFormat(new Date(), _this65.x.format)) return _this65.formErr('afterNow', [_this65.x.afterNow]);
10294
- if (_this65.provideRangeParent) return _this65.provideRangeParent.validHooks.valid();
10315
+ if (_this66.vv('beforeNow') && v && v > $$1.dateFormat(new Date(), _this66.x.format)) return _this66.formErr('beforeNow', [_this66.x.beforeNow]);
10316
+ if (_this66.vv('afterNow') && v && v < $$1.dateFormat(new Date(), _this66.x.format)) return _this66.formErr('afterNow', [_this66.x.afterNow]);
10317
+ if (_this66.provideRangeParent) return _this66.provideRangeParent.validHooks.valid();
10295
10318
  }
10296
10319
  };
10297
10320
  },
@@ -10339,7 +10362,7 @@ var script$8 = {
10339
10362
  return this.input_text;
10340
10363
  },
10341
10364
  html_input: function html_input() {
10342
- var _this66 = this;
10365
+ var _this67 = this;
10343
10366
 
10344
10367
  var t = this.input_text;
10345
10368
  var p = this.input_placeholder;
@@ -10358,14 +10381,14 @@ var script$8 = {
10358
10381
  autoHide: true,
10359
10382
  snap: {
10360
10383
  target: function target() {
10361
- return _this66.el('main');
10384
+ return _this67.el('main');
10362
10385
  },
10363
10386
  position: 'v',
10364
10387
  indent: 1
10365
10388
  },
10366
10389
  on: {
10367
10390
  close: function close() {
10368
- return _this66.showDrop = false;
10391
+ return _this67.showDrop = false;
10369
10392
  }
10370
10393
  }
10371
10394
  }, this.$slots)];
@@ -10379,7 +10402,7 @@ var script$8 = {
10379
10402
  },
10380
10403
  computed: {
10381
10404
  input_text: function input_text() {
10382
- var _this67 = this;
10405
+ var _this68 = this;
10383
10406
 
10384
10407
  var r = [];
10385
10408
  var s = this.slots_children();
@@ -10389,7 +10412,7 @@ var script$8 = {
10389
10412
  return n.props.value == v;
10390
10413
  });
10391
10414
  if (i > -1) r.push(i);
10392
- if (!_this67.x.multiple) return false;
10415
+ if (!_this68.x.multiple) return false;
10393
10416
  });
10394
10417
  return r.sort().map(function (v) {
10395
10418
  return s[v].props.text;
@@ -10510,24 +10533,27 @@ var script$5 = {
10510
10533
  },
10511
10534
  computed: {
10512
10535
  validHooks: function validHooks() {
10513
- var _this68 = this;
10536
+ var _this69 = this;
10514
10537
 
10515
10538
  return {
10516
10539
  valid: function valid() {
10517
- var f = _this68.forms();
10540
+ var f = _this69.forms();
10518
10541
 
10519
10542
  if (f.length > 1) {
10520
10543
  var v1 = f[0] && f[0].formVal();
10521
10544
  var v2 = f[1] && f[1].formVal();
10522
10545
 
10523
- var _c5 = _this68.x.compare || '<=';
10546
+ var _c5 = _this69.x.compare || '<=';
10547
+
10548
+ if (!isNaN(v1)) v1 = parseFloat(v1);
10549
+ if (!isNaN(v2)) v2 = parseFloat(v2);
10524
10550
 
10525
10551
  if (v1 && v2) {
10526
10552
  if (!$$1.eval("v1 ".concat(_c5, " v2"), {
10527
10553
  v1: v1,
10528
10554
  v2: v2
10529
10555
  })) {
10530
- return _this68.formErr('compare', [f[0].getLabelText(), _c5, f[1].getLabelText()]);
10556
+ return _this69.formErr('compare', [f[0].getLabelText(), _c5, f[1].getLabelText()]);
10531
10557
  }
10532
10558
  }
10533
10559
  }
@@ -10535,11 +10561,11 @@ var script$5 = {
10535
10561
  };
10536
10562
  },
10537
10563
  html_on: function html_on() {
10538
- var _this69 = this;
10564
+ var _this70 = this;
10539
10565
 
10540
10566
  return {
10541
10567
  onclick: function onclick(e) {
10542
- return _this69.warnClass = '';
10568
+ return _this70.warnClass = '';
10543
10569
  }
10544
10570
  };
10545
10571
  }
@@ -10594,7 +10620,7 @@ var script$4 = {
10594
10620
  this.warn(false);
10595
10621
  },
10596
10622
  oninput: function oninput(e) {
10597
- var _this70 = this;
10623
+ var _this71 = this;
10598
10624
 
10599
10625
  var v = e.target.value;
10600
10626
  this.sensor_text = v;
@@ -10604,9 +10630,9 @@ var script$4 = {
10604
10630
  this.suggest(false);
10605
10631
  } else {
10606
10632
  this.sug_timer = setTimeout(function () {
10607
- _this70.suggest(true);
10633
+ _this71.suggest(true);
10608
10634
 
10609
- _this70.trigger(e, v);
10635
+ _this71.trigger(e, v);
10610
10636
  }, 500);
10611
10637
  }
10612
10638
  },
@@ -10653,7 +10679,7 @@ var script$4 = {
10653
10679
  return this.input_title;
10654
10680
  },
10655
10681
  html_options: function html_options() {
10656
- var _this71 = this;
10682
+ var _this72 = this;
10657
10683
 
10658
10684
  var m = this.x.modelValue;
10659
10685
 
@@ -10664,22 +10690,22 @@ var script$4 = {
10664
10690
  'z-forbid': v.forbid
10665
10691
  }],
10666
10692
  onclick: function onclick(e) {
10667
- return _this71.clickItem(e, v);
10693
+ return _this72.clickItem(e, v);
10668
10694
  }
10669
10695
  }, [h$1('div', {
10670
10696
  class: 'w-combobox-option-text f-line-1',
10671
10697
  title: v.text
10672
- }, v.text), _this71.isNormal && h$1('div', {
10698
+ }, v.text), _this72.isNormal && h$1('div', {
10673
10699
  class: 'w-combobox-option-close f-i f-i-close',
10674
10700
  onclick: function onclick(e) {
10675
- return _this71.clickClose(e, v);
10701
+ return _this72.clickClose(e, v);
10676
10702
  }
10677
10703
  })]);
10678
10704
  });
10679
10705
  }
10680
10706
  },
10681
10707
  html_var: function html_var() {
10682
- var _this72 = this;
10708
+ var _this73 = this;
10683
10709
 
10684
10710
  return h$1('div', {
10685
10711
  class: 'w-combobox-input-wrap'
@@ -10696,15 +10722,15 @@ var script$4 = {
10696
10722
  onkeydown: this.onkeydown,
10697
10723
  placeholder: this.input_value ? null : this.input_placeholder,
10698
10724
  onfocus: function onfocus(e) {
10699
- _this72.isFocus = true, e.target.value && e.target.dispatchEvent(new Event('input'));
10725
+ _this73.isFocus = true, e.target.value && e.target.dispatchEvent(new Event('input'));
10700
10726
  },
10701
10727
  onblur: function onblur(e) {
10702
- return _this72.isFocus = false;
10728
+ return _this73.isFocus = false;
10703
10729
  }
10704
10730
  })]);
10705
10731
  },
10706
10732
  html_input: function html_input() {
10707
- var _this73 = this;
10733
+ var _this74 = this;
10708
10734
 
10709
10735
  return [this.html_input_hidden(), h$1('div', {
10710
10736
  class: 'w-combobox-list f-flex-1 f-flex f-oh f-height'
@@ -10717,14 +10743,14 @@ var script$4 = {
10717
10743
  autoHide: true,
10718
10744
  snap: {
10719
10745
  target: function target() {
10720
- return _this73.el('main');
10746
+ return _this74.el('main');
10721
10747
  },
10722
10748
  position: 'v',
10723
10749
  indent: 1
10724
10750
  },
10725
10751
  on: {
10726
10752
  close: function close() {
10727
- return _this73.showSuggest = false;
10753
+ return _this74.showSuggest = false;
10728
10754
  }
10729
10755
  }
10730
10756
  }, this.$slots))];
@@ -10752,6 +10778,15 @@ var script$4 = {
10752
10778
  }
10753
10779
  },
10754
10780
  computed: {
10781
+ validHooks: function validHooks() {
10782
+ var _this75 = this;
10783
+
10784
+ return {
10785
+ valid: function valid(v) {
10786
+ if (_this75.$refs.input.value) return _this75.formErr('invalid_option');
10787
+ }
10788
+ };
10789
+ },
10755
10790
  input_value: function input_value() {
10756
10791
  return typeof this.x.modelValue === 'string' ? this.x.modelValue : $$1.array(this.x.modelValue).map(function (v) {
10757
10792
  return v.value;
@@ -10774,12 +10809,12 @@ var script$4 = {
10774
10809
  }
10775
10810
  },
10776
10811
  mounted: function mounted() {
10777
- var _this74 = this;
10812
+ var _this76 = this;
10778
10813
 
10779
10814
  if (this.isEntity && this.$refs.sensor) {
10780
10815
  new ResizeObserver(function () {
10781
- if (_this74.$refs.sensor) {
10782
- _this74.sensor_width = _this74.$refs.sensor.offsetWidth + 'px';
10816
+ if (_this76.$refs.sensor) {
10817
+ _this76.sensor_width = _this76.$refs.sensor.offsetWidth + 'px';
10783
10818
  }
10784
10819
  }).observe(this.$refs.sensor);
10785
10820
  }
@@ -10792,13 +10827,13 @@ var script$3 = {
10792
10827
  emits: ['input', 'dblclick:item'],
10793
10828
  props: ['multiple', 'picker', 'dropWidth', 'separator', 'strict', 'br'],
10794
10829
  created: function created() {
10795
- var _this75 = this;
10830
+ var _this77 = this;
10796
10831
 
10797
10832
  this.$watch(function () {
10798
- return _this75.x.modelValue;
10833
+ return _this77.x.modelValue;
10799
10834
  }, function (v) {
10800
- if (_this75.isEntity && !_this75.isFocus) {
10801
- _this75.initOptions(v);
10835
+ if (_this77.isEntity && !_this77.isFocus) {
10836
+ _this77.initOptions(v);
10802
10837
  }
10803
10838
  });
10804
10839
  },
@@ -10882,7 +10917,7 @@ var script$3 = {
10882
10917
  this.warn(false);
10883
10918
  },
10884
10919
  input: function input(a) {
10885
- var _this76 = this;
10920
+ var _this78 = this;
10886
10921
 
10887
10922
  this.currOpt = a;
10888
10923
  var v = a.innerText.replace(/^[\s,]+|[\s,]+$/g, '');
@@ -10892,9 +10927,9 @@ var script$3 = {
10892
10927
  this.suggest(false);
10893
10928
  } else {
10894
10929
  this.sug_timer = setTimeout(function () {
10895
- _this76.suggest(true);
10930
+ _this78.suggest(true);
10896
10931
 
10897
- _this76.trigger(new Event('input'), v);
10932
+ _this78.trigger(new Event('input'), v);
10898
10933
  }, 500);
10899
10934
  }
10900
10935
  },
@@ -10910,7 +10945,7 @@ var script$3 = {
10910
10945
  return this.$refs.inp;
10911
10946
  },
10912
10947
  fixStyle: function fixStyle() {
10913
- var _this77 = this;
10948
+ var _this79 = this;
10914
10949
 
10915
10950
  var c = $$1.rngElement();
10916
10951
  var g = false;
@@ -10985,7 +11020,7 @@ var script$3 = {
10985
11020
 
10986
11021
  t.split(p).forEach(function (s) {
10987
11022
  if (_h4 = $$1.strTrim(s)) {
10988
- g = _this77.param(_h4);
11023
+ g = _this79.param(_h4);
10989
11024
 
10990
11025
  _d.push('<u' + (g ? ' class=_o data-value="' + g.value + '"' + (g.forbid ? ' data-forbid' : '') : '') + '>' + _h4 + '</u>');
10991
11026
 
@@ -11051,11 +11086,11 @@ var script$3 = {
11051
11086
  if (typeof c === 'function') c(this);else this.cmd(c, this.formVal());
11052
11087
  },
11053
11088
  addStore: function addStore(m) {
11054
- var _this78 = this;
11089
+ var _this80 = this;
11055
11090
 
11056
11091
  if (m && typeof m !== 'string') {
11057
11092
  var _r6 = $$1.array(m).filter(function (v) {
11058
- return !_this78.store.find(function (s) {
11093
+ return !_this80.store.find(function (s) {
11059
11094
  return s.value == v.value;
11060
11095
  });
11061
11096
  });
@@ -11135,7 +11170,7 @@ var script$3 = {
11135
11170
  return this.input_title;
11136
11171
  },
11137
11172
  html_options: function html_options(v) {
11138
- var _this79 = this;
11173
+ var _this81 = this;
11139
11174
 
11140
11175
  var p = this.x.separator || ',';
11141
11176
  if (v == null) v = this.x.modelValue;
@@ -11146,7 +11181,7 @@ var script$3 = {
11146
11181
  $$1.lodash.each(b, function (o, i) {
11147
11182
  _r7.push('<u' + (o.value ? ' class=_o data-value="' + o.value + '"' : '') + (o.forbid ? ' data-forbid' : '') + '>' + o.text + '</u>');
11148
11183
 
11149
- if (!_this79.x.multiple) return false;
11184
+ if (!_this81.x.multiple) return false;
11150
11185
 
11151
11186
  _r7.push('<i>' + p + '</i>');
11152
11187
  });
@@ -11154,7 +11189,7 @@ var script$3 = {
11154
11189
  }
11155
11190
  },
11156
11191
  html_var: function html_var() {
11157
- var _this80 = this;
11192
+ var _this82 = this;
11158
11193
 
11159
11194
  return h$1('div', {
11160
11195
  class: 'w-linkbox-input f-flex-1',
@@ -11165,15 +11200,15 @@ var script$3 = {
11165
11200
  onclick: this.onclick,
11166
11201
  ondblclick: this.ondblclick,
11167
11202
  onfocus: function onfocus(e) {
11168
- _this80.isFocus = true;
11203
+ _this82.isFocus = true;
11169
11204
  },
11170
11205
  onblur: function onblur(e) {
11171
- _this80.isFocus = false;
11206
+ _this82.isFocus = false;
11172
11207
  }
11173
11208
  });
11174
11209
  },
11175
11210
  html_input: function html_input() {
11176
- var _this81 = this;
11211
+ var _this83 = this;
11177
11212
 
11178
11213
  var p = this.input_placeholder;
11179
11214
  return [this.html_input_hidden(), this.html_var(), h$1('div', {
@@ -11187,14 +11222,14 @@ var script$3 = {
11187
11222
  autoHide: true,
11188
11223
  snap: {
11189
11224
  target: function target() {
11190
- return _this81.el('main');
11225
+ return _this83.el('main');
11191
11226
  },
11192
11227
  position: 'v',
11193
11228
  indent: 1
11194
11229
  },
11195
11230
  on: {
11196
11231
  close: function close() {
11197
- return _this81.showSuggest = false;
11232
+ return _this83.showSuggest = false;
11198
11233
  }
11199
11234
  }
11200
11235
  }, this.$slots)];
@@ -11223,12 +11258,12 @@ var script$3 = {
11223
11258
  },
11224
11259
  computed: {
11225
11260
  validHooks: function validHooks() {
11226
- var _this82 = this;
11261
+ var _this84 = this;
11227
11262
 
11228
11263
  return {
11229
11264
  valid: function valid(v) {
11230
- if (_this82.x.strict && $$1.q('u:not([data-value])').length > 0) {
11231
- return _this82.formErr('invalid_option');
11265
+ if (_this84.x.strict && $$1.q('u:not([data-value])').length > 0) {
11266
+ return _this84.formErr('invalid_option');
11232
11267
  }
11233
11268
  }
11234
11269
  };
@@ -11256,15 +11291,15 @@ var script$3 = {
11256
11291
  }
11257
11292
  },
11258
11293
  mounted: function mounted() {
11259
- var _this83 = this;
11294
+ var _this85 = this;
11260
11295
 
11261
11296
  if (this.isEntity) {
11262
11297
  this.initOptions();
11263
11298
  this.inp().addEventListener('compositionstart', function () {
11264
- _this83.imeMode = true;
11299
+ _this85.imeMode = true;
11265
11300
  });
11266
11301
  this.inp().addEventListener('compositionend', function () {
11267
- _this83.imeMode = false;
11302
+ _this85.imeMode = false;
11268
11303
  });
11269
11304
  }
11270
11305
  }
@@ -11380,7 +11415,7 @@ var script$1 = {
11380
11415
  this.setThumbLeft();
11381
11416
  },
11382
11417
  error: function error(text, timeout, fn) {
11383
- var _this84 = this;
11418
+ var _this86 = this;
11384
11419
 
11385
11420
  if (!text) text = '';
11386
11421
  this.isError = true;
@@ -11392,12 +11427,12 @@ var script$1 = {
11392
11427
  this.text = text + "(".concat(timeout / 1000, ")");
11393
11428
  var timer = setInterval(function () {
11394
11429
  timeout -= 1000;
11395
- _this84.text = text + "(".concat(timeout / 1000, ")");
11430
+ _this86.text = text + "(".concat(timeout / 1000, ")");
11396
11431
 
11397
11432
  if (timeout <= 0) {
11398
11433
  clearInterval(timer);
11399
11434
 
11400
- _this84.reset();
11435
+ _this86.reset();
11401
11436
 
11402
11437
  fn && fn();
11403
11438
  }
@@ -11433,7 +11468,7 @@ var script$1 = {
11433
11468
  $$1.close(this.dropper);
11434
11469
  },
11435
11470
  dragstart: function dragstart(e) {
11436
- var _this85 = this;
11471
+ var _this87 = this;
11437
11472
 
11438
11473
  if (!this.isNormal || this.locked) return;
11439
11474
  this.warn(false);
@@ -11448,16 +11483,16 @@ var script$1 = {
11448
11483
  var c = $$1.eventX(e);
11449
11484
  var l = $$1.numRange(f + c - x, 0, w - g);
11450
11485
  a.style.left = l + 'px';
11451
- _this85.$refs.track.style.width = l + g + 'px';
11452
- _this85.x.modelValue = Math.floor(Math.floor((m - n) * l / (w - g)));
11486
+ _this87.$refs.track.style.width = l + g + 'px';
11487
+ _this87.x.modelValue = Math.floor(Math.floor((m - n) * l / (w - g)));
11453
11488
 
11454
- _this85.el().classList.add('z-drag');
11489
+ _this87.el().classList.add('z-drag');
11455
11490
  }, function (e) {
11456
11491
  a.dispatchEvent(new Event('drop'));
11457
11492
  }, e);
11458
11493
  },
11459
11494
  mouseenter: function mouseenter(e) {
11460
- var _this86 = this;
11495
+ var _this88 = this;
11461
11496
 
11462
11497
  if (this.dropper || !this.x.big || this.isSuccess || this.locked) return;
11463
11498
  this.warn(false);
@@ -11475,13 +11510,13 @@ var script$1 = {
11475
11510
  context: this,
11476
11511
  snap: {
11477
11512
  target: function target() {
11478
- return _this86.el('main');
11513
+ return _this88.el('main');
11479
11514
  },
11480
11515
  position: 'v'
11481
11516
  },
11482
11517
  on: {
11483
11518
  close: function close() {
11484
- return _this86.dropper = null;
11519
+ return _this88.dropper = null;
11485
11520
  }
11486
11521
  }
11487
11522
  });
@@ -11524,12 +11559,12 @@ var script$1 = {
11524
11559
  },
11525
11560
  computed: {
11526
11561
  validHooks: function validHooks() {
11527
- var _this87 = this;
11562
+ var _this89 = this;
11528
11563
 
11529
11564
  return {
11530
11565
  valid: function valid(v) {
11531
- if (!_this87.isSuccess) {
11532
- return _this87.formErr('jigsaw_required');
11566
+ if (!_this89.isSuccess) {
11567
+ return _this89.formErr('jigsaw_required');
11533
11568
  }
11534
11569
  }
11535
11570
  };