@fangzhongya/fang-ui 0.1.23 → 0.1.25

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.
@@ -80,6 +80,7 @@
80
80
  .box-adjust-body .box-adjust-title-icon {
81
81
  width: 20px;
82
82
  display: inline-flex;
83
+ color: #fff;
83
84
  align-items: center;
84
85
  margin: 0 4px;
85
86
  height: 100%;
@@ -37,6 +37,7 @@ $box-adjust: 'box-adjust';
37
37
  .#{z($box-adjust, 'title-icon')} {
38
38
  width: 20px;
39
39
  display: inline-flex;
40
+ color: #fff;
40
41
  align-items: center;
41
42
  margin: 0 4px;
42
43
  height: 100%;
@@ -146,16 +146,14 @@ function comHandle(props2, emit, config) {
146
146
  if (config == null ? void 0 : config.getValue) v = config.getValue(v);
147
147
  if (v && v instanceof Array) {
148
148
  return v.join(props2.multiple);
149
- } else {
150
- return v;
151
149
  }
150
+ return v;
152
151
  };
153
152
  setMultipleValue = (v) => {
154
- let arr = [];
155
153
  if (v && typeof v === "string") {
156
- arr = v.split(props2.multiple);
154
+ return v.split(props2.multiple);
157
155
  }
158
- return arr;
156
+ return v;
159
157
  };
160
158
  setValue(3);
161
159
  }
@@ -144,16 +144,14 @@ function comHandle(props2, emit, config) {
144
144
  if (config == null ? void 0 : config.getValue) v = config.getValue(v);
145
145
  if (v && v instanceof Array) {
146
146
  return v.join(props2.multiple);
147
- } else {
148
- return v;
149
147
  }
148
+ return v;
150
149
  };
151
150
  setMultipleValue = (v) => {
152
- let arr = [];
153
151
  if (v && typeof v === "string") {
154
- arr = v.split(props2.multiple);
152
+ return v.split(props2.multiple);
155
153
  }
156
- return arr;
154
+ return v;
157
155
  };
158
156
  setValue(3);
159
157
  }
@@ -119,4 +119,5 @@
119
119
  @use './tablesp/index.scss' as *;
120
120
  @use './tablespd/index.scss' as *;
121
121
  @use './tabless/index.scss' as *;
122
- @use './tablesv/index.scss' as *;
122
+ @use './tablesv/index.scss' as *;
123
+ @use './tablesvp/index.scss' as *;
@@ -4,5 +4,6 @@ export type ListValue = {
4
4
  suffix?: string;
5
5
  disabled?: boolean;
6
6
  type?: string;
7
+ [key: string]: any;
7
8
  };
8
9
  export declare function getListValue(list: Array<any>): Array<ListValue>;
@@ -80,7 +80,8 @@ const dataHandle = list.comHandle;
80
80
  const dataEmits = [...list.emits, "views", "httpRequest"];
81
81
  const dataSlot = {
82
82
  default: "default",
83
- views: "views"
83
+ views: "views",
84
+ list: "list"
84
85
  };
85
86
  const dataExpose = {};
