@fox-js/foxui-pc 4.1.1-7 → 4.1.1-9
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/dist/index.cjs.js +158 -52
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +158 -52
- package/dist/index.esm.js.map +1 -1
- package/dist/index.umd.js +158 -52
- package/dist/index.umd.js.map +1 -1
- package/dist/style.css +1 -1
- package/dist/types/index.d.ts +3 -1
- package/package.json +1 -1
package/dist/index.umd.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
|
|
2
2
|
/*!
|
|
3
|
-
* @fox-js/foxui-desktop v4.0.0
|
|
3
|
+
* @fox-js/foxui-desktop v4.0.0 Mon Dec 02 2024 10:29:50 GMT+0800 (中国标准时间)
|
|
4
4
|
*/
|
|
5
5
|
(function (global, factory) {
|
|
6
6
|
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('vue'), require('@fox-js/validator'), require('element-plus'), require('@element-plus/icons-vue'), require('@fox-js/i18n')) :
|
|
@@ -7905,14 +7905,17 @@
|
|
|
7905
7905
|
* 返回日期格式字符串
|
|
7906
7906
|
* @param {Number} 0返回今天的日期、1返回明天的日期,2返回后天得日期,依次类推
|
|
7907
7907
|
* @param {Date} 起点日期
|
|
7908
|
+
* @param {formatTemplate} 格式化模版
|
|
7908
7909
|
* @return {string} '2014-12-31'
|
|
7910
|
+
*
|
|
7909
7911
|
*/
|
|
7910
|
-
getDay(i, startDate) {
|
|
7912
|
+
getDay(i, startDate, formatTemplate) {
|
|
7911
7913
|
i = i || 0;
|
|
7912
7914
|
let date = startDate ?? /* @__PURE__ */ new Date();
|
|
7913
7915
|
const diff = i * (1e3 * 60 * 60 * 24);
|
|
7914
7916
|
date = new Date(date.getTime() + diff);
|
|
7915
|
-
|
|
7917
|
+
formatTemplate = formatTemplate ?? "YYYY-MM-DD";
|
|
7918
|
+
return this.format(date, formatTemplate);
|
|
7916
7919
|
},
|
|
7917
7920
|
/**
|
|
7918
7921
|
* 时间比较
|
|
@@ -11857,6 +11860,10 @@
|
|
|
11857
11860
|
params: {
|
|
11858
11861
|
type: [Object]
|
|
11859
11862
|
},
|
|
11863
|
+
// row class name
|
|
11864
|
+
rowClassName: {
|
|
11865
|
+
type: Function
|
|
11866
|
+
},
|
|
11860
11867
|
// cell class name
|
|
11861
11868
|
cellClassName: {
|
|
11862
11869
|
type: Function
|
|
@@ -12094,7 +12101,7 @@
|
|
|
12094
12101
|
// setup
|
|
12095
12102
|
setup(props, context) {
|
|
12096
12103
|
const { locale } = i18n.useFoxI18n(scope);
|
|
12097
|
-
const { emitEvent } = defineItem(
|
|
12104
|
+
const { emitEvent, broadcast } = defineItem(
|
|
12098
12105
|
{
|
|
12099
12106
|
componentName,
|
|
12100
12107
|
// 获取value
|
|
@@ -12365,6 +12372,7 @@
|
|
|
12365
12372
|
expandedRows.splice(0, size, row);
|
|
12366
12373
|
}
|
|
12367
12374
|
}
|
|
12375
|
+
setTimeout(setChildCellClassNames, 0);
|
|
12368
12376
|
};
|
|
12369
12377
|
const settingId = context.attrs.id ?? props.prop ?? context.attrs.name;
|
|
12370
12378
|
const settingModel = useSettingModel();
|
|
@@ -12462,10 +12470,14 @@
|
|
|
12462
12470
|
return cols;
|
|
12463
12471
|
});
|
|
12464
12472
|
const cellClassNames = vue.shallowRef(/* @__PURE__ */ new Map());
|
|
12465
|
-
const defaultCellClassName = ({ column, rowIndex }) => {
|
|
12466
|
-
const
|
|
12467
|
-
const
|
|
12468
|
-
|
|
12473
|
+
const defaultCellClassName = ({ row, column, rowIndex, columnIndex }) => {
|
|
12474
|
+
const rowIndexColumnPropkey = `${rowIndex}_${column.property}`;
|
|
12475
|
+
const indexKey = `${rowIndex}_${columnIndex}`;
|
|
12476
|
+
let cellClassName = cellClassNames.value.get(rowIndexColumnPropkey);
|
|
12477
|
+
if (!cellClassName) {
|
|
12478
|
+
cellClassName = cellClassNames.value.get(indexKey);
|
|
12479
|
+
}
|
|
12480
|
+
return cellClassName ?? "";
|
|
12469
12481
|
};
|
|
12470
12482
|
const getCellClassNameProperty = (clsName) => {
|
|
12471
12483
|
if (typeof clsName === "function") {
|
|
@@ -12487,8 +12499,20 @@
|
|
|
12487
12499
|
}
|
|
12488
12500
|
return defaultCellClassName;
|
|
12489
12501
|
};
|
|
12490
|
-
const
|
|
12491
|
-
|
|
12502
|
+
const setChildCellClassNames = () => {
|
|
12503
|
+
cellClassNames.value.entries().forEach(([key, value]) => {
|
|
12504
|
+
const name = `${key}_item`;
|
|
12505
|
+
broadcast.emitToChildren(
|
|
12506
|
+
{
|
|
12507
|
+
name
|
|
12508
|
+
},
|
|
12509
|
+
"setCustomClassName",
|
|
12510
|
+
value
|
|
12511
|
+
);
|
|
12512
|
+
});
|
|
12513
|
+
};
|
|
12514
|
+
const setCellClassName = (rowIndex, column, cellClassName) => {
|
|
12515
|
+
const key = `${rowIndex}_${column}`;
|
|
12492
12516
|
if (cellClassName) {
|
|
12493
12517
|
cellClassNames.value.set(key, cellClassName);
|
|
12494
12518
|
} else {
|
|
@@ -12496,6 +12520,49 @@
|
|
|
12496
12520
|
}
|
|
12497
12521
|
vue.triggerRef(cellClassNames);
|
|
12498
12522
|
};
|
|
12523
|
+
const clearCellClassName = () => {
|
|
12524
|
+
cellClassNames.value.clear();
|
|
12525
|
+
vue.triggerRef(cellClassNames);
|
|
12526
|
+
};
|
|
12527
|
+
const rowClassNames = vue.shallowRef(/* @__PURE__ */ new Map());
|
|
12528
|
+
const defaultRowClassName = ({ rowIndex }) => {
|
|
12529
|
+
const key = `${rowIndex}`;
|
|
12530
|
+
const rowClassName = cellClassNames.value.get(key) ?? "";
|
|
12531
|
+
return rowClassName;
|
|
12532
|
+
};
|
|
12533
|
+
const getRowClassNameProperty = (clsName) => {
|
|
12534
|
+
if (typeof clsName === "function") {
|
|
12535
|
+
return (args) => {
|
|
12536
|
+
const ret = [];
|
|
12537
|
+
let s = defaultRowClassName(args);
|
|
12538
|
+
if (s) {
|
|
12539
|
+
ret.push(s);
|
|
12540
|
+
}
|
|
12541
|
+
s = clsName(args);
|
|
12542
|
+
if (s) {
|
|
12543
|
+
ret.push(s);
|
|
12544
|
+
}
|
|
12545
|
+
if (ret.length === 0) {
|
|
12546
|
+
return "";
|
|
12547
|
+
}
|
|
12548
|
+
return ret.join(" ");
|
|
12549
|
+
};
|
|
12550
|
+
}
|
|
12551
|
+
return defaultRowClassName;
|
|
12552
|
+
};
|
|
12553
|
+
const setRowClassName = (rowIndex, rowClassName) => {
|
|
12554
|
+
const key = `${rowIndex}`;
|
|
12555
|
+
if (rowClassName) {
|
|
12556
|
+
rowClassNames.value.set(key, rowClassName);
|
|
12557
|
+
} else {
|
|
12558
|
+
rowClassNames.value.delete(key);
|
|
12559
|
+
}
|
|
12560
|
+
vue.triggerRef(rowClassNames);
|
|
12561
|
+
};
|
|
12562
|
+
const clearRowClassName = () => {
|
|
12563
|
+
rowClassNames.value.clear();
|
|
12564
|
+
vue.triggerRef(rowClassNames);
|
|
12565
|
+
};
|
|
12499
12566
|
const tableRef = vue.ref();
|
|
12500
12567
|
useExpose({
|
|
12501
12568
|
// 清空selection
|
|
@@ -12609,7 +12676,13 @@
|
|
|
12609
12676
|
// 移除列属性配置
|
|
12610
12677
|
removeColumnSetting,
|
|
12611
12678
|
// 设置cell class name
|
|
12612
|
-
setCellClassName
|
|
12679
|
+
setCellClassName,
|
|
12680
|
+
// 清空cell className
|
|
12681
|
+
clearCellClassName,
|
|
12682
|
+
// 设置row class name
|
|
12683
|
+
setRowClassName,
|
|
12684
|
+
// 清空row class name
|
|
12685
|
+
clearRowClassName
|
|
12613
12686
|
});
|
|
12614
12687
|
return () => {
|
|
12615
12688
|
const attrs = filterInheritAttr(context.attrs);
|
|
@@ -12621,7 +12694,8 @@
|
|
|
12621
12694
|
data: source.value,
|
|
12622
12695
|
ref: tableRef,
|
|
12623
12696
|
class: classes.value,
|
|
12624
|
-
[`cell-class-name`]: getCellClassNameProperty(props.cellClassName)
|
|
12697
|
+
[`cell-class-name`]: getCellClassNameProperty(props.cellClassName),
|
|
12698
|
+
[`row-class-name`]: getRowClassNameProperty(props.rowClassName)
|
|
12625
12699
|
};
|
|
12626
12700
|
const tableChildren = {};
|
|
12627
12701
|
if (context.slots.default) {
|
|
@@ -14563,7 +14637,7 @@
|
|
|
14563
14637
|
"fill-opacity": "0.9"
|
|
14564
14638
|
}, null, -1), F = [
|
|
14565
14639
|
A
|
|
14566
|
-
],
|
|
14640
|
+
], X6 = /* @__PURE__ */ vue.defineComponent({
|
|
14567
14641
|
__name: "Uploader",
|
|
14568
14642
|
props: {
|
|
14569
14643
|
class: { type: String, default: "" },
|
|
@@ -14601,13 +14675,13 @@
|
|
|
14601
14675
|
role: "presentation"
|
|
14602
14676
|
}, F, 14, V));
|
|
14603
14677
|
}
|
|
14604
|
-
}),
|
|
14678
|
+
}), L3 = ["aria-labelledby"], B3 = /* @__PURE__ */ vue.createElementVNode("path", {
|
|
14605
14679
|
d: "M834.7 920.1h-643c-23.7 0-43-19.2-43-43 0-23.7 19.2-43 43-43h643c23.7 0 43 19.2 43 43 0 23.7-19.3 43-43 43zm0-729.2h-643c-23.7 0-43-19.2-43-43 0-23.7 19.2-43 43-43h643c23.7 0 43 19.2 43 43s-19.3 43-43 43zm0 354.6h-643c-23.7 0-43-19.2-43-43 0-23.7 19.2-43 43-43h643c23.7 0 43 19.2 43 43 0 23.7-19.3 43-43 43z",
|
|
14606
14680
|
fill: "currentColor",
|
|
14607
14681
|
"fill-opacity": "0.9"
|
|
14608
|
-
}, null, -1),
|
|
14609
|
-
|
|
14610
|
-
],
|
|
14682
|
+
}, null, -1), V3 = [
|
|
14683
|
+
B3
|
|
14684
|
+
], ds = /* @__PURE__ */ vue.defineComponent({
|
|
14611
14685
|
__name: "MoreH",
|
|
14612
14686
|
props: {
|
|
14613
14687
|
class: { type: String, default: "" },
|
|
@@ -14643,15 +14717,15 @@
|
|
|
14643
14717
|
viewBox: "0 0 1024 1024",
|
|
14644
14718
|
"aria-labelledby": c.name,
|
|
14645
14719
|
role: "presentation"
|
|
14646
|
-
},
|
|
14720
|
+
}, V3, 14, L3));
|
|
14647
14721
|
}
|
|
14648
|
-
}),
|
|
14722
|
+
}), C4 = ["aria-labelledby"], v4 = /* @__PURE__ */ vue.createElementVNode("path", {
|
|
14649
14723
|
d: "M784 902.4c9.6 19.2 6.4 41.6-12.8 54.4-19.2 9.6-41.6 3.2-51.2-12.8-9.6-19.2-6.4-41.6 12.8-54.4 16-12.8 38.4-8 51.2 12.8zM550.4 984c0 22.4-16 38.4-38.4 38.4s-38.4-16-38.4-38.4v-24c0-22.4 19.2-38.4 41.6-38.4 19.2 0 35.2 16 38.4 38.4v25.6h-3.2zm-240-43.2c-9.6 19.2-35.2 25.6-54.4 16-19.2-9.6-25.6-35.2-16-51.2l28.8-51.2c9.6-19.2 35.2-25.6 54.4-16s25.6 35.2 12.8 54.4l-25.6 48zM121.6 784c-19.2 9.6-41.6 3.2-54.4-16-9.6-19.2-6.4-41.6 12.8-54.4l76.8-44.8c19.2-9.6 41.6-3.2 54.4 16 9.6 19.2 3.2 41.6-16 54.4L121.6 784zM38.4 552C16 552 0 536 0 513.6s16-38.4 38.4-38.4H160c22.4 0 38.4 19.2 38.4 38.4 0 22.4-16 38.4-38.4 38.4H38.4zm44.8-241.6c-19.2-9.6-25.6-35.2-16-51.2 9.6-19.2 35.2-25.6 54.4-16L256 320c19.2 9.6 25.6 35.2 16 54.4s-35.2 25.6-54.4 16l-134.4-80zm160-185.6 92.8 160c9.6 19.2 35.2 25.6 54.4 12.8s25.6-35.2 12.8-54.4l-92.8-160C297.6 64 275.2 60.8 256 70.4c-16 12.8-22.4 33.6-12.8 54.4zM473.6 40c0-22.4 16-38.4 38.4-38.4s38.4 19.2 38.4 38.4v184c0 22.4-19.2 38.4-38.4 38.4-22.4 0-38.4-19.2-38.4-38.4V40zm240 43.2c9.6-19.2 35.2-25.6 54.4-16 19.2 9.6 25.6 35.2 16 51.2l-92.8 160c-9.6 19.2-35.2 25.6-54.4 16-19.2-9.6-25.6-35.2-12.8-54.4l89.6-156.8zm188.8 160-160 92.8c-19.2 9.6-25.6 35.2-16 54.4 12.8 19.2 35.2 25.6 54.4 12.8l160-92.8c19.2-9.6 25.6-35.2 12.8-54.4-9.6-16-32-25.6-51.2-12.8zM985.6 472c22.4 0 38.4 16 38.4 38.4s-16 38.4-38.4 38.4H800c-22.4 0-38.4-19.2-38.4-38.4 0-22.4 19.2-38.4 38.4-38.4h185.6z",
|
|
14650
14724
|
fill: "currentColor",
|
|
14651
14725
|
"fill-opacity": "0.9"
|
|
14652
|
-
}, null, -1),
|
|
14653
|
-
|
|
14654
|
-
],
|
|
14726
|
+
}, null, -1), $4 = [
|
|
14727
|
+
v4
|
|
14728
|
+
], $s = /* @__PURE__ */ vue.defineComponent({
|
|
14655
14729
|
__name: "Loading",
|
|
14656
14730
|
props: {
|
|
14657
14731
|
class: { type: String, default: "" },
|
|
@@ -14687,15 +14761,15 @@
|
|
|
14687
14761
|
viewBox: "0 0 1024 1024",
|
|
14688
14762
|
"aria-labelledby": c.name,
|
|
14689
14763
|
role: "presentation"
|
|
14690
|
-
},
|
|
14764
|
+
}, $4, 14, C4));
|
|
14691
14765
|
}
|
|
14692
|
-
}),
|
|
14766
|
+
}), _0 = ["aria-labelledby"], w0 = /* @__PURE__ */ vue.createElementVNode("path", {
|
|
14693
14767
|
d: "M981.577 1024c-11.703 0-23.406-2.926-32.183-11.703L13.166 76.07c-14.629-17.555-14.629-46.812 0-64.366 17.554-14.629 46.811-14.629 64.365 0L1013.76 947.93c17.554 17.555 17.554 43.886 0 61.44-8.777 11.703-20.48 14.629-32.183 14.629zm-936.228 0c-11.703 0-23.406-2.926-32.183-11.703-17.555-17.554-17.555-43.886 0-61.44L949.394 14.63c17.555-17.555 43.886-17.555 61.44 0 17.555 17.554 17.555 43.885 0 61.44L74.606 1012.297C68.754 1021.074 57.05 1024 45.349 1024z",
|
|
14694
14768
|
fill: "currentColor",
|
|
14695
14769
|
"fill-opacity": "0.9"
|
|
14696
|
-
}, null, -1),
|
|
14697
|
-
|
|
14698
|
-
],
|
|
14770
|
+
}, null, -1), S0 = [
|
|
14771
|
+
w0
|
|
14772
|
+
], N7 = /* @__PURE__ */ vue.defineComponent({
|
|
14699
14773
|
__name: "Close",
|
|
14700
14774
|
props: {
|
|
14701
14775
|
class: { type: String, default: "" },
|
|
@@ -14731,15 +14805,15 @@
|
|
|
14731
14805
|
viewBox: "0 0 1026 1024",
|
|
14732
14806
|
"aria-labelledby": c.name,
|
|
14733
14807
|
role: "presentation"
|
|
14734
|
-
},
|
|
14808
|
+
}, S0, 14, _0));
|
|
14735
14809
|
}
|
|
14736
|
-
}),
|
|
14810
|
+
}), L0 = ["aria-labelledby"], B0 = /* @__PURE__ */ vue.createElementVNode("path", {
|
|
14737
14811
|
d: "M159.289 500.622c62.578 0 125.155 17.067 221.867 102.4 8.533 5.69 19.91 5.69 25.6 0 48.355-54.044 238.933-261.689 455.11-329.955 0 0 28.445-5.69 42.667 19.91 8.534 17.067 19.911 34.134-5.689 54.045-22.755 17.067-264.533 179.2-440.888 440.89l-2.845 2.844c-11.378 8.533-68.267 51.2-119.467-14.223-56.888-71.11-85.333-139.377-196.266-196.266-2.845 0-2.845-2.845-5.69-5.69-11.377-11.377-54.044-73.955 25.6-73.955z",
|
|
14738
14812
|
fill: "currentColor",
|
|
14739
14813
|
"fill-opacity": "0.9"
|
|
14740
|
-
}, null, -1),
|
|
14741
|
-
|
|
14742
|
-
],
|
|
14814
|
+
}, null, -1), V0 = [
|
|
14815
|
+
B0
|
|
14816
|
+
], M7 = /* @__PURE__ */ vue.defineComponent({
|
|
14743
14817
|
__name: "Checklist",
|
|
14744
14818
|
props: {
|
|
14745
14819
|
class: { type: String, default: "" },
|
|
@@ -14775,15 +14849,15 @@
|
|
|
14775
14849
|
viewBox: "0 0 1024 1024",
|
|
14776
14850
|
"aria-labelledby": c.name,
|
|
14777
14851
|
role: "presentation"
|
|
14778
|
-
},
|
|
14852
|
+
}, V0, 14, L0));
|
|
14779
14853
|
}
|
|
14780
|
-
}),
|
|
14854
|
+
}), N6 = ["aria-labelledby"], C6 = /* @__PURE__ */ vue.createElementVNode("path", {
|
|
14781
14855
|
d: "m387.547 980.846 305.006-397.532a117.102 117.102 0 0 0 0-142.628L387.584 43.154a44.837 44.837 0 0 0-71.131 54.492l305.042 397.568a27.538 27.538 0 0 1 0 33.572L316.489 926.318a44.8 44.8 0 0 0 71.058 54.564",
|
|
14782
14856
|
fill: "currentColor",
|
|
14783
14857
|
"fill-opacity": "0.9"
|
|
14784
|
-
}, null, -1),
|
|
14785
|
-
|
|
14786
|
-
],
|
|
14858
|
+
}, null, -1), v6 = [
|
|
14859
|
+
C6
|
|
14860
|
+
], J7 = /* @__PURE__ */ vue.defineComponent({
|
|
14787
14861
|
__name: "ArrowRight",
|
|
14788
14862
|
props: {
|
|
14789
14863
|
class: { type: String, default: "" },
|
|
@@ -14819,7 +14893,7 @@
|
|
|
14819
14893
|
viewBox: "0 0 1024 1024",
|
|
14820
14894
|
"aria-labelledby": c.name,
|
|
14821
14895
|
role: "presentation"
|
|
14822
|
-
},
|
|
14896
|
+
}, v6, 14, N6));
|
|
14823
14897
|
}
|
|
14824
14898
|
});
|
|
14825
14899
|
|
|
@@ -15364,7 +15438,7 @@
|
|
|
15364
15438
|
}
|
|
15365
15439
|
|
|
15366
15440
|
const { create: create$k, componentName: componentName$j, scope: scope$h } = createComponent("tabs-bar");
|
|
15367
|
-
const _sfc_main$k = create$k(component$f(componentName$j, scope$h,
|
|
15441
|
+
const _sfc_main$k = create$k(component$f(componentName$j, scope$h, ds, false));
|
|
15368
15442
|
|
|
15369
15443
|
const TabsStatesKey = Symbol("TabsStatesKey");
|
|
15370
15444
|
const tabsContainerProps = {
|
|
@@ -15627,7 +15701,7 @@
|
|
|
15627
15701
|
}
|
|
15628
15702
|
|
|
15629
15703
|
const { create: create$i, componentName: componentName$h, scope: scope$f } = createComponent("tabs-pane");
|
|
15630
|
-
const _sfc_main$i = create$i(component$d(componentName$h, scope$f,
|
|
15704
|
+
const _sfc_main$i = create$i(component$d(componentName$h, scope$f, $s));
|
|
15631
15705
|
|
|
15632
15706
|
const stepBarProps = {
|
|
15633
15707
|
// 步骤栏方向
|
|
@@ -16274,7 +16348,7 @@
|
|
|
16274
16348
|
}
|
|
16275
16349
|
|
|
16276
16350
|
const { componentName: componentName$g, create: create$h, scope: scope$e } = createComponent("steps-bar");
|
|
16277
|
-
const _sfc_main$h = create$h(component$c(componentName$g, scope$e,
|
|
16351
|
+
const _sfc_main$h = create$h(component$c(componentName$g, scope$e, M7, J7));
|
|
16278
16352
|
|
|
16279
16353
|
const InnerPageScopeKey$1 = Symbol.for("InnerPageScopeKey");
|
|
16280
16354
|
const PageWrapperKey$1 = Symbol.for("PageWrapperKey");
|
|
@@ -16282,14 +16356,22 @@
|
|
|
16282
16356
|
return {
|
|
16283
16357
|
// 属性
|
|
16284
16358
|
props: {
|
|
16359
|
+
// class
|
|
16360
|
+
class: {
|
|
16361
|
+
type: [String]
|
|
16362
|
+
},
|
|
16285
16363
|
// 标题
|
|
16286
16364
|
title: {
|
|
16287
16365
|
type: [String]
|
|
16288
16366
|
},
|
|
16367
|
+
// 隐藏header
|
|
16368
|
+
hideHeader: {
|
|
16369
|
+
type: [Boolean]
|
|
16370
|
+
},
|
|
16289
16371
|
// 是否可拖动
|
|
16290
16372
|
draggable: {
|
|
16291
16373
|
type: [Boolean],
|
|
16292
|
-
default: true
|
|
16374
|
+
default: () => true
|
|
16293
16375
|
},
|
|
16294
16376
|
// 是否加入body
|
|
16295
16377
|
appendToBody: {
|
|
@@ -16299,12 +16381,12 @@
|
|
|
16299
16381
|
// 是否可以通过点击 modal 关闭 Dialog
|
|
16300
16382
|
closeOnClickModal: {
|
|
16301
16383
|
type: [Boolean],
|
|
16302
|
-
default: false
|
|
16384
|
+
default: () => false
|
|
16303
16385
|
},
|
|
16304
16386
|
// 是否可以通过按下 ESC 关闭 Dialog
|
|
16305
16387
|
closeOnPressEscape: {
|
|
16306
16388
|
type: [Boolean],
|
|
16307
|
-
default: true
|
|
16389
|
+
default: () => true
|
|
16308
16390
|
}
|
|
16309
16391
|
},
|
|
16310
16392
|
// setup
|
|
@@ -16323,7 +16405,7 @@
|
|
|
16323
16405
|
};
|
|
16324
16406
|
return () => {
|
|
16325
16407
|
const attrs = context.attrs;
|
|
16326
|
-
const
|
|
16408
|
+
const data = {
|
|
16327
16409
|
...attrs,
|
|
16328
16410
|
title: props.title,
|
|
16329
16411
|
draggable: props.draggable,
|
|
@@ -16334,12 +16416,19 @@
|
|
|
16334
16416
|
"close-on-press-escape": props.closeOnPressEscape,
|
|
16335
16417
|
"before-close": beforeClose
|
|
16336
16418
|
};
|
|
16419
|
+
const classes = ["fox-dialog-item "];
|
|
16420
|
+
if (props.hideHeader) {
|
|
16421
|
+
classes.push("hide-header");
|
|
16422
|
+
}
|
|
16423
|
+
if (props.class) {
|
|
16424
|
+
classes.push(props.class);
|
|
16425
|
+
}
|
|
16426
|
+
data.class = classes.join(" ");
|
|
16337
16427
|
const children = {};
|
|
16338
16428
|
if (typeof context.slots.default === "function") {
|
|
16339
|
-
|
|
16340
|
-
children.default = () => node;
|
|
16429
|
+
children.default = context.slots.default;
|
|
16341
16430
|
}
|
|
16342
|
-
return vue.h(elementPlus.ElDialog,
|
|
16431
|
+
return vue.h(elementPlus.ElDialog, data, children);
|
|
16343
16432
|
};
|
|
16344
16433
|
}
|
|
16345
16434
|
};
|
|
@@ -16650,7 +16739,7 @@
|
|
|
16650
16739
|
const _sfc_main$e = create$e(
|
|
16651
16740
|
component$a(componentName$d, {
|
|
16652
16741
|
FoxOverLay: OverLay,
|
|
16653
|
-
Close:
|
|
16742
|
+
Close: N7
|
|
16654
16743
|
})
|
|
16655
16744
|
);
|
|
16656
16745
|
|
|
@@ -17429,7 +17518,7 @@
|
|
|
17429
17518
|
}
|
|
17430
17519
|
|
|
17431
17520
|
const { componentName: componentName$b, create: create$b, scope: scope$b } = createComponent("infinite-loading");
|
|
17432
|
-
const _sfc_main$b = create$b(component$8(componentName$b, scope$b,
|
|
17521
|
+
const _sfc_main$b = create$b(component$8(componentName$b, scope$b, $s));
|
|
17433
17522
|
|
|
17434
17523
|
const MIN_DISTANCE = 10;
|
|
17435
17524
|
function getDirection(x, y) {
|
|
@@ -17813,7 +17902,7 @@
|
|
|
17813
17902
|
};
|
|
17814
17903
|
|
|
17815
17904
|
const { componentName: componentName$a, create: create$a, scope: scope$a } = createComponent("pull-refresh");
|
|
17816
|
-
const _sfc_main$a = create$a(component$7(componentName$a, scope$a,
|
|
17905
|
+
const _sfc_main$a = create$a(component$7(componentName$a, scope$a, $s));
|
|
17817
17906
|
|
|
17818
17907
|
function component$6(componentName, scope) {
|
|
17819
17908
|
return {
|
|
@@ -18709,7 +18798,7 @@
|
|
|
18709
18798
|
};
|
|
18710
18799
|
|
|
18711
18800
|
const { componentName: componentName$6, create: create$6, scope: scope$6 } = createComponent("floating-button");
|
|
18712
|
-
const _sfc_main$6 = create$6(component$3(componentName$6, scope$6,
|
|
18801
|
+
const _sfc_main$6 = create$6(component$3(componentName$6, scope$6, X6, false));
|
|
18713
18802
|
|
|
18714
18803
|
function isWindow(val) {
|
|
18715
18804
|
return val === window;
|
|
@@ -20299,6 +20388,10 @@
|
|
|
20299
20388
|
// custom style
|
|
20300
20389
|
customStyle: {
|
|
20301
20390
|
type: [Object]
|
|
20391
|
+
},
|
|
20392
|
+
// leave hide(鼠标离开,自动隐藏)
|
|
20393
|
+
leaveHide: {
|
|
20394
|
+
type: [Boolean]
|
|
20302
20395
|
}
|
|
20303
20396
|
};
|
|
20304
20397
|
|
|
@@ -20686,6 +20779,16 @@
|
|
|
20686
20779
|
mounted.value = false;
|
|
20687
20780
|
}
|
|
20688
20781
|
};
|
|
20782
|
+
const onMouseleave = (e) => {
|
|
20783
|
+
if (!dialogRef.value || visible.value === false) {
|
|
20784
|
+
return;
|
|
20785
|
+
}
|
|
20786
|
+
const { relatedTarget } = e;
|
|
20787
|
+
if (!dialogRef.value.contains(relatedTarget)) {
|
|
20788
|
+
visible.value = false;
|
|
20789
|
+
emit("update:visible", false);
|
|
20790
|
+
}
|
|
20791
|
+
};
|
|
20689
20792
|
expose({
|
|
20690
20793
|
doLayout
|
|
20691
20794
|
});
|
|
@@ -20717,6 +20820,9 @@
|
|
|
20717
20820
|
style: styles.value,
|
|
20718
20821
|
onAnimationend
|
|
20719
20822
|
};
|
|
20823
|
+
if (props.leaveHide) {
|
|
20824
|
+
data["onMouseleave"] = onMouseleave;
|
|
20825
|
+
}
|
|
20720
20826
|
const dialogNode = vue.h("div", data, { default: () => children });
|
|
20721
20827
|
rootNodes.push(dialogNode);
|
|
20722
20828
|
return rootNodes;
|