hfn-components 0.6.1 → 0.6.2
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.css +1 -0
- package/es/_virtual/_plugin-vue_export-helper.mjs +9 -0
- package/es/component.d.ts +3 -0
- package/es/component.mjs +14 -0
- package/es/components/chart/index.d.ts +201 -0
- package/es/components/chart/index.mjs +7 -0
- package/es/components/chart/src/HtChart.d.ts +77 -0
- package/es/components/chart/src/HtChart.mjs +93 -0
- package/es/components/chart/src/HtChart.vue.d.ts +207 -0
- package/es/components/chart/src/HtChart.vue.mjs +90 -0
- package/es/components/chart/src/HtChart.vue2.mjs +109 -0
- package/es/components/chart/src/chartConfig.d.ts +7 -0
- package/es/components/chart/src/chartConfig.mjs +88 -0
- package/es/components/chart/style/index.d.ts +1 -0
- package/es/components/chart/style/index.mjs +1 -0
- package/es/components/elTable/index.d.ts +821 -0
- package/es/components/elTable/index.mjs +7 -0
- package/es/components/elTable/src/columnDeal.vue.d.ts +65 -0
- package/es/components/elTable/src/columnDeal.vue.mjs +42 -0
- package/es/components/elTable/src/columnDeal.vue2.mjs +19 -0
- package/es/components/elTable/src/elTable.d.ts +56 -0
- package/es/components/elTable/src/elTable.mjs +49 -0
- package/es/components/elTable/src/elTable.vue.d.ts +820 -0
- package/es/components/elTable/src/elTable.vue.mjs +114 -0
- package/es/components/elTable/src/elTable.vue2.mjs +51 -0
- package/es/components/htTarget/index.d.ts +2028 -0
- package/es/components/htTarget/index.mjs +6 -0
- package/es/components/htTarget/src/htTarget.d.ts +25 -0
- package/es/components/htTarget/src/htTarget.mjs +20 -0
- package/es/components/htTarget/src/htTarget.vue.d.ts +2027 -0
- package/es/components/htTarget/src/htTarget.vue.mjs +240 -0
- package/es/components/htTarget/src/htTarget.vue2.mjs +158 -0
- package/es/components/htTarget/style/index.d.ts +1 -0
- package/es/components/htTarget/style/index.mjs +1 -0
- package/es/components/index.d.ts +4 -0
- package/es/components/index.mjs +7 -0
- package/es/components/pieChart/index.d.ts +104 -0
- package/es/components/pieChart/index.mjs +7 -0
- package/es/components/pieChart/src/HtPieChart.d.ts +36 -0
- package/es/components/pieChart/src/HtPieChart.mjs +42 -0
- package/es/components/pieChart/src/HtPieChart.vue.d.ts +109 -0
- package/es/components/pieChart/src/HtPieChart.vue.mjs +61 -0
- package/es/components/pieChart/src/HtPieChart.vue2.mjs +103 -0
- package/es/components/pieChart/style/index.d.ts +1 -0
- package/es/components/pieChart/style/index.mjs +1 -0
- package/es/components/table/HtTable.d.ts +142 -0
- package/es/components/table/HtTable.mjs +136 -0
- package/es/components/table/HtTable.vue.d.ts +1847 -0
- package/es/components/table/HtTable.vue.mjs +449 -0
- package/es/components/table/HtTable.vue2.mjs +124 -0
- package/es/components/table/index.d.ts +1845 -0
- package/es/components/table/index.mjs +7 -0
- package/es/constants/chartConfig.d.ts +8 -0
- package/es/constants/chartConfig.mjs +148 -0
- package/es/constants/index.d.ts +4 -0
- package/es/constants/index.mjs +4 -0
- package/es/constants/key.d.ts +1 -0
- package/es/constants/key.mjs +3 -0
- package/es/constants/table.d.ts +125 -0
- package/es/constants/table.mjs +156 -0
- package/es/constants/target.d.ts +15 -0
- package/es/constants/target.mjs +59 -0
- package/es/defaults.d.ts +4 -0
- package/es/defaults.mjs +7 -0
- package/es/index.d.ts +5 -0
- package/es/index.mjs +13 -0
- package/es/make-installer.d.ts +4 -0
- package/es/make-installer.mjs +15 -0
- package/es/plugin.d.ts +2 -0
- package/es/plugin.mjs +3 -0
- package/es/utils/chart.d.ts +8 -0
- package/es/utils/chart.mjs +197 -0
- package/es/utils/common.d.ts +3 -0
- package/es/utils/common.mjs +15 -0
- package/es/utils/index.d.ts +4 -0
- package/es/utils/index.mjs +4 -0
- package/es/utils/table.d.ts +2 -0
- package/es/utils/table.mjs +31 -0
- package/es/utils/tool.d.ts +2 -0
- package/es/utils/tool.mjs +42 -0
- package/global.d.ts +14 -0
- package/package.json +1 -1
- package/theme-chalk/ht-chart.css +1 -0
- package/theme-chalk/ht-table.css +1 -0
- package/theme-chalk/ht-target.css +1 -0
- package/theme-chalk/index.css +1 -0
- package/theme-chalk/src/chart.scss +58 -0
- package/theme-chalk/src/index.scss +3 -0
- package/theme-chalk/src/table.scss +45 -0
- package/theme-chalk/src/target.scss +39 -0
- package/component.ts +0 -15
- package/defaults.ts +0 -5
- package/index.ts +0 -6
- package/make-installer.ts +0 -17
- package/plugin.ts +0 -1
|
@@ -0,0 +1,197 @@
|
|
|
1
|
+
const legendEnterOperate = (options, name) => {
|
|
2
|
+
options.series.forEach((series) => {
|
|
3
|
+
if (series.name === name) {
|
|
4
|
+
if (series.type === "line") {
|
|
5
|
+
if (series.lineStyle) {
|
|
6
|
+
series.lineStyle.opacity = 1;
|
|
7
|
+
} else {
|
|
8
|
+
series.lineStyle = {
|
|
9
|
+
opacity: 1
|
|
10
|
+
};
|
|
11
|
+
}
|
|
12
|
+
} else if (series.type === "bar") {
|
|
13
|
+
if (series.itemStyle) {
|
|
14
|
+
series.itemStyle.opacity = 1;
|
|
15
|
+
} else {
|
|
16
|
+
series.itemStyle = {
|
|
17
|
+
opacity: 1
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
} else {
|
|
22
|
+
if (series.type === "line") {
|
|
23
|
+
if (series.lineStyle) {
|
|
24
|
+
series.lineStyle.opacity = 0.1;
|
|
25
|
+
} else {
|
|
26
|
+
series.lineStyle = {
|
|
27
|
+
opacity: 0.1
|
|
28
|
+
};
|
|
29
|
+
}
|
|
30
|
+
} else if (series.type === "bar") {
|
|
31
|
+
if (series.itemStyle) {
|
|
32
|
+
series.itemStyle.opacity = 0.1;
|
|
33
|
+
} else {
|
|
34
|
+
series.itemStyle = {
|
|
35
|
+
opacity: 0.1
|
|
36
|
+
};
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
});
|
|
41
|
+
};
|
|
42
|
+
const legendLeaveOperate = (options) => {
|
|
43
|
+
options.series.forEach((series) => {
|
|
44
|
+
if (series.type === "line") {
|
|
45
|
+
if (series.lineStyle) {
|
|
46
|
+
series.lineStyle.opacity = 1;
|
|
47
|
+
} else {
|
|
48
|
+
series.lineStyle = {
|
|
49
|
+
opacity: 1
|
|
50
|
+
};
|
|
51
|
+
}
|
|
52
|
+
} else if (series.type === "bar") {
|
|
53
|
+
if (series.itemStyle) {
|
|
54
|
+
series.itemStyle.opacity = 1;
|
|
55
|
+
} else {
|
|
56
|
+
series.itemStyle = {
|
|
57
|
+
opacity: 1
|
|
58
|
+
};
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
});
|
|
62
|
+
};
|
|
63
|
+
const setEchartXAxis = (options, type, xAxisData) => {
|
|
64
|
+
if (type === "category") {
|
|
65
|
+
const xAxis = [...xAxisData];
|
|
66
|
+
options.xAxis = {
|
|
67
|
+
type,
|
|
68
|
+
data: xAxis,
|
|
69
|
+
boundaryGap: true,
|
|
70
|
+
axisTick: {
|
|
71
|
+
alignWithLabel: true
|
|
72
|
+
}
|
|
73
|
+
};
|
|
74
|
+
} else if (type === "time") {
|
|
75
|
+
options.xAxis = {
|
|
76
|
+
type,
|
|
77
|
+
minInterval: 24 * 60 * 60 * 1e3,
|
|
78
|
+
axisLine: {
|
|
79
|
+
onZero: false
|
|
80
|
+
}
|
|
81
|
+
};
|
|
82
|
+
}
|
|
83
|
+
};
|
|
84
|
+
const setEchartYAxis = (options, props) => {
|
|
85
|
+
options.yAxis = {
|
|
86
|
+
type: "value",
|
|
87
|
+
axisLabel: {
|
|
88
|
+
show: true,
|
|
89
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
90
|
+
formatter: function(val) {
|
|
91
|
+
return (props.yAxisUnit === "%" ? val > 0 ? "+" : "" : "") + parseFloat(val.toFixed(props.floatNumber)) + props.yAxisUnit;
|
|
92
|
+
}
|
|
93
|
+
},
|
|
94
|
+
...props.yAxisObj
|
|
95
|
+
};
|
|
96
|
+
};
|
|
97
|
+
const setEchartTitle = (options, props) => {
|
|
98
|
+
options.title = [
|
|
99
|
+
{
|
|
100
|
+
left: "left",
|
|
101
|
+
text: props.titleText,
|
|
102
|
+
itemGap: 0,
|
|
103
|
+
textStyle: {
|
|
104
|
+
fontSize: 12,
|
|
105
|
+
fontWeight: "normal"
|
|
106
|
+
}
|
|
107
|
+
},
|
|
108
|
+
{
|
|
109
|
+
left: "right",
|
|
110
|
+
subtext: props.titleText2,
|
|
111
|
+
itemGap: 0
|
|
112
|
+
}
|
|
113
|
+
];
|
|
114
|
+
};
|
|
115
|
+
const setEchartTooltip = (options, props) => {
|
|
116
|
+
options.tooltip = {
|
|
117
|
+
trigger: "axis",
|
|
118
|
+
// tooltip提示框格式自定义
|
|
119
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
120
|
+
formatter: function(paramItems) {
|
|
121
|
+
let html = "";
|
|
122
|
+
if (Array.isArray(paramItems)) {
|
|
123
|
+
const params = paramItems.filter((item) => item.data !== void 0 && item.data !== null);
|
|
124
|
+
if (params.length === 0) return "";
|
|
125
|
+
if (props.chartType === "category") {
|
|
126
|
+
params.sort((a, b) => b.value - a.value);
|
|
127
|
+
} else {
|
|
128
|
+
params.sort((a, b) => {
|
|
129
|
+
if (Array.isArray(a.value) && Array.isArray(b.value)) {
|
|
130
|
+
return props.collation === "des" ? b.value[1] - a.value[1] : a.value[1] - b.value[1];
|
|
131
|
+
} else {
|
|
132
|
+
return 0;
|
|
133
|
+
}
|
|
134
|
+
});
|
|
135
|
+
}
|
|
136
|
+
html += `<div>${props.chartType === "category" ? params[0].name : Array.isArray(params[0].value) ? params[0].value[0] : ""}</div>`;
|
|
137
|
+
if (params.length > 30) html += '<div style="display: flex;">';
|
|
138
|
+
const len = Math.ceil(params.length / 3);
|
|
139
|
+
for (let i = 0; i < params.length; i++) {
|
|
140
|
+
if ((i + 1) % len === 1 && params.length > 30) {
|
|
141
|
+
html += '<div style="display: flex; flex-direction: column;">';
|
|
142
|
+
}
|
|
143
|
+
if (params[i].value === void 0 || params[i].value === null) ; else {
|
|
144
|
+
html += '<div style="display: flex;align-items:center">';
|
|
145
|
+
html += `<span
|
|
146
|
+
style="display:inline-block;
|
|
147
|
+
margin-right:5px;
|
|
148
|
+
border-radius:10px;
|
|
149
|
+
width:10px;height:10px;
|
|
150
|
+
background-color:${params[i].color};
|
|
151
|
+
">
|
|
152
|
+
</span>`;
|
|
153
|
+
if (props.isReturn) {
|
|
154
|
+
if (
|
|
155
|
+
// params[i].seriesId === 'excess' ||
|
|
156
|
+
params[i].seriesName === "\u7D2F\u8BA1\u8D85\u989D"
|
|
157
|
+
) {
|
|
158
|
+
html += `<span style='color:${params[i].color}'>
|
|
159
|
+
${params[i].seriesName}</span>\uFF1A${params[i].value[1].toFixed(2)}%
|
|
160
|
+
`;
|
|
161
|
+
} else if (props.chartType === "category") {
|
|
162
|
+
console.log(props.auxiliaryData);
|
|
163
|
+
html += `<span style='color:${params[i].color}'>
|
|
164
|
+
${params[i].seriesName}</span>\uFF1A${props.auxiliaryData[params[i].seriesName][params[0].name]}(${params[i].value || params[i].value === 0 ? Number(params[i].value).toFixed(props.floatNumber) : ""}%)
|
|
165
|
+
`;
|
|
166
|
+
} else {
|
|
167
|
+
html += `<span style='color:${params[i].color}'>${params[i].seriesName}</span>\uFF1A${params[i].value[2]?.toFixed(props.floatNumber)}\uFF08${params[i].value[1] > 0 ? "+" : ""}${params[i].value[1]}%\uFF09`;
|
|
168
|
+
}
|
|
169
|
+
} else {
|
|
170
|
+
if (props.chartType === "category") {
|
|
171
|
+
html += `<span style='color:${params[i].color}'>
|
|
172
|
+
${params[i].seriesName.includes("series") ? params[i].name : params[i].seriesName}
|
|
173
|
+
</span>\uFF1A
|
|
174
|
+
${params[i].value.toFixed(props.floatNumber)}${props.tooltipUnit}
|
|
175
|
+
`;
|
|
176
|
+
} else {
|
|
177
|
+
html += `<span style='color:${params[i].color}'>${params[i].seriesName}</span>\uFF1A${params[i].value[1]?.toFixed(props.floatNumber)}${props.tooltipUnit}`;
|
|
178
|
+
}
|
|
179
|
+
}
|
|
180
|
+
html += "</div>";
|
|
181
|
+
}
|
|
182
|
+
if ((i + 1) % len === 0 && params.length > 30) {
|
|
183
|
+
html += "</div>";
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
if (params.length > 30) html += "</div>";
|
|
187
|
+
}
|
|
188
|
+
return html;
|
|
189
|
+
},
|
|
190
|
+
textStyle: {
|
|
191
|
+
color: "rgba(0,0,0,0.7)"
|
|
192
|
+
// 设置文字颜色
|
|
193
|
+
}
|
|
194
|
+
};
|
|
195
|
+
};
|
|
196
|
+
|
|
197
|
+
export { legendEnterOperate, legendLeaveOperate, setEchartTitle, setEchartTooltip, setEchartXAxis, setEchartYAxis };
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
const withInstall = (main, extra) => {
|
|
2
|
+
main.install = (app) => {
|
|
3
|
+
for (const comp of [main, ...Object.values(extra ?? {})]) {
|
|
4
|
+
app.component(comp.name, comp);
|
|
5
|
+
}
|
|
6
|
+
};
|
|
7
|
+
if (extra) {
|
|
8
|
+
for (const [key, comp] of Object.entries(extra)) {
|
|
9
|
+
main[key] = comp;
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
return main;
|
|
13
|
+
};
|
|
14
|
+
|
|
15
|
+
export { withInstall };
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export { withInstall } from './common.mjs';
|
|
2
|
+
export { handleData, handleText } from './table.mjs';
|
|
3
|
+
export { dataHandle, splitK } from './tool.mjs';
|
|
4
|
+
export { legendEnterOperate, legendLeaveOperate, setEchartTitle, setEchartTooltip, setEchartXAxis, setEchartYAxis } from './chart.mjs';
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { splitK } from './tool.mjs';
|
|
2
|
+
|
|
3
|
+
const handleData = (value, type) => {
|
|
4
|
+
if (isNaN(parseFloat(value))) return "-";
|
|
5
|
+
let val = parseFloat(value);
|
|
6
|
+
if (type.includes("percent")) {
|
|
7
|
+
val = val * 100;
|
|
8
|
+
}
|
|
9
|
+
const floatMatch = type.match(/float(\d+)/);
|
|
10
|
+
if (floatMatch) {
|
|
11
|
+
const precision = Number(floatMatch[1]);
|
|
12
|
+
val = val.toFixed(precision);
|
|
13
|
+
}
|
|
14
|
+
if (type.includes("splitK")) {
|
|
15
|
+
val = splitK(val);
|
|
16
|
+
}
|
|
17
|
+
if (type.includes("sign")) {
|
|
18
|
+
val = Number(val) > 0 ? "+" + val : val;
|
|
19
|
+
}
|
|
20
|
+
if (type.includes("percent")) {
|
|
21
|
+
val = val + "%";
|
|
22
|
+
}
|
|
23
|
+
return val;
|
|
24
|
+
};
|
|
25
|
+
const handleText = (value, type) => {
|
|
26
|
+
if (type === "name") {
|
|
27
|
+
return value;
|
|
28
|
+
}
|
|
29
|
+
};
|
|
30
|
+
|
|
31
|
+
export { handleData, handleText };
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
function dataHandle(val, isPer, floatNum) {
|
|
2
|
+
val = parseFloat(val);
|
|
3
|
+
if (isNaN(val)) {
|
|
4
|
+
return "-";
|
|
5
|
+
} else {
|
|
6
|
+
if (isPer) {
|
|
7
|
+
val = val * 100;
|
|
8
|
+
}
|
|
9
|
+
if (Number(val.toFixed(floatNum)) === 0) {
|
|
10
|
+
const a = 0;
|
|
11
|
+
return a.toFixed(floatNum);
|
|
12
|
+
} else {
|
|
13
|
+
return val.toFixed(floatNum);
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
function splitK(num) {
|
|
18
|
+
let decimal = String(num).split(".")[1] || "";
|
|
19
|
+
if (decimal === "") {
|
|
20
|
+
decimal = "00";
|
|
21
|
+
}
|
|
22
|
+
const tempArr = [];
|
|
23
|
+
const revNumArr = String(num).split(".")[0].split("").reverse();
|
|
24
|
+
const mark = revNumArr[revNumArr.length - 1];
|
|
25
|
+
if (mark === "-") {
|
|
26
|
+
revNumArr.splice(-1, 1);
|
|
27
|
+
}
|
|
28
|
+
for (const i in revNumArr) {
|
|
29
|
+
tempArr.push(revNumArr[i]);
|
|
30
|
+
const index = parseFloat(i);
|
|
31
|
+
if ((index + 1) % 3 === 0 && Number(i) !== revNumArr.length - 1) {
|
|
32
|
+
tempArr.push(",");
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
if (mark === "-") {
|
|
36
|
+
tempArr.push(mark);
|
|
37
|
+
}
|
|
38
|
+
const zs = tempArr.reverse().join("");
|
|
39
|
+
return decimal ? zs + "." + decimal : zs;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
export { dataHandle, splitK };
|
package/global.d.ts
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
// declare module '*.vue' {
|
|
2
|
+
// import { defineComponent } from 'vue'
|
|
3
|
+
// const componentOptions:ReturnType<typeof defineComponent>
|
|
4
|
+
// export default componentOptions
|
|
5
|
+
// }
|
|
6
|
+
|
|
7
|
+
declare module '@vue/runtime-core' {
|
|
8
|
+
export interface GlobalComponents {
|
|
9
|
+
HtTable: (typeof import('hfn-components'))['HtTable']
|
|
10
|
+
}
|
|
11
|
+
interface ComponentCustomProperties {
|
|
12
|
+
// 你可以在这里添加自定义属性
|
|
13
|
+
}
|
|
14
|
+
}
|
package/package.json
CHANGED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.echart-box{display:flex;flex-direction:column;height:100%;position:relative;width:100%}.echart-content{flex:auto}.echart-lenged{box-sizing:border-box;display:flex;flex-wrap:wrap;font-size:12px;height:auto;margin-top:6px;padding-right:22px;position:relative;width:100%;z-index:999}.bg-span{height:2px;width:14px}.bg-span,.bg-span-bar{display:inline-block;margin-right:6px}.bg-span-bar{border-radius:2px;height:10px;width:16px}.span-box{cursor:pointer;margin-left:5px;margin-right:6px}.noData,.span-box{align-items:center;display:flex}.noData{bottom:0;color:#ccc;font-size:16px;justify-content:center;position:absolute}._100,.noData{height:100%;width:100%}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.header-text-wrap{line-height:1.5;white-space:pre-line}.header-only-border .el-table,.header-only-border .el-table__inner-wrapper,.header-only-border.el-table--border{border:none!important}.header-only-border .el-table:after,.header-only-border .el-table:before,.header-only-border .el-table__inner-wrapper:after,.header-only-border .el-table__inner-wrapper:before{display:none!important}.header-only-border .el-table__cell{border:none!important}.header-only-border .el-table__header .el-table__cell{border:none!important;position:relative}.header-only-border .el-table__header .el-table__cell:after{background-color:#dcdfe6;content:"";height:40%;position:absolute;right:0;top:50%;transform:translateY(-50%);width:1px}.header-only-border .el-table__header .el-table__cell:last-child:after{display:none}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.dialog{padding:24px!important;width:860px!important}.factor-content{display:flex;flex-direction:column;flex-wrap:wrap;height:380px;width:100%}.factor_item{width:33.33%}.check_item,.factor_item{display:flex;margin-bottom:10px}.check_item{justify-content:space-between}.flex-alignCnter{align-items:center;cursor:pointer;display:flex}.target-head{display:grid;grid:auto/repeat(5,1fr)}.flow-col{border-left:1px solid #e8e8e8;height:520px;overflow-y:auto;padding-left:10px}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.echart-box{display:flex;flex-direction:column;height:100%;position:relative;width:100%}.echart-content{flex:auto}.echart-lenged{box-sizing:border-box;display:flex;flex-wrap:wrap;font-size:12px;height:auto;margin-top:6px;padding-right:22px;position:relative;width:100%;z-index:999}.bg-span{height:2px;width:14px}.bg-span,.bg-span-bar{display:inline-block;margin-right:6px}.bg-span-bar{border-radius:2px;height:10px;width:16px}.span-box{cursor:pointer;margin-left:5px;margin-right:6px}.noData,.span-box{align-items:center;display:flex}.noData{bottom:0;color:#ccc;font-size:16px;justify-content:center;position:absolute}._100,.noData{height:100%;width:100%}.dialog{padding:24px!important;width:860px!important}.factor-content{display:flex;flex-direction:column;flex-wrap:wrap;height:380px;width:100%}.factor_item{width:33.33%}.check_item,.factor_item{display:flex;margin-bottom:10px}.check_item{justify-content:space-between}.flex-alignCnter{align-items:center;cursor:pointer;display:flex}.target-head{display:grid;grid:auto/repeat(5,1fr)}.flow-col{border-left:1px solid #e8e8e8;height:520px;overflow-y:auto;padding-left:10px}.header-text-wrap{line-height:1.5;white-space:pre-line}.header-only-border .el-table,.header-only-border .el-table__inner-wrapper,.header-only-border.el-table--border{border:none!important}.header-only-border .el-table:after,.header-only-border .el-table:before,.header-only-border .el-table__inner-wrapper:after,.header-only-border .el-table__inner-wrapper:before{display:none!important}.header-only-border .el-table__cell{border:none!important}.header-only-border .el-table__header .el-table__cell{border:none!important;position:relative}.header-only-border .el-table__header .el-table__cell:after{background-color:#dcdfe6;content:"";height:40%;position:absolute;right:0;top:50%;transform:translateY(-50%);width:1px}.header-only-border .el-table__header .el-table__cell:last-child:after{display:none}
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
.echart-box {
|
|
2
|
+
width: 100%;
|
|
3
|
+
height: 100%;
|
|
4
|
+
display: flex;
|
|
5
|
+
flex-direction: column;
|
|
6
|
+
position: relative;
|
|
7
|
+
}
|
|
8
|
+
.echart-content {
|
|
9
|
+
flex: auto;
|
|
10
|
+
}
|
|
11
|
+
.echart-lenged {
|
|
12
|
+
width: 100%;
|
|
13
|
+
height: auto;
|
|
14
|
+
margin-top: 6px;
|
|
15
|
+
padding-right: 22px;
|
|
16
|
+
box-sizing: border-box;
|
|
17
|
+
display: flex;
|
|
18
|
+
flex-wrap: wrap;
|
|
19
|
+
font-size: 12px;
|
|
20
|
+
position: relative;
|
|
21
|
+
z-index: 999;
|
|
22
|
+
}
|
|
23
|
+
.bg-span {
|
|
24
|
+
display: inline-block;
|
|
25
|
+
width: 14px;
|
|
26
|
+
height: 2px;
|
|
27
|
+
margin-right: 6px;
|
|
28
|
+
}
|
|
29
|
+
.bg-span-bar {
|
|
30
|
+
display: inline-block;
|
|
31
|
+
width: 16px;
|
|
32
|
+
height: 10px;
|
|
33
|
+
border-radius: 2px;
|
|
34
|
+
margin-right: 6px;
|
|
35
|
+
}
|
|
36
|
+
.span-box {
|
|
37
|
+
margin-left: 5px;
|
|
38
|
+
margin-right: 6px;
|
|
39
|
+
cursor: pointer;
|
|
40
|
+
display: flex;
|
|
41
|
+
align-items: center;
|
|
42
|
+
}
|
|
43
|
+
.noData {
|
|
44
|
+
width: 100%;
|
|
45
|
+
height: 100%;
|
|
46
|
+
font-size: 16px;
|
|
47
|
+
display: flex;
|
|
48
|
+
justify-content: center;
|
|
49
|
+
align-items: center;
|
|
50
|
+
position: absolute;
|
|
51
|
+
bottom: 0px;
|
|
52
|
+
color: #ccc;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
._100 {
|
|
56
|
+
width: 100%;
|
|
57
|
+
height: 100%;
|
|
58
|
+
}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
// 表头文字换行样式
|
|
2
|
+
.header-text-wrap {
|
|
3
|
+
white-space: pre-line;
|
|
4
|
+
line-height: 1.5;
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
// 隐藏所有边框,让表格看起来和未设置 border 时一样
|
|
8
|
+
.header-only-border.el-table--border,
|
|
9
|
+
.header-only-border .el-table__inner-wrapper,
|
|
10
|
+
.header-only-border .el-table {
|
|
11
|
+
border: none !important;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
.header-only-border .el-table__inner-wrapper::before,
|
|
15
|
+
.header-only-border .el-table__inner-wrapper::after,
|
|
16
|
+
.header-only-border .el-table::before,
|
|
17
|
+
.header-only-border .el-table::after {
|
|
18
|
+
display: none !important;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.header-only-border .el-table__cell {
|
|
22
|
+
border: none !important;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
// 表头列分隔线 - 使用伪元素实现居中效果
|
|
26
|
+
.header-only-border .el-table__header .el-table__cell {
|
|
27
|
+
position: relative;
|
|
28
|
+
border: none !important;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
.header-only-border .el-table__header .el-table__cell::after {
|
|
32
|
+
content: '';
|
|
33
|
+
position: absolute;
|
|
34
|
+
right: 0;
|
|
35
|
+
top: 50%;
|
|
36
|
+
transform: translateY(-50%);
|
|
37
|
+
width: 1px;
|
|
38
|
+
height: 40%;
|
|
39
|
+
background-color: #dcdfe6;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
// 最后一列表头不显示分隔线
|
|
43
|
+
.header-only-border .el-table__header .el-table__cell:last-child::after {
|
|
44
|
+
display: none;
|
|
45
|
+
}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
.dialog {
|
|
2
|
+
width: 860px !important;
|
|
3
|
+
padding: 24px !important;
|
|
4
|
+
}
|
|
5
|
+
.factor-content {
|
|
6
|
+
width: 100%;
|
|
7
|
+
height: 380px;
|
|
8
|
+
display: flex;
|
|
9
|
+
flex-wrap: wrap;
|
|
10
|
+
flex-direction: column;
|
|
11
|
+
}
|
|
12
|
+
.factor_item {
|
|
13
|
+
width: 33.33%;
|
|
14
|
+
margin-bottom: 10px;
|
|
15
|
+
display: flex;
|
|
16
|
+
}
|
|
17
|
+
.check_item {
|
|
18
|
+
display: flex;
|
|
19
|
+
justify-content: space-between;
|
|
20
|
+
margin-bottom: 10px;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.flex-alignCnter {
|
|
24
|
+
display: flex;
|
|
25
|
+
align-items: center;
|
|
26
|
+
cursor: pointer;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
.target-head {
|
|
30
|
+
display: grid;
|
|
31
|
+
grid: auto / repeat(5, 1fr)
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.flow-col {
|
|
35
|
+
height: 520px;
|
|
36
|
+
overflow-y: auto;
|
|
37
|
+
border-left: 1px solid #e8e8e8;
|
|
38
|
+
padding-left: 10px;
|
|
39
|
+
}
|
package/component.ts
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
// import { HtTable } from '@hfn-components/components/table'
|
|
2
|
-
import { HtElTable } from '@hfn-components/components/elTable'
|
|
3
|
-
import { HtChart } from '@hfn-components/components/chart'
|
|
4
|
-
import { HtPieChart } from '@hfn-components/components/pieChart'
|
|
5
|
-
import { HtTarget } from '@hfn-components/components'
|
|
6
|
-
|
|
7
|
-
import type { Plugin } from 'vue'
|
|
8
|
-
|
|
9
|
-
export default [
|
|
10
|
-
// HtTable,
|
|
11
|
-
HtChart,
|
|
12
|
-
HtElTable,
|
|
13
|
-
HtPieChart,
|
|
14
|
-
HtTarget
|
|
15
|
-
] as Plugin[]
|
package/defaults.ts
DELETED
package/index.ts
DELETED
package/make-installer.ts
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import type { App, Plugin } from 'vue'
|
|
2
|
-
import { INSTALLED_KEY } from '@hfn-components/constants'
|
|
3
|
-
|
|
4
|
-
export const makeInstaller = (components: Plugin[] = []) => {
|
|
5
|
-
const install = (app: App) => {
|
|
6
|
-
if (app[INSTALLED_KEY]) return
|
|
7
|
-
|
|
8
|
-
app[INSTALLED_KEY] = true
|
|
9
|
-
components.forEach(c => app.use(c))
|
|
10
|
-
|
|
11
|
-
// if (options) provideGlobalConfig(options, app, true)
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
return {
|
|
15
|
-
install
|
|
16
|
-
}
|
|
17
|
-
}
|
package/plugin.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export default []
|