@94ai/nf-virtual-select 3.3.14 → 3.3.16

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.d.ts CHANGED
@@ -58,10 +58,6 @@ declare const _default: import("vue/types/v3-component-public-instance").Compone
58
58
  type: ObjectConstructor;
59
59
  default: () => {};
60
60
  };
61
- itemScopedSlots: {
62
- type: ObjectConstructor;
63
- default: () => {};
64
- };
65
61
  headerTag: {
66
62
  type: StringConstructor;
67
63
  default: string;
@@ -215,10 +211,6 @@ declare const _default: import("vue/types/v3-component-public-instance").Compone
215
211
  type: ObjectConstructor;
216
212
  default: () => {};
217
213
  };
218
- itemScopedSlots: {
219
- type: ObjectConstructor;
220
- default: () => {};
221
- };
222
214
  headerTag: {
223
215
  type: StringConstructor;
224
216
  default: string;
@@ -332,7 +324,6 @@ declare const _default: import("vue/types/v3-component-public-instance").Compone
332
324
  itemTag: string;
333
325
  itemClass: string;
334
326
  itemStyle: Record<string, any>;
335
- itemScopedSlots: Record<string, any>;
336
327
  headerTag: string;
337
328
  headeClass: string;
338
329
  headerStyle: Record<string, any>;
@@ -409,10 +400,6 @@ declare const _default: import("vue/types/v3-component-public-instance").Compone
409
400
  type: ObjectConstructor;
410
401
  default: () => {};
411
402
  };
412
- itemScopedSlots: {
413
- type: ObjectConstructor;
414
- default: () => {};
415
- };
416
403
  headerTag: {
417
404
  type: StringConstructor;
418
405
  default: string;
@@ -582,10 +569,6 @@ declare const _default: import("vue/types/v3-component-public-instance").Compone
582
569
  type: ObjectConstructor;
583
570
  default: () => {};
584
571
  };
585
- itemScopedSlots: {
586
- type: ObjectConstructor;
587
- default: () => {};
588
- };
589
572
  headerTag: {
590
573
  type: StringConstructor;
591
574
  default: string;
@@ -739,10 +722,6 @@ declare const _default: import("vue/types/v3-component-public-instance").Compone
739
722
  type: ObjectConstructor;
740
723
  default: () => {};
741
724
  };
742
- itemScopedSlots: {
743
- type: ObjectConstructor;
744
- default: () => {};
745
- };
746
725
  headerTag: {
747
726
  type: StringConstructor;
748
727
  default: string;
@@ -872,7 +851,6 @@ declare const _default: import("vue/types/v3-component-public-instance").Compone
872
851
  itemTag: string;
873
852
  itemClass: string;
874
853
  itemStyle: Record<string, any>;
875
- itemScopedSlots: Record<string, any>;
876
854
  headerTag: string;
877
855
  headeClass: string;
878
856
  headerStyle: Record<string, any>;
@@ -950,10 +928,6 @@ declare const _default: import("vue/types/v3-component-public-instance").Compone
950
928
  type: ObjectConstructor;
951
929
  default: () => {};
952
930
  };
953
- itemScopedSlots: {
954
- type: ObjectConstructor;
955
- default: () => {};
956
- };
957
931
  headerTag: {
958
932
  type: StringConstructor;
959
933
  default: string;
@@ -45,14 +45,19 @@ var _sfc_render$2 = function render() {
45
45
  "value": _vm.source[_vm.value],
46
46
  "disabled": _vm.source["disabled"]
47
47
  }
48
- }, [_vm.showTip ? _c("el-tooltip", {
49
- attrs: {
50
- "content": _vm.source[_vm.label],
51
- "open-delay": 1e3,
52
- "effect": "dark",
53
- "placement": "left"
54
- }
55
- }, [_c("span", [_vm._v(_vm._s(_vm.source[_vm.label]))])]) : _c("span", [_vm._v(_vm._s(_vm.source[_vm.label]))])], 1);
48
+ }, [_vm._t("option", function() {
49
+ return [_vm.showTip ? _c("el-tooltip", {
50
+ attrs: {
51
+ "content": _vm.source[_vm.label],
52
+ "open-delay": 1e3,
53
+ "effect": "dark",
54
+ "placement": "left"
55
+ }
56
+ }, [_c("span", [_vm._v(_vm._s(_vm.source[_vm.label]))])]) : _c("span", [_vm._v(_vm._s(_vm.source[_vm.label]))])];
57
+ }, {
58
+ "slot": "default",
59
+ "row": _vm.source
60
+ })], 2);
56
61
  };
57
62
  var _sfc_staticRenderFns$2 = [];
