@aplus-frontend/ui 0.5.17 → 0.5.19

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.
Files changed (79) hide show
  1. package/es/src/ap-table/ap-table.vue2.mjs +30 -30
  2. package/es/src/ap-table/components/setting/sorter/index.vue2.mjs +1 -1
  3. package/es/src/ap-table/hooks/use-table-paging-ng.mjs +108 -107
  4. package/es/src/ap-table/interface.d.ts +8 -0
  5. package/es/src/business/ap-ladder/ApLadder.vue.d.ts +4 -20
  6. package/es/src/business/ap-ladder/ApLadder.vue2.mjs +64 -266
  7. package/es/src/business/ap-ladder/components/SimpleMode.vue.d.ts +110 -0
  8. package/es/src/business/ap-ladder/components/SimpleMode.vue.mjs +4 -0
  9. package/es/src/business/ap-ladder/components/SimpleMode.vue2.mjs +122 -0
  10. package/es/src/business/ap-ladder/components/ValueGroupMode.vue.d.ts +118 -0
  11. package/es/src/business/ap-ladder/components/ValueGroupMode.vue.mjs +4 -0
  12. package/es/src/business/ap-ladder/components/ValueGroupMode.vue2.mjs +209 -0
  13. package/es/src/business/ap-ladder/index.d.ts +5 -38
  14. package/es/src/business/ap-ladder/interface.d.ts +42 -16
  15. package/es/src/business/ap-ladder/useWatchEllipsis.d.ts +1 -2
  16. package/es/src/business/ap-ladder/useWatchEllipsis.origin.d.ts +3 -0
  17. package/es/src/business/ap-ladder/utils.d.ts +2 -0
  18. package/es/src/business/ap-ladder/utils.mjs +5 -0
  19. package/es/src/business/ap-table-modal/hooks/use-create-table-modal.mjs +1 -1
  20. package/es/src/business/ap-table-modal/interface.d.ts +1 -1
  21. package/es/src/business/ap-table-modal/modal-title.vue2.mjs +1 -1
  22. package/es/src/business/ap-table-modal/table-layout/index.vue2.mjs +8 -9
  23. package/es/src/business/ap-table-modal/table-modal.vue2.mjs +14 -14
  24. package/es/src/mask/style/css.d.ts +0 -0
  25. package/es/src/mask/style/css.js +1 -0
  26. package/es/src/mask/style/index.d.ts +0 -0
  27. package/es/src/mask/style/index.js +1 -0
  28. package/es/src/path-map.mjs +3 -1
  29. package/es/src/text/index.vue.mjs +46 -41
  30. package/es/src/text/interface.d.ts +6 -0
  31. package/es/src/text/style/css.d.ts +0 -0
  32. package/es/src/text/style/css.js +2 -0
  33. package/es/src/text/style/index.d.ts +0 -0
  34. package/es/src/text/style/index.js +2 -0
  35. package/lib/src/ap-table/ap-table.vue2.js +1 -1
  36. package/lib/src/ap-table/hooks/use-table-paging-ng.js +1 -1
  37. package/lib/src/ap-table/interface.d.ts +8 -0
  38. package/lib/src/business/ap-ladder/ApLadder.vue.d.ts +4 -20
  39. package/lib/src/business/ap-ladder/ApLadder.vue2.js +1 -1
  40. package/lib/src/business/ap-ladder/components/SimpleMode.vue.d.ts +110 -0
  41. package/lib/src/business/ap-ladder/components/SimpleMode.vue.js +1 -0
  42. package/lib/src/business/ap-ladder/components/SimpleMode.vue2.js +1 -0
  43. package/lib/src/business/ap-ladder/components/ValueGroupMode.vue.d.ts +118 -0
  44. package/lib/src/business/ap-ladder/components/ValueGroupMode.vue.js +1 -0
  45. package/lib/src/business/ap-ladder/components/ValueGroupMode.vue2.js +1 -0
  46. package/lib/src/business/ap-ladder/index.d.ts +5 -38
  47. package/lib/src/business/ap-ladder/interface.d.ts +42 -16
  48. package/lib/src/business/ap-ladder/useWatchEllipsis.d.ts +1 -2
  49. package/lib/src/business/ap-ladder/useWatchEllipsis.origin.d.ts +3 -0
  50. package/lib/src/business/ap-ladder/utils.d.ts +2 -0
  51. package/lib/src/business/ap-ladder/utils.js +1 -0
  52. package/lib/src/business/ap-table-modal/hooks/use-create-table-modal.js +1 -1
  53. package/lib/src/business/ap-table-modal/interface.d.ts +1 -1
  54. package/lib/src/business/ap-table-modal/modal-title.vue2.js +1 -1
  55. package/lib/src/business/ap-table-modal/table-layout/index.vue2.js +1 -1
  56. package/lib/src/business/ap-table-modal/table-modal.vue2.js +1 -1
  57. package/lib/src/mask/style/css.cjs +1 -0
  58. package/lib/src/mask/style/css.d.ts +0 -0
  59. package/lib/src/mask/style/index.cjs +1 -0
  60. package/lib/src/mask/style/index.d.ts +0 -0
  61. package/lib/src/path-map.js +1 -1
  62. package/lib/src/text/index.vue.js +1 -1
  63. package/lib/src/text/interface.d.ts +6 -0
  64. package/lib/src/text/style/css.cjs +2 -0
  65. package/lib/src/text/style/css.d.ts +0 -0
  66. package/lib/src/text/style/index.cjs +2 -0
  67. package/lib/src/text/style/index.d.ts +0 -0
  68. package/package.json +1 -1
  69. package/theme/ap-ladder/ap-ladder.css +68 -1
  70. package/theme/ap-ladder/ap-ladder.less +72 -2
  71. package/theme/index.css +68 -1
  72. package/es/src/business/ap-ladder/HelpMessageIcon.vue.d.ts +0 -14
  73. package/es/src/business/ap-ladder/HelpMessageIcon.vue.mjs +0 -4
  74. package/es/src/business/ap-ladder/HelpMessageIcon.vue2.mjs +0 -35
  75. package/es/src/business/ap-ladder/useWatchEllipsis.mjs +0 -35
  76. package/lib/src/business/ap-ladder/HelpMessageIcon.vue.d.ts +0 -14
  77. package/lib/src/business/ap-ladder/HelpMessageIcon.vue.js +0 -1
  78. package/lib/src/business/ap-ladder/HelpMessageIcon.vue2.js +0 -1
  79. package/lib/src/business/ap-ladder/useWatchEllipsis.js +0 -1