86
87
  const types = {
@@ -129,6 +129,7 @@ export type DataEmits = typeof dataEmits;
129
129
  export declare const dataSlot: {
130
130
  default: string;
131
131
  views: string;
132
+ list: string;
132
133
  };
133
134
  /**
134
135
  * @expose setValue (val:<string>设置的数据 )
@@ -78,7 +78,8 @@ const dataHandle = comHandle;
78
78
  const dataEmits = [...emits, "views", "httpRequest"];
79
79
  const dataSlot = {
80
80
  default: "default",
81
- views: "views"
81
+ views: "views",
82
+ list: "list"
82
83
  };
83
84
  const dataExpose = {};
84
85
  const types = {
@@ -24,10 +24,11 @@ const util = require("./util.cjs");
24
24
  require("../../form/index.cjs");
25
25
  const index$3 = require("../../../hooks/props-default/index.cjs");
26
26
  const index$4 = require("element-plus/es/components/form/index");
27
- const _hoisted_1 = ["title"];
28
- const _hoisted_2 = ["onClick", "title"];
27
+ const _hoisted_1 = ["onMouseenter"];
28
+ const _hoisted_2 = ["title"];
29
29
  const _hoisted_3 = ["onClick", "title"];
30
30
  const _hoisted_4 = ["onClick", "title"];
31
+ const _hoisted_5 = ["onClick", "title"];
31
32
  const _sfc_main = /* @__PURE__ */ vue.defineComponent({
32
33
  ...{ inheritAttrs: false },
33
34
  __name: "index",
@@ -48,6 +49,7 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
48
49
  const multiple = listFuObj.multiple;
49
50
  const isloading = vue.ref(false);
50
51
  const disabled = index$4.useDisabled();
52
+ const showIndex = vue.ref(-1);
51
53
  const accept = vue.computed(() => {
52
54
  if (props.accept) {
53
55
  return props.accept;
@@ -141,6 +143,7 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
141
143
  if (is) {
142
144
  if (multiple.value) {
143
145
  value.value.splice(index2, 1);
146
+ value.value = value.value;
144
147
  } else {
145
148
  value.value = "";
146
149
  }
@@ -152,6 +155,7 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
152
155
  } else {
153
156
  if (multiple.value) {
154
157
  value.value.splice(index2, 1);
158
+ value.value = value.value;
155
159
  } else {
156
160
  value.value = "";
157
161
  }
@@ -206,12 +210,14 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
206
210
  if (v instanceof Array) {
207
211
  if (value.value) {
208
212
  value.value.push(...v);
213
+ value.value = value.value;
209
214
  } else {
210
215
  value.value = [...v];
211
216
  }
212
217
  } else {
213
218
  if (value.value) {
214
219
  value.value.push(v);
220
+ value.value = value.value;
215
221
  } else {
216
222
  value.value = [v];
217
223
  }
@@ -247,9 +253,11 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
247
253
  (vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(fileList.value, (item, index2) => {
248
254
  return vue.openBlock(), vue.createElementBlock("div", {
249
255
  class: vue.normalizeClass(vue.unref(cs).z("list-li")),
250
- key: index2
256
+ key: index2,
257
+ onMouseenter: ($event) => showIndex.value = index2,
258
+ onMouseleave: _cache[0] || (_cache[0] = ($event) => showIndex.value = -1)
251
259
  }, [
252
- vue.renderSlot(_ctx.$slots, vue.unref(data.dataSlot).default, {
260
+ vue.renderSlot(_ctx.$slots, vue.unref(data.dataSlot).list, {
253
261
  value: item,
254
262
  type: vue.unref(props).type,
255
263
  accept: accept.value,
@@ -259,6 +267,9 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
259
267
  return [
260
268
  vue.createElementVNode("div", {
261
269
  class: vue.normalizeClass(vue.unref(cs).z("list-li-operation")),
270
+ style: vue.normalizeStyle({
271
+ display: showIndex.value == index2 ? "flex" : "none"
272
+ }),
262
273
  title: item.url
263
274
  }, [
264
275
  vue.unref(props).isDownload ? (vue.openBlock(), vue.createElementBlock("span", {
@@ -272,7 +283,7 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
272
283
  ]),
273
284
  _: 1
274
285
  })
275
- ], 8, _hoisted_2)) : vue.createCommentVNode("", true),
286
+ ], 8, _hoisted_3)) : vue.createCommentVNode("", true),
276
287
  vue.unref(props).isViews ? (vue.openBlock(), vue.createElementBlock("span", {
277
288
  key: 1,
278
289
  onClick: ($event) => onViews(item, index2),
@@ -284,7 +295,7 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
284
295
  ]),
285
296
  _: 1
286
297
  })
287
- ], 8, _hoisted_3)) : vue.createCommentVNode("", true),
298
+ ], 8, _hoisted_4)) : vue.createCommentVNode("", true),
288
299
  !(vue.unref(disabled) || item.disabled) ? (vue.openBlock(), vue.createElementBlock("span", {
289
300
  key: 2,
290
301
  class: vue.normalizeClass(vue.unref(cs).z("list-li-operation-delete")),
@@ -297,8 +308,8 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
297
308
  ]),
298
309
  _: 1
299
310
  })
300
- ], 10, _hoisted_4)) : vue.createCommentVNode("", true)
301
- ], 10, _hoisted_1),
311
+ ], 10, _hoisted_5)) : vue.createCommentVNode("", true)
312
+ ], 14, _hoisted_2),
302
313
  vue.createElementVNode("div", {
303
314
  class: vue.normalizeClass(vue.unref(cs).z("list-li-value"))
304
315
  }, [
@@ -337,7 +348,7 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
337
348
  ], 2)