58
63
  var __component__$2 = /* @__PURE__ */ vue2RuntimeHelpers.normalizeComponent(_sfc_main$2, _sfc_render$2, _sfc_staticRenderFns$2, false, null, null, null, null);
@@ -185,12 +190,6 @@ const _sfc_main = {
185
190
  return {};
186
191
  }
187
192
  },
188
- itemScopedSlots: {
189
- type: Object,
190
- default: () => {
191
- return {};
192
- }
193
- },
194
193
  headerTag: {
195
194
  type: String,
196
195
  default: "div"
@@ -333,7 +332,8 @@ const _sfc_main = {
333
332
  showTip: that.showTip,
334
333
  source: this.source,
335
334
  index: this.index
336
- }
335
+ },
336
+ scopedSlots: this.$scopedSlots
337
337
  });
338
338
  }
339
339
  };
@@ -650,7 +650,7 @@ var _sfc_render = function render2() {
650
650
  "item-class": _vm.itemClass,
651
651
  "item-class-add": _vm.itemClassAdd,
652
652
  "item-style": _vm.itemStyle,
653
- "item-scoped-slots": _vm.itemScopedSlots,
653
+ "item-scoped-slots": _vm.$scopedSlots,
654
654
  "header-tag": _vm.headerTag,
655
655
  "header-class": _vm.headeClass,
656
656
  "header-style": _vm.headerStyle,
@@ -669,7 +669,15 @@ var _sfc_render = function render2() {
669
669
  "totop": _vm.totop,
670
670
  "tobottom": _vm.tobottom,
671
671
  "resized": _vm.resized
672
- }
672
+ },
673
+ scopedSlots: _vm._u([{
674
+ key: "default",
675
+ fn: function(scoped) {
676
+ return _vm._t("option", null, {
677
+ "row": scoped.row
678
+ });
679
+ }
680
+ }], null, true)
673
681
  }, [_vm._t("footer", null, {
674
682
  "slot": "footer"
675
683
  }), _vm._t("header", null, {
@@ -682,14 +690,19 @@ var _sfc_render = function render2() {
682
690
  "value": item[_vm.keyValue[1]],
683
691
  "disabled": item.disabled
684
692
  }
685
- }, [_vm.showTip ? _c("el-tooltip", {
686
- attrs: {
687
- "content": item[_vm.keyValue[0]],
688
- "open-delay": 1e3,
689
- "effect": "dark",
690
- "placement": "left"
691
- }
692
- }, [_c("span", [_vm._v(_vm._s(item[_vm.keyValue[0]]))])]) : _c("span", [_vm._v(" " + _vm._s(item[_vm.keyValue[0]]) + " ")])], 1);
693
+ }, [_vm._t("option", function() {
694
+ return [_vm.showTip ? _c("el-tooltip", {
695
+ attrs: {
696
+ "content": item[_vm.keyValue[0]],
697
+ "open-delay": 1e3,
698
+ "effect": "dark",
699
+ "placement": "left"
700
+ }
701
+ }, [_c("span", [_vm._v(_vm._s(item[_vm.keyValue[0]]))])]) : _c("span", [_vm._v(" " + _vm._s(item[_vm.keyValue[0]]) + " ")])];
702
+ }, {
703
+ "slot": "default",
704
+ "row": item
705
+ })], 2);
693
706
  }), _vm._t("default"), _vm._t("footer")]], 2);
694
707
  };
695
708
  var _sfc_staticRenderFns = [];
@@ -43,14 +43,19 @@ var _sfc_render$2 = function render() {
43
43
  "value": _vm.source[_vm.value],
44
44
  "disabled": _vm.source["disabled"]
45
45
  }
46
- }, [_vm.showTip ? _c("el-tooltip", {
47
- attrs: {
48
- "content": _vm.source[_vm.label],
49
- "open-delay": 1e3,
50
- "effect": "dark",
51
- "placement": "left"
52
- }
53
- }, [_c("span", [_vm._v(_vm._s(_vm.source[_vm.label]))])]) : _c("span", [_vm._v(_vm._s(_vm.source[_vm.label]))])], 1);
46
+ }, [_vm._t("option", function() {
47
+ return [_vm.showTip ? _c("el-tooltip", {
48
+ attrs: {
49
+ "content": _vm.source[_vm.label],
50
+ "open-delay": 1e3,
51
+ "effect": "dark",
52
+ "placement": "left"
53
+ }
54
+ }, [_c("span", [_vm._v(_vm._s(_vm.source[_vm.label]))])]) : _c("span", [_vm._v(_vm._s(_vm.source[_vm.label]))])];
55
+ }, {
56
+ "slot": "default",
57
+ "row": _vm.source
58
+ })], 2);
54
59
  };