@@ -1,292 +1,90 @@
1
- import { defineComponent as Q, useSlots as U, ref as N, computed as h, unref as o, createElementBlock as r, openBlock as l, normalizeClass as a, createBlock as y, createCommentVNode as S, normalizeProps as E, mergeProps as C, createSlots as R, withCtx as c, Fragment as k, createElementVNode as m, normalizeStyle as p, toDisplayString as n, renderSlot as T, renderList as D, createTextVNode as X, isVNode as V, resolveDynamicComponent as b, createVNode as v } from "vue";
2
- import { Tooltip as j } from "@aplus-frontend/antdv";
1
+ import { defineComponent as C, useSlots as j, computed as e, createElementBlock as _, openBlock as i, normalizeClass as g, unref as o, createBlock as n, createCommentVNode as V, createSlots as p, withCtx as m, renderSlot as u } from "vue";
2
+ import { memoize as h } from "lodash-unified";
3
3
  import "../../config-provider/index.mjs";
4
- import { locales as Y } from "./interface.mjs";
5
- import "./HelpMessageIcon.vue.mjs";
6
- import { useWatchEllipsis as Z, ellipsisElementCls as A } from "./useWatchEllipsis.mjs";
7
- import { useNamespace as x } from "../../config-provider/hooks/use-namespace.mjs";
8
- import { useGlobalConfig as ee } from "../../config-provider/hooks/use-global-config.mjs";
9
- import M from "./HelpMessageIcon.vue2.mjs";
10
- const te = { key: 1 }, le = { key: 0 }, oe = { key: 1 }, re = { key: 0 }, ie = ["onClick"], ne = { key: 0 }, se = { key: 1 }, Se = /* @__PURE__ */ Q({
4
+ import "./components/SimpleMode.vue.mjs";
5
+ import "./components/ValueGroupMode.vue.mjs";
6
+ import { isNull as L, createMemoizeKey as A } from "./utils.mjs";
7
+ import { useNamespace as M } from "../../config-provider/hooks/use-namespace.mjs";
8
+ import { useGlobalConfig as $ } from "../../config-provider/hooks/use-global-config.mjs";
9
+ import B from "./components/SimpleMode.vue2.mjs";
10
+ import w from "./components/ValueGroupMode.vue2.mjs";
11
+ const J = /* @__PURE__ */ C({
11
12
  name: "ApLadder",
12
13
  __name: "ApLadder",
13
14
  props: {
14
- major: { default: "" },
15
- minor: { default: "" },
15
+ major: {},
16
+ minor: {},
16
17
  majorColor: { default: "" },
17
- majorStyles: { type: [Boolean, null, String, Object, Array], default: void 0 },
18
+ majorStyles: {},
18
19
  minorColor: { default: "" },
19
- minorStyles: { type: [Boolean, null, String, Object, Array], default: void 0 },
20
+ minorStyles: {},
20
21
  layout: { default: "vertical" },
21
22
  tooltip: { type: Boolean, default: !0 },
22
23
  labelValues: { default: () => [] },
23
- labelAlign: { default: "right" },
24
- labelStyles: { type: [Boolean, null, String, Object, Array], default: void 0 },
25
- valueStyles: { type: [Boolean, null, String, Object, Array], default: void 0 },
26
- linkStyles: { type: [Boolean, null, String, Object, Array], default: void 0 },
27
- unitStyles: { type: [Boolean, null, String, Object, Array], default: void 0 },
28
- tooltipProps: { default: () => ({
29
- title: void 0,
30
- align: {},
31
- arrowPointAtCenter: !1,
32
- arrow: !0,
33
- autoAdjustOverflow: !0,
34
- color: "",
35
- destroyTooltipOnHide: !1,
36
- getPopupContainer: () => document.body,
37
- mouseEnterDelay: 0.1,
38
- mouseLeaveDelay: 0.1,
39
- overlayClassName: "",
40
- overlayStyle: {},
41
- overlayInnerStyle: {},
42
- placement: "top",
43
- trigger: "hover"
44
- }) },
45
- tooltipLabelStyles: { type: [Boolean, null, String, Object, Array], default: void 0 },
46
- tooltipValueStyles: { type: [Boolean, null, String, Object, Array], default: void 0 }
24
+ labelAlign: { default: "left" },
25
+ labelStyles: {},
26
+ valueStyles: {},
27
+ linkStyles: {},
28
+ unitStyles: {},
29
+ tooltipProps: { default: () => ({}) },
30
+ tooltipLabelStyles: {},
31
+ tooltipValueStyles: {}
47
32
  },
48
- setup(F) {
49
- const P = U(), i = F, { b: z, e: s, m: G } = x("ap-ladder"), W = ee("uiMode", "aplus"), g = N([]), w = N(), H = Z(w);
50
- function I(t) {
51
- var f;
52
- const u = (f = g.value) == null ? void 0 : f[t];
53
- return u ? getComputedStyle(u).color : void 0;
54
- }
55
- const q = h(() => i.labelValues.length === 0), J = h(() => i.labelValues.length > 0), B = h(() => i.majorColor ? {
56
- color: `${i.majorColor}`
57
- } : {}), $ = h(() => i.minorColor ? {
58
- color: `${i.minorColor}`
59
- } : {}), _ = (t) => t == null || typeof t == "string" && t.trim() === "", d = (t, u = {}) => {
60
- const e = {
61
- rawValue: u.rawValue,
62
- precision: u.precision === void 0 ? 2 : u.precision,
63
- thousand: u.thousand,
64
- thousandSeparator: u.thousandSeparator || ",",
65
- currency: u.currency,
66
- percent: u.percent
67
- };
68
- if (t === null || typeof t == "object" || typeof t == "function" || typeof t > "u")
69
- return "--";
70
- if (typeof t == "boolean")
71
- return t;
72
- if (_(t))
73
- return "--";
74
- if (e.rawValue)
75
- return t;
76
- if (typeof t == "number") {
77
- if (e.percent)
78
- return `${t.toFixed(e.precision)}%`;
79
- if (e.currency)
80
- return t.toLocaleString(Y[e.currency], {
81
- style: "currency",
82
- currency: e.currency
83
- });
84
- if (e.thousand) {
85
- const [f, L] = t.toFixed(e.precision).split(".");
86
- return `${f.replace(
87
- /(\d)(?=(\d{3})+(?!\d))/g,
88
- `$1${e.thousandSeparator}`
89
- )}.${L}`;
90
- }
91
- return t.toFixed(e.precision);
92
- }
93
- return t;
94
- }, O = h(() => P.title ? !0 : i.tooltip && o(H)), K = (t) => {
33
+ setup(y) {
34
+ const s = j(), l = y, { b: c, m: f } = M("ap-ladder"), d = $("uiMode", "aplus"), v = e(
35
+ () => l.labelValues === void 0 || l.labelValues.length === 0
36
+ ), b = e(() => l.labelValues.length > 0), S = e(() => l.labelAlign), r = h((t) => L(t) ? "" : typeof t == "number" ? t.toString() : typeof t == "string" ? t : "", A), a = e(() => !!s.title || l.tooltip), k = (t) => {
95
37
  t.link && window.open(t.link, "_blank"), typeof t.handleClickLink == "function" && t.handleClickLink();
96
38
  };
97
- return (t, u) => (l(), r("div", {
98
- ref_key: "wrapperRef",
99
- ref: w,
100
- class: a([o(z)(), `${o(G)(o(W))}`])
39
+ return (t, N) => (i(), _("div", {
40
+ class: g([o(c)(), `${o(f)(o(d))}`])
101
41
  }, [
102
- q.value ? (l(), y(o(j), E(C({ key: 0 }, { ...i.tooltipProps })), R({
103
- default: c(() => [
104
- !_(t.major) || !_(t.minor) ? (l(), r(k, { key: 0 }, [
105
- i.layout === "vertical" ? (l(), r(k, { key: 0 }, [
106
- m("div", {
107
- class: a([o(s)("major"), o(s)("ellipsis"), o(A)]),
108
- style: p([t.majorStyles, B.value])
109
- }, n(d(t.major)), 7),
110
- m("div", {
111
- class: a([o(s)("minor"), o(s)("ellipsis"), o(A)]),
112
- style: p([t.minorStyles, $.value])
113
- }, n(d(t.minor)), 7)
114
- ], 64)) : (l(), r("div", {
115
- key: 1,
116
- class: a([o(s)("ellipsis"), o(A)])
117
- }, [
118
- m("span", {
119
- class: a([o(s)("major")]),
120
- style: p([t.majorStyles, B.value])
121
- }, n(d(t.major)), 7),
122
- m("span", {
123
- class: a([o(s)("minor")]),
124
- style: p([t.minorStyles, $.value])
125
- }, n(d(t.minor)), 7)
126
- ], 2))
127
- ], 64)) : (l(), r("div", te, n("--")))
128
- ]),
129
- _: 2
130
- }, [
131
- O.value ? {
42
+ v.value ? (i(), n(B, {
43
+ key: 0,
44
+ major: l.major,
45
+ minor: l.minor,
46
+ "major-styles": l.majorStyles || {},
47
+ "major-color": l.majorColor || {},
48
+ "minor-styles": l.minorStyles || {},
49
+ "minor-color": l.minorColor || {},
50
+ "tooltip-props": l.tooltipProps || {},
51
+ layout: l.layout,
52
+ tooltip: a.value,
53
+ "convert-value": o(r)
54
+ }, p({ _: 2 }, [
55
+ s.title ? {
132
56
  name: "title",
133
- fn: c(() => [
134
- P.title ? T(t.$slots, "title", { key: 0 }) : (l(), r(k, { key: 1 }, [
135
- i.tooltipProps.title ? (l(), r("div", le, n(i.tooltipProps.title), 1)) : (l(), r("div", oe, [
136
- m("div", null, n(d(t.major)), 1),
137
- m("div", null, n(d(t.minor)), 1)
138
- ]))
139
- ], 64))
57
+ fn: m(() => [
58
+ u(t.$slots, "title")
140
59
  ]),
141
60
  key: "0"
142
61
  } : void 0
143
- ]), 1040)) : S("", !0),
144
- J.value ? (l(), y(o(j), E(C({ key: 1 }, { ...i.tooltipProps })), R({
145
- default: c(() => [
146
- (l(!0), r(k, null, D(i.labelValues, (e, f) => (l(), r("div", {
147
- key: f,
148
- class: a([o(s)("cross-bar")])
149
- }, [
150
- m("div", {
151
- class: a([o(s)("ellipsis"), o(A)]),
152
- style: p({ color: I(f) })
153
- }, [
154
- m("span", {
155
- class: a(o(s)("label")),
156
- style: p([
157
- t.labelStyles,
158
- e.labelStyles,
159
- e.labelColor ? { color: e.labelColor } : void 0,
160
- { textAlign: e.labelAlign || t.labelAlign }
161
- ])
162
- }, [
163
- X(n(e.label), 1),
164
- e.label ? (l(), r("span", re, ":")) : S("", !0)
165
- ], 6),
166
- V(e.value) ? (l(), y(b(e.value), {
167
- key: 0,
168
- ref_for: !0,
169
- ref_key: "valueRefs",
170
- ref: g,
171
- style: { display: "inline-block" }
172
- }, null, 512)) : typeof e.value == "function" ? (l(), y(b(e.value()), {
173
- key: 1,
174
- ref_for: !0,
175
- ref_key: "valueRefs",
176
- ref: g,
177
- style: { display: "inline-block" }
178
- }, null, 512)) : (l(), r(k, { key: 2 }, [
179
- _(e.link) ? (l(), r("span", {
180
- key: 1,
181
- ref_for: !0,
182
- ref_key: "valueRefs",
183
- ref: g,
184
- class: a(o(s)("value")),
185
- style: p([
186
- t.valueStyles,
187
- e.valueStyles,
188
- e.valueColor ? { color: e.valueColor } : void 0
189
- ])
190
- }, n(d(e.value, { ...e })), 7)) : (l(), r("span", {
191
- key: 0,
192
- ref_for: !0,
193
- ref_key: "valueRefs",
194
- ref: g,
195
- class: a(o(s)("link")),
196
- style: p([
197
- t.linkStyles,
198
- e.linkStyles,
199
- e.linkColor ? { color: e.linkColor } : void 0
200
- ]),
201
- onClick: (L) => K(e)
202
- }, n(d(e.value, { ...e })), 15, ie))
203
- ], 64)),
204
- e.unit ? (l(), r("span", {
205
- key: 3,
206
- class: a(o(s)("unit")),
207
- style: p([
208
- t.unitStyles,
209
- e.unitStyles,
210
- e.unitColor ? { color: e.unitColor } : void 0
211
- ])
212
- }, n(e.unit), 7)) : S("", !0)
213
- ], 6),
214
- e.helpMessage ? (l(), r("div", {
215
- key: 0,
216
- class: a([o(s)("help-message")])
217
- }, [
218
- V(e.helpMessage) ? (l(), y(o(j), C({
219
- key: 0,
220
- ref_for: !0
221
- }, { ...e.helpMessageTooltipProps }), {
222
- title: c(() => [
223
- (l(), y(b(e.helpMessage)))
224
- ]),
225
- default: c(() => [
226
- v(M, { lv: e }, null, 8, ["lv"])
227
- ]),
228
- _: 2
229
- }, 1040)) : typeof e.helpMessage == "function" ? (l(), y(o(j), C({
230
- key: 1,
231
- ref_for: !0
232
- }, { ...e.helpMessageTooltipProps }), {
233
- title: c(() => [
234
- (l(), y(b(e.helpMessage())))
235
- ]),
236
- default: c(() => [
237
- v(M, { lv: e }, null, 8, ["lv"])
238
- ]),
239
- _: 2
240
- }, 1040)) : (l(), y(o(j), C({
241
- key: 2,
242
- ref_for: !0
243
- }, { ...e.helpMessageTooltipProps }, {
244
- placement: "bottom",
245
- title: e.helpMessage
246
- }), {
247
- default: c(() => [
248
- v(M, { lv: e }, null, 8, ["lv"])
249
- ]),
250
- _: 2
251
- }, 1040, ["title"]))
252
- ], 2)) : S("", !0)
253
- ], 2))), 128))
254
- ]),
255
- _: 2
256
- }, [
257
- O.value ? {
62
+ ]), 1032, ["major", "minor", "major-styles", "major-color", "minor-styles", "minor-color", "tooltip-props", "layout", "tooltip", "convert-value"])) : b.value ? (i(), n(w, {
63
+ key: 1,
64
+ "label-values": l.labelValues || {},
65
+ "label-align": S.value,
66
+ "label-styles": l.labelStyles || {},
67
+ "value-styles": l.valueStyles || {},
68
+ "link-styles": l.linkStyles || {},
69
+ "unit-styles": l.unitStyles || {},
70
+ "tooltip-label-styles": l.tooltipLabelStyles || {},
71
+ "tooltip-value-styles": l.tooltipValueStyles || {},
72
+ "tooltip-props": l.tooltipProps || {},
73
+ tooltip: a.value,
74
+ "convert-value": o(r),
75
+ onHandleClick: k
76
+ }, p({ _: 2 }, [
77
+ s.title ? {
258
78
  name: "title",
259
- fn: c(() => [
260
- P.title ? T(t.$slots, "title", { key: 0 }) : (l(), r(k, { key: 1 }, [
261
- i.tooltipProps.title ? (l(), r("div", ne, n(i.tooltipProps.title), 1)) : (l(), r("div", se, [
262
- (l(!0), r(k, null, D(i.labelValues, (e, f) => (l(), r("div", {
263
- key: f,
264
- style: { "word-break": "break-all" }
265
- }, [
266
- e.label ? (l(), r("span", {
267
- key: 0,
268
- style: p([t.tooltipLabelStyles, e.tooltipLabelStyles])
269
- }, n(e.label) + ":", 5)) : S("", !0),
270
- V(e.value) ? (l(), y(b(e.value), {
271
- key: 1,
272
- style: { display: "inline-block" }
273
- })) : typeof e.value == "function" ? (l(), y(b(e.value()), {
274
- key: 2,
275
- style: { display: "inline-block" }
276
- })) : (l(), r("span", {
277
- key: 3,
278
- style: p([t.tooltipValueStyles, e.tooltipValueStyles])
279
- }, n(d(e.value, { ...e })), 5))
280
- ]))), 128))
281
- ]))
282
- ], 64))
79
+ fn: m(() => [
80
+ u(t.$slots, "title")
283
81
  ]),
284
82
  key: "0"
285
83
  } : void 0
286
- ]), 1040)) : S("", !0)
84
+ ]), 1032, ["label-values", "label-align", "label-styles", "value-styles", "link-styles", "unit-styles", "tooltip-label-styles", "tooltip-value-styles", "tooltip-props", "tooltip", "convert-value"])) : V("", !0)
287
85
  ], 2));
288
86
  }
289
87
  });
290
88
  export {
291
- Se as default
89
+ J as default
292
90
  };
@@ -0,0 +1,110 @@
1
+ import { CSSProperties, PropType, DefineComponent, ExtractPropTypes, ComponentOptionsMixin, PublicProps, ComponentProvideOptions } from 'vue';
2
+ declare function __VLS_template(): {
3
+ attrs: Partial<{}>;
4
+ slots: {
5
+ title?(_: {}): any;
6
+ };
7
+ refs: {};
8
+ rootEl: any;
9
+ };
10
+ type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
11
+ declare const __VLS_component: DefineComponent<ExtractPropTypes<{
12
+ major: {
13
+ type: (NumberConstructor | ObjectConstructor | StringConstructor | FunctionConstructor)[];
14
+ default: null;
15
+ };
16
+ minor: {
17
+ type: (NumberConstructor | ObjectConstructor | StringConstructor | FunctionConstructor)[];
18
+ default: null;
19
+ };
20
+ majorStyles: {
21
+ type: PropType<CSSProperties>;
22
+ default: () => {};
23
+ };
24
+ majorColorStyles: {
25
+ type: PropType<CSSProperties>;
26
+ default: () => {};
27
+ };
28
+ minorStyles: {
29
+ type: PropType<CSSProperties>;
30
+ default: () => {};
31
+ };
32
+ minorColorStyles: {
33
+ type: PropType<CSSProperties>;
34
+ default: () => {};
35
+ };
36
+ tooltipProps: {
37
+ type: ObjectConstructor;
38
+ default: () => {};
39
+ };
40
+ layout: {
41
+ type: StringConstructor;
42
+ default: string;
43
+ };
44
+ tooltip: {
45
+ type: BooleanConstructor;
46
+ default: boolean;
47
+ };
48
+ convertValue: {
49
+ type: FunctionConstructor;
50
+ required: true;
51
+ };
52
+ }>, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly< ExtractPropTypes<{
53
+ major: {
54
+ type: (NumberConstructor | ObjectConstructor | StringConstructor | FunctionConstructor)[];
55
+ default: null;
56
+ };
57
+ minor: {
58
+ type: (NumberConstructor | ObjectConstructor | StringConstructor | FunctionConstructor)[];
59
+ default: null;
60
+ };
61
+ majorStyles: {
62
+ type: PropType<CSSProperties>;
63
+ default: () => {};
64
+ };
65
+ majorColorStyles: {
66
+ type: PropType<CSSProperties>;
67
+ default: () => {};
68
+ };
69
+ minorStyles: {
70
+ type: PropType<CSSProperties>;
71
+ default: () => {};
72
+ };
73
+ minorColorStyles: {
74
+ type: PropType<CSSProperties>;
75
+ default: () => {};
76
+ };
77
+ tooltipProps: {
78
+ type: ObjectConstructor;
79
+ default: () => {};
80
+ };
81
+ layout: {
82
+ type: StringConstructor;
83
+ default: string;
84
+ };
85
+ tooltip: {
86
+ type: BooleanConstructor;
87
+ default: boolean;
88
+ };
89
+ convertValue: {
90
+ type: FunctionConstructor;
91
+ required: true;
92
+ };
93
+ }>> & Readonly<{}>, {
94
+ layout: string;
95
+ tooltip: boolean;
96
+ major: string | number | Function | Record<string, any>;
97
+ minor: string | number | Function | Record<string, any>;
98
+ tooltipProps: Record<string, any>;
99
+ majorStyles: CSSProperties;
100
+ majorColorStyles: CSSProperties;
101
+ minorStyles: CSSProperties;
102
+ minorColorStyles: CSSProperties;
103
+ }, {}, {}, {}, string, ComponentProvideOptions, true, {}, any>;
104
+ declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
105
+ export default _default;
106
+ type __VLS_WithTemplateSlots<T, S> = T & {
107
+ new (): {
108
+ $slots: S;
109
+ };
110
+ };
@@ -0,0 +1,4 @@
1
+ import f from "./SimpleMode.vue2.mjs";
2
+ export {
3
+ f as default
4
+ };
@@ -0,0 +1,122 @@
1
+ import { defineComponent as j, createBlock as S, openBlock as n, unref as t, normalizeProps as v, guardReactiveProps as b, createSlots as k, withCtx as s, createElementBlock as i, createCommentVNode as u, Fragment as C, normalizeClass as l, createElementVNode as a, normalizeStyle as m, toDisplayString as r, renderSlot as V } from "vue";
2
+ import { Tooltip as O } from "@aplus-frontend/antdv";
3
+ import "../../../config-provider/index.mjs";
4
+ import { isNull as c } from "../utils.mjs";
5
+ import { useNamespace as g } from "../../../config-provider/hooks/use-namespace.mjs";
6
+ const E = /* @__PURE__ */ j({
7
+ name: "ApLadderSimpleMode",
8
+ __name: "SimpleMode",
9
+ props: {
10
+ major: {
11
+ type: [String, Number, Function, Object],
12
+ default: null
13
+ },
14
+ minor: {
15
+ type: [String, Number, Function, Object],
16
+ default: null
17
+ },
18
+ majorStyles: {
19
+ type: Object,
20
+ default: () => ({})
21
+ },
22
+ majorColorStyles: {
23
+ type: Object,
24
+ default: () => ({})
25
+ },
26
+ minorStyles: {
27
+ type: Object,
28
+ default: () => ({})
29
+ },
30
+ minorColorStyles: {
31
+ type: Object,
32
+ default: () => ({})
33
+ },
34
+ tooltipProps: {
35
+ type: Object,
36
+ default: () => ({})
37
+ },
38
+ layout: {
39
+ type: String,
40
+ default: "vertical"
41
+ },
42
+ tooltip: {
43
+ type: Boolean,
44
+ default: !1
45
+ },
46
+ convertValue: {
47
+ type: Function,
48
+ required: !0
49
+ }
50
+ },
51
+ setup(e) {
52
+ const { b: y, e: o, m: d } = g("ap-ladder");
53
+ return (f, N) => (n(), S(t(O), v(b(e.tooltipProps)), k({
54
+ default: s(() => [
55
+ !t(c)(e.major) || !t(c)(e.minor) ? (n(), i(C, { key: 0 }, [
56
+ e.layout === "vertical" ? (n(), i("div", {
57
+ key: 0,
58
+ class: l([t(y)("base"), t(d)("vertical")])
59
+ }, [
60
+ a("span", {
61
+ class: l([t(o)("major")]),
62
+ style: m([e.majorStyles, e.majorColorStyles])
63
+ }, r(e.convertValue(e.major)), 7),
64
+ a("span", {
65
+ class: l([t(o)("minor")]),
66
+ style: m([e.minorStyles, e.minorColorStyles])
67
+ }, r(e.convertValue(e.minor)), 7)
68
+ ], 2)) : (n(), i("div", {
69
+ key: 1,
70
+ class: l([t(y)("base"), t(d)("horizontal")])
71
+ }, [
72
+ a("span", {
73
+ class: l([t(o)("major")]),
74
+ style: m([e.majorStyles, e.majorColorStyles])
75
+ }, r(e.convertValue(e.major)), 7),
76
+ a("span", {
77
+ class: l([t(o)("minor")]),
78
+ style: m([e.minorStyles, e.minorColorStyles])
79
+ }, r(e.convertValue(e.minor)), 7)
80
+ ], 2))
81
+ ], 64)) : u("", !0)
82
+ ]),
83
+ _: 2
84
+ }, [
85
+ f.$slots.title ? {
86
+ name: "title",
87
+ fn: s(() => [
88
+ V(f.$slots, "title")
89
+ ]),
90
+ key: "0"
91
+ } : e.tooltip ? {
92
+ name: "title",
93
+ fn: s(() => [
94
+ a("div", {
95
+ class: l(t(o)("tooltip"))
96
+ }, [
97
+ t(c)(e.major) ? u("", !0) : (n(), i("div", {
98
+ key: 0,
99
+ class: l(t(o)("tooltip-item"))
100
+ }, [
101
+ a("span", {
102
+ class: l(t(o)("tooltip-label"))
103
+ }, r(e.convertValue(e.major)), 3)
104
+ ], 2)),
105
+ t(c)(e.minor) ? u("", !0) : (n(), i("div", {
106
+ key: 1,
107
+ class: l(t(o)("tooltip-item"))
108
+ }, [
109
+ a("span", {
110
+ class: l(t(o)("tooltip-label"))
111
+ }, r(e.convertValue(e.minor)), 3)
112
+ ], 2))
113
+ ], 2)
114
+ ]),
115
+ key: "1"
116
+ } : void 0
117
+ ]), 1040));
118
+ }
119
+ });
120
+ export {
121
+ E as default
122
+ };