338
349
  ];
339
350
  })
340
- ], 2);
351
+ ], 42, _hoisted_1);
341
352
  }), 128)),
342
353
  vue.unref(props).isViews ? (vue.openBlock(), vue.createElementBlock("div", {
343
354
  key: 0,
@@ -348,12 +359,12 @@ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
348
359
  accept: accept.value,
349
360
  value: views$1.value,
350
361
  show: views$1.show,
351
- onClose: _cache[0] || (_cache[0] = ($event) => views$1.show = false)
362
+ onClose: _cache[1] || (_cache[1] = ($event) => views$1.show = false)
352
363
  }, () => [
353
364
  vue.createVNode(vue.unref(index$9.BoxAdjust), {
354
365
  isMax: "",
355
366
  modelValue: views$1.show,
356
- "onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => views$1.show = $event)
367
+ "onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => views$1.show = $event)
357
368
  }, {
358
369
  default: vue.withCtx(() => {
359
370
  var _a, _b;
@@ -1,4 +1,4 @@
1
- import { defineComponent, ref, useAttrs, computed, reactive, createElementBlock, openBlock, mergeProps, unref, createElementVNode, createBlock, createCommentVNode, normalizeClass, Fragment, renderList, renderSlot, createVNode, withCtx, toDisplayString } from "vue";
1
+ import { defineComponent, ref, useAttrs, computed, reactive, createElementBlock, openBlock, mergeProps, unref, createElementVNode, createBlock, createCommentVNode, normalizeClass, Fragment, renderList, renderSlot, normalizeStyle, createVNode, withCtx, toDisplayString } from "vue";
2
2
  import Document from "../../../icons/vue/document.js";
3
3
  import Download from "../../../icons/vue/download.js";
4
4
  import Plus from "../../../icons/vue/plus.js";
@@ -22,10 +22,11 @@ import { getType, getListType } from "./util.js";
22
22
  import "../../form/index.js";
23
23
  import { usePropsDefault, viewProps, getProps } from "../../../hooks/props-default/index.js";
24
24
  import { useDisabled } from "element-plus/es/components/form/index";
25
- const _hoisted_1 = ["title"];
26
- const _hoisted_2 = ["onClick", "title"];
25
+ const _hoisted_1 = ["onMouseenter"];
26
+ const _hoisted_2 = ["title"];
27
27
  const _hoisted_3 = ["onClick", "title"];
28
28
  const _hoisted_4 = ["onClick", "title"];
29
+ const _hoisted_5 = ["onClick", "title"];
29
30
  const _sfc_main = /* @__PURE__ */ defineComponent({
30
31
  ...{ inheritAttrs: false },
31
32
  __name: "index",
@@ -46,6 +47,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
46
47
  const multiple = listFuObj.multiple;
47
48
  const isloading = ref(false);
48
49
  const disabled = useDisabled();
50
+ const showIndex = ref(-1);
49
51
  const accept = computed(() => {
50
52
  if (props.accept) {
51
53
  return props.accept;
@@ -139,6 +141,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
139
141
  if (is) {
140
142
  if (multiple.value) {
141
143
  value.value.splice(index, 1);
144
+ value.value = value.value;
142
145
  } else {
143
146
  value.value = "";
144
147
  }
@@ -150,6 +153,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
150
153
  } else {
151
154
  if (multiple.value) {
152
155
  value.value.splice(index, 1);
156
+ value.value = value.value;
153
157
  } else {
154
158
  value.value = "";
155
159
  }
@@ -204,12 +208,14 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
204
208
  if (v instanceof Array) {
205
209
  if (value.value) {
206
210
  value.value.push(...v);
211
+ value.value = value.value;
207
212
  } else {
208
213
  value.value = [...v];
209
214
  }
210
215
  } else {
211
216
  if (value.value) {
212
217
  value.value.push(v);
218
+ value.value = value.value;
213
219
  } else {
214
220
  value.value = [v];
215
221
  }
@@ -245,9 +251,11 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
245
251
  (openBlock(true), createElementBlock(Fragment, null, renderList(fileList.value, (item, index) => {
246
252
  return openBlock(), createElementBlock("div", {
247
253
  class: normalizeClass(unref(cs).z("list-li")),
248
- key: index
254
+ key: index,
255
+ onMouseenter: ($event) => showIndex.value = index,
256
+ onMouseleave: _cache[0] || (_cache[0] = ($event) => showIndex.value = -1)
249
257
  }, [
250
- renderSlot(_ctx.$slots, unref(dataSlot).default, {
258
+ renderSlot(_ctx.$slots, unref(dataSlot).list, {
251
259
  value: item,
252
260
  type: unref(props).type,
253
261
  accept: accept.value,
@@ -257,6 +265,9 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
257
265
  return [
258
266
  createElementVNode("div", {
259
267
  class: normalizeClass(unref(cs).z("list-li-operation")),
268
+ style: normalizeStyle({
269
+ display: showIndex.value == index ? "flex" : "none"
270
+ }),
260
271
  title: item.url
261
272
  }, [
262
273
  unref(props).isDownload ? (openBlock(), createElementBlock("span", {
@@ -270,7 +281,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
270
281
  ]),
271
282
  _: 1
272
283
  })
273
- ], 8, _hoisted_2)) : createCommentVNode("", true),
284
+ ], 8, _hoisted_3)) : createCommentVNode("", true),
274
285
  unref(props).isViews ? (openBlock(), createElementBlock("span", {
275
286
  key: 1,
276
287
  onClick: ($event) => onViews(item, index),
@@ -282,7 +293,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
282
293
  ]),
283
294
  _: 1
284
295
  })
285
- ], 8, _hoisted_3)) : createCommentVNode("", true),
296
+ ], 8, _hoisted_4)) : createCommentVNode("", true),
286
297
  !(unref(disabled) || item.disabled) ? (openBlock(), createElementBlock("span", {
287
298
  key: 2,
288
299
  class: normalizeClass(unref(cs).z("list-li-operation-delete")),
@@ -295,8 +306,8 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
295
306
  ]),
296
307
  _: 1
297
308
  })
298
- ], 10, _hoisted_4)) : createCommentVNode("", true)
299
- ], 10, _hoisted_1),
309
+ ], 10, _hoisted_5)) : createCommentVNode("", true)
310
+ ], 14, _hoisted_2),
300
311
  createElementVNode("div", {
301
312
  class: normalizeClass(unref(cs).z("list-li-value"))
302
313
  }, [
@@ -335,7 +346,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
335
346
  ], 2)
336
347
  ];
337
348
  })