55
60
  var _sfc_staticRenderFns$2 = [];
56
61
  var __component__$2 = /* @__PURE__ */ normalizeComponent(_sfc_main$2, _sfc_render$2, _sfc_staticRenderFns$2, false, null, null, null, null);
@@ -183,12 +188,6 @@ const _sfc_main = {
183
188
  return {};
184
189
  }
185
190
  },
186
- itemScopedSlots: {
187
- type: Object,
188
- default: () => {
189
- return {};
190
- }
191
- },
192
191
  headerTag: {
193
192
  type: String,
194
193
  default: "div"
@@ -331,7 +330,8 @@ const _sfc_main = {
331
330
  showTip: that.showTip,
332
331
  source: this.source,
333
332
  index: this.index
334
- }
333
+ },
334
+ scopedSlots: this.$scopedSlots
335
335
  });
336
336
  }
337
337
  };
@@ -648,7 +648,7 @@ var _sfc_render = function render2() {
648
648
  "item-class": _vm.itemClass,
649
649
  "item-class-add": _vm.itemClassAdd,
650
650
  "item-style": _vm.itemStyle,
651
- "item-scoped-slots": _vm.itemScopedSlots,
651
+ "item-scoped-slots": _vm.$scopedSlots,
652
652
  "header-tag": _vm.headerTag,
653
653
  "header-class": _vm.headeClass,
654
654
  "header-style": _vm.headerStyle,
@@ -667,7 +667,15 @@ var _sfc_render = function render2() {
667
667
  "totop": _vm.totop,
668
668
  "tobottom": _vm.tobottom,
669
669
  "resized": _vm.resized
670
- }
670
+ },
671
+ scopedSlots: _vm._u([{
672
+ key: "default",
673
+ fn: function(scoped) {
674
+ return _vm._t("option", null, {
675
+ "row": scoped.row
676
+ });
677
+ }
678
+ }], null, true)
671
679
  }, [_vm._t("footer", null, {
672
680
  "slot": "footer"
673
681
  }), _vm._t("header", null, {
@@ -680,14 +688,19 @@ var _sfc_render = function render2() {
680
688
  "value": item[_vm.keyValue[1]],
681
689
  "disabled": item.disabled
682
690
  }
683
- }, [_vm.showTip ? _c("el-tooltip", {
684
- attrs: {
685
- "content": item[_vm.keyValue[0]],
686
- "open-delay": 1e3,
687
- "effect": "dark",
688
- "placement": "left"
689
- }
690
- }, [_c("span", [_vm._v(_vm._s(item[_vm.keyValue[0]]))])]) : _c("span", [_vm._v(" " + _vm._s(item[_vm.keyValue[0]]) + " ")])], 1);
691
+ }, [_vm._t("option", function() {
692
+ return [_vm.showTip ? _c("el-tooltip", {
693
+ attrs: {
694
+ "content": item[_vm.keyValue[0]],
695
+ "open-delay": 1e3,
696
+ "effect": "dark",
697
+ "placement": "left"
698
+ }
699
+ }, [_c("span", [_vm._v(_vm._s(item[_vm.keyValue[0]]))])]) : _c("span", [_vm._v(" " + _vm._s(item[_vm.keyValue[0]]) + " ")])];
700
+ }, {
701
+ "slot": "default",
702
+ "row": item
703
+ })], 2);
691
704
  }), _vm._t("default"), _vm._t("footer")]], 2);
692
705
  };
693
706
  var _sfc_staticRenderFns = [];
@@ -54,10 +54,6 @@ declare const _default: import("vue").DefineComponent<{
54
54
  type: ObjectConstructor;
55
55
  default: () => {};
56
56
  };
57
- itemScopedSlots: {
58
- type: ObjectConstructor;
59
- default: () => {};
60
- };
61
57
  headerTag: {
62
58
  type: StringConstructor;
63
59
  default: string;
@@ -227,10 +223,6 @@ declare const _default: import("vue").DefineComponent<{
227
223
  type: ObjectConstructor;
228
224
  default: () => {};
229
225
  };
230
- itemScopedSlots: {
231
- type: ObjectConstructor;
232
- default: () => {};
233
- };
234
226
  headerTag: {
235
227
  type: StringConstructor;
236
228
  default: string;
@@ -344,7 +336,6 @@ declare const _default: import("vue").DefineComponent<{
344
336
  itemTag: string;
345
337
  itemClass: string;
346
338
  itemStyle: Record<string, any>;
347
- itemScopedSlots: Record<string, any>;
348
339
  headerTag: string;
349
340
  headeClass: string;
350
341
  headerStyle: Record<string, any>;
@@ -5,15 +5,17 @@
5
5
  :value="source[value]"
6
6
  :disabled="source['disabled']"
7
7
  >
8
- <el-tooltip v-if="showTip"
9
- :content="source[label]"
10
- :open-delay="1000"
11
- effect="dark"
12
- placement="left"
13
- >
14
- <span>{{ source[label] }}</span>
15
- </el-tooltip>
16
- <span v-else>{{ source[label] }}</span>
8
+ <slot name="option" slot="default" :row="source">
9
+ <el-tooltip v-if="showTip"
10
+ :content="source[label]"
11
+ :open-delay="1000"
12
+ effect="dark"
13
+ placement="left"
14
+ >
15
+ <span>{{ source[label] }}</span>
16
+ </el-tooltip>
17
+ <span v-else>{{ source[label] }}</span>
18
+ </slot>
17
19
  </el-option>
18
20
  </template>
19
21
 
@@ -25,7 +25,7 @@
25
25
  :item-class="itemClass"
26
26
  :item-class-add="itemClassAdd"
27
27
  :item-style="itemStyle"
28
- :item-scoped-slots="itemScopedSlots"
28
+ :item-scoped-slots="$scopedSlots"
29
29
  :header-tag="headerTag"
30
30
  :header-class="headeClass"
31
31
  :header-style="headerStyle"
@@ -48,6 +48,7 @@
48
48
  >
49
49
  <slot slot="footer" name="footer" />
50
50
  <slot slot="header" name="header" />
51
+ <slot slot="default" name="option" :row="scoped.row" slot-scope="scoped" />
51
52
  </virtual-list>
52
53
  <slot />
53
54
  </template>
@@ -60,16 +61,18 @@
60
61
  :value="item[keyValue[1]]"
61
62
  :disabled="item.disabled"
62
63
  >
63
- <el-tooltip :content="item[keyValue[0]]"
64
- :open-delay="1000"
65
- effect="dark"
66
- placement="left"
67
- v-if="showTip">
68
- <span>{{ item[keyValue[0]] }}</span>
69
- </el-tooltip>
70
- <span v-else>
71
- {{ item[keyValue[0]] }}
72
- </span>
64
+ <slot slot="default" name="option" :row="item">
65
+ <el-tooltip :content="item[keyValue[0]]"
66
+ :open-delay="1000"
67
+ effect="dark"
68
+ placement="left"
69
+ v-if="showTip">
70
+ <span>{{ item[keyValue[0]] }}</span>
71
+ </el-tooltip>
72
+ <span v-else>
73
+ {{ item[keyValue[0]] }}
74
+ </span>
75
+ </slot>
73
76
  </el-option>
74
77
  <slot />
75
78
  <slot name="footer" />
@@ -153,12 +156,6 @@ export default {
153
156
  return {}
154
157
  }
155
158
  },
156
- itemScopedSlots: {
157
- type: Object,
158
- default: () => {
159
- return {}
160
- }
161
- },
162
159
  headerTag: {
163
160
  type: String,
164
161
  default: 'div'
@@ -299,7 +296,8 @@ export default {
299
296
  showTip: that.showTip,
300
297
  source: this.source,
301
298
  index: this.index
302
- }
299
+ },
300
+ scopedSlots: this.$scopedSlots
303
301
  })
304
302
  }
305
303
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@94ai/nf-virtual-select",
3
- "version": "3.3.14",
3
+ "version": "3.3.16",
4
4
  "description": "> TODO: description",
5
5
  "keywords": [],
6
6
  "author": "zoujiahe <zoujiahe@94ai.com>,DESKTOP-1EDDQ79\\dev026 <liuxiangxiang@94ai.com>",
@@ -14,8 +14,8 @@
14
14
  "url": "http://94ai.gitlab.com/zoujiahe/common-ui.git"
15
15
  },
16
16
  "dependencies": {
17
- "@94ai/common-utils": "^3.3.14",
18
- "@94ai/nf-theme-chalk": "^3.3.14",
17
+ "@94ai/common-utils": "^3.3.16",
18
+ "@94ai/nf-theme-chalk": "^3.3.16",
19
19
  "lodash-es": "^4.17.21",
20
20
  "vue-demi": "^0.14.5",
21
21
  "vue-virtual-scroll-list": "^2.3.5"
@@ -33,5 +33,5 @@
33
33
  "types": "lib/index.d.ts",
34
34
  "main": "lib/nf-virtual-select.cjs.js",
35
35
  "module": "lib/nf-virtual-select.esm-bundler.js",
36
- "gitHead": "44bfb05b192645561af74a704914dddb6adca795"
36
+ "gitHead": "706bddaa9e0298e496a416d22ee7b92d433ff4eb"
37
37
  }