338
- ], 2);
349
+ ], 42, _hoisted_1);
339
350
  }), 128)),
340
351
  unref(props).isViews ? (openBlock(), createElementBlock("div", {
341
352
  key: 0,
@@ -346,12 +357,12 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
346
357
  accept: accept.value,
347
358
  value: views.value,
348
359
  show: views.show,
349
- onClose: _cache[0] || (_cache[0] = ($event) => views.show = false)
360
+ onClose: _cache[1] || (_cache[1] = ($event) => views.show = false)
350
361
  }, () => [
351
362
  createVNode(unref(BoxAdjust), {
352
363
  isMax: "",
353
364
  modelValue: views.show,
354
- "onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => views.show = $event)
365
+ "onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => views.show = $event)
355
366
  }, {
356
367
  default: withCtx(() => {
357
368
  var _a, _b;
@@ -80,6 +80,7 @@
80
80
  .box-adjust-body .box-adjust-title-icon {
81
81
  width: 20px;
82
82
  display: inline-flex;
83
+ color: #fff;
83
84
  align-items: center;
84
85
  margin: 0 4px;
85
86
  height: 100%;
@@ -692,6 +692,7 @@
692
692
  .box-adjust-body .box-adjust-title-icon {
693
693
  width: 20px;
694
694
  display: inline-flex;
695
+ color: #fff;
695
696
  align-items: center;
696
697
  margin: 0 4px;
697
698
  height: 100%;
@@ -1835,4 +1836,26 @@
1835
1836
  left: 0;
1836
1837
  z-index: 1;
1837
1838
  opacity: 0;
1839
+ }
1840
+
1841
+ .tablesvp {
1842
+ width: 100%;
1843
+ height: var(--tablesvp-height);
1844
+ display: flex;
1845
+ flex-direction: column;
1846
+ }
1847
+ .tablesvp-main {
1848
+ display: flex;
1849
+ flex-direction: column;
1850
+ flex: 1;
1851
+ width: 100%;
1852
+ }
1853
+ .tablesvp-main.is-radio .el-table__header .el-table-column--selection .el-checkbox {
1854
+ display: none;
1855
+ }
1856
+ .tablesvp-paginat {
1857
+ overflow: hidden;
1858
+ }
1859
+ .tablesvp-paginat .el-pagination {
1860
+ justify-content: flex-end;
1838
1861
  }
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "prefix": "fang-ui",
3
3
  "info": {},
4
- "lastModified": 1762953996277,
4
+ "lastModified": 1762959390937,
5
5
  "icons": {
6
6
  "bar": {
7
7
  "body": " <path fill=\"currentColor\" d=\"M128 544h768a32 32 0 1 0 0-64H128a32 32 0 0 0 0 64z\" ></path> "
package/dist/index.css CHANGED
@@ -692,6 +692,7 @@
692
692
  .box-adjust-body .box-adjust-title-icon {
693
693
  width: 20px;
694
694
  display: inline-flex;
695
+ color: #fff;
695
696
  align-items: center;
696
697
  margin: 0 4px;
697
698
  height: 100%;
@@ -1835,4 +1836,26 @@
1835
1836
  left: 0;
1836
1837
  z-index: 1;
1837
1838
  opacity: 0;
1839
+ }
1840
+
1841
+ .tablesvp {
1842
+ width: 100%;
1843
+ height: var(--tablesvp-height);
1844
+ display: flex;
1845
+ flex-direction: column;
1846
+ }
1847
+ .tablesvp-main {
1848
+ display: flex;
1849
+ flex-direction: column;
1850
+ flex: 1;
1851
+ width: 100%;
1852
+ }
1853
+ .tablesvp-main.is-radio .el-table__header .el-table-column--selection .el-checkbox {
1854
+ display: none;
1855
+ }
1856
+ .tablesvp-paginat {
1857
+ overflow: hidden;
1858
+ }
1859
+ .tablesvp-paginat .el-pagination {
1860
+ justify-content: flex-end;
1838
1861
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@fangzhongya/fang-ui",
3
3
  "private": false,
4
- "version": "0.1.23",
4
+ "version": "0.1.25",
5
5
  "type": "module",
6
6
  "description ": "fang-ui",
7
7
  "keywords": [
@@ -53,11 +53,11 @@
53
53
  "vxe-table": "4.17.13",
54
54
  "@fang-ui/components": "0.0.1-0",
55
55
  "@fang-ui/directives": "0.0.1-0",
56
+ "@fang-ui/icons": "0.0.1-0",
56
57
  "@fang-ui/hooks": "0.0.1-0",
57
58
  "@fang-ui/locale": "0.0.1-0",
58
- "@fang-ui/icons": "0.0.1-0",
59
- "@fang-ui/theme": "0.0.1-0",
60
59
  "@fang-ui/types": "0.0.1-0",
60
+ "@fang-ui/theme": "0.0.1-0",
61
61
  "@fang-ui/utils": "0.0.1-0"
62
62
  },
63
63
  "main": "./dist/index.cjs",
File without changes
File without changes