@shtabapp/ui-kit 1.52.0 → 1.53.0
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/CHANGELOG.md +10 -0
- package/dist/{SCard-BkmIQd2s.js → SCard-BPYqNqDs.js} +1 -1
- package/dist/{SCard-BzIQoACi.cjs → SCard-BZ2TUqpd.cjs} +1 -1
- package/dist/SCheckbox-BAPXAjnl.cjs +1 -0
- package/dist/SCheckbox-CU6nzXrI.js +103 -0
- package/dist/{SRadio-BZKPhGwO.js → SRadio-C1CfSeb_.js} +2 -2
- package/dist/SRadio-xfAIUC2I.cjs +1 -0
- package/dist/{SToggle-BgCgar2U.js → SToggle-CSz9gHYO.js} +3 -3
- package/dist/SToggle-CXl6RWi1.cjs +1 -0
- package/dist/components/SCheckbox/SCheckbox.types.d.ts +6 -0
- package/dist/components/SCheckbox/SCheckbox.types.d.ts.map +1 -1
- package/dist/components/SCheckbox/SCheckbox.vue.d.ts +11 -1
- package/dist/components/SCheckbox/SCheckbox.vue.d.ts.map +1 -1
- package/dist/components/SCheckbox/index.d.ts +1 -1
- package/dist/components/SCheckbox/index.d.ts.map +1 -1
- package/dist/entries/card.cjs +1 -1
- package/dist/entries/card.js +1 -1
- package/dist/entries/checkbox.cjs +1 -1
- package/dist/entries/checkbox.d.ts +1 -1
- package/dist/entries/checkbox.d.ts.map +1 -1
- package/dist/entries/checkbox.js +2 -2
- package/dist/entries/radio.cjs +1 -1
- package/dist/entries/radio.js +1 -1
- package/dist/entries/toggle.cjs +1 -1
- package/dist/entries/toggle.d.ts +1 -1
- package/dist/entries/toggle.d.ts.map +1 -1
- package/dist/entries/toggle.js +2 -2
- package/dist/index.cjs +1 -1
- package/dist/index.d.ts +2 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +244 -244
- package/dist/uikit-components.css +1 -1
- package/package.json +1 -1
- package/dist/SCheckbox-BXV4bPOv.js +0 -76
- package/dist/SCheckbox-D_YLWg6a.cjs +0 -1
- package/dist/SRadio-CcmuHaKk.cjs +0 -1
- package/dist/SToggle-B5EdI-rG.cjs +0 -1
package/dist/index.js
CHANGED
|
@@ -9,47 +9,47 @@ import { t as w } from "./SButton-DnU_XZ1C.js";
|
|
|
9
9
|
import { a as re, n as ie, o as ae, r as oe, t as se } from "./useSelectionGroup-cKj38lEN.js";
|
|
10
10
|
import { n as ce } from "./useSelectLink-DClG5hGA.js";
|
|
11
11
|
import { n as le, t as ue } from "./SButtonGroup-CmSlYnSv.js";
|
|
12
|
-
import {
|
|
13
|
-
import { n as
|
|
14
|
-
import { t as
|
|
15
|
-
import { n as
|
|
16
|
-
import { t as
|
|
17
|
-
import { i as
|
|
18
|
-
import { n as
|
|
19
|
-
import { t as
|
|
20
|
-
import { n as
|
|
21
|
-
import { t as
|
|
22
|
-
import { n as
|
|
23
|
-
import { n as
|
|
24
|
-
import { n as
|
|
25
|
-
import { n as
|
|
26
|
-
import { a as
|
|
27
|
-
import { n as
|
|
28
|
-
import { n as
|
|
29
|
-
import { n as
|
|
30
|
-
import { n as
|
|
31
|
-
import { t as
|
|
32
|
-
import { n as
|
|
33
|
-
import { a as
|
|
34
|
-
import { t as
|
|
35
|
-
import { t as
|
|
36
|
-
import { t as
|
|
37
|
-
import { t as
|
|
38
|
-
import { t as
|
|
39
|
-
import { t as
|
|
40
|
-
import { t as
|
|
41
|
-
import { t as
|
|
42
|
-
import { t as
|
|
43
|
-
import { t as
|
|
44
|
-
import { t as
|
|
45
|
-
import { a as
|
|
46
|
-
import { Fragment as
|
|
47
|
-
import { ESIconName as
|
|
48
|
-
import { useResizeObserver as
|
|
12
|
+
import { i as de, n as fe, r as pe, t as me } from "./SCheckbox-CU6nzXrI.js";
|
|
13
|
+
import { n as he, t as ge } from "./SCard-BPYqNqDs.js";
|
|
14
|
+
import { t as _e } from "./SSegmentControl-CmJEjfSR.js";
|
|
15
|
+
import { n as ve, r as ye, t as be } from "./STab-DY1TGadw.js";
|
|
16
|
+
import { t as xe } from "./STabs-CTM8Nji_.js";
|
|
17
|
+
import { i as Se, n as Ce, r as we, t as Te } from "./useFloatingOverlay-QcumEYEq.js";
|
|
18
|
+
import { n as Ee, r as De, t as Oe } from "./STag-CluIVRKi.js";
|
|
19
|
+
import { t as ke } from "./STagGroup-GzZhto7-.js";
|
|
20
|
+
import { n as Ae, r as je, t as Me } from "./SChip-DvPazz7Y.js";
|
|
21
|
+
import { t as Ne } from "./SDropdown-CTQ5Qlez.js";
|
|
22
|
+
import { n as Pe, r as Fe, t as Ie } from "./SSelect-Bf1lDJ0M.js";
|
|
23
|
+
import { n as Le, t as Re } from "./SInput-ug89CYt3.js";
|
|
24
|
+
import { n as ze, t as Be } from "./SInlineMessage-Dirk5RwO.js";
|
|
25
|
+
import { n as Ve, r as He, t as Ue } from "./SLabel-yzcX4qp5.js";
|
|
26
|
+
import { a as We, o as Ge, s as Ke, t as qe } from "./SList-BESqVnlh.js";
|
|
27
|
+
import { n as Je, t as Ye } from "./SListItem-DJ8uSadf.js";
|
|
28
|
+
import { n as Xe, t as Ze } from "./SRadio-C1CfSeb_.js";
|
|
29
|
+
import { n as Qe, r as $e, t as et } from "./SToggle-CSz9gHYO.js";
|
|
30
|
+
import { n as tt, t as nt } from "./SInlineInput-DHq5BNPn.js";
|
|
31
|
+
import { t as rt } from "./STextarea-ASdLqfpC.js";
|
|
32
|
+
import { n as it, r as at, t as ot } from "./SPhotoEdit-BJXa6mh4.js";
|
|
33
|
+
import { a as st, i as ct, n as lt, r as ut, t as dt, v as T, w as E } from "./SChartSkeletonHost-BT96eWSF.js";
|
|
34
|
+
import { t as ft } from "./SChartLine-DSQaezYq.js";
|
|
35
|
+
import { t as pt } from "./resolveSeriesPaletteColor-BdvGT-PI.js";
|
|
36
|
+
import { t as mt } from "./SChartStackedArea-BxUex_Di.js";
|
|
37
|
+
import { t as ht } from "./SChartStackedBar-BJ9LOgSP.js";
|
|
38
|
+
import { t as gt } from "./SChartHorizontalBar-XNasKzaO.js";
|
|
39
|
+
import { t as _t } from "./SChartPie-bN8rY-y5.js";
|
|
40
|
+
import { t as vt } from "./SChartMultiLine-CrMmphFe.js";
|
|
41
|
+
import { t as yt } from "./SChartBurnup-Dxi0MBwo.js";
|
|
42
|
+
import { t as bt } from "./SChartProgress-BtwqE4xL.js";
|
|
43
|
+
import { t as xt } from "./SChartLegend-oZoF8XK7.js";
|
|
44
|
+
import { t as St } from "./useHasListener-RSjlUyqH.js";
|
|
45
|
+
import { a as Ct, c as wt, i as Tt, l as Et, n as Dt, o as Ot, r as kt, s as At, t as jt, u as Mt } from "./buildWorkTimeLegendItems-ChGHTwbn.js";
|
|
46
|
+
import { Fragment as Nt, Teleport as Pt, computed as D, createBlock as O, createCommentVNode as k, createElementBlock as A, createElementVNode as j, createSlots as Ft, createTextVNode as M, createVNode as It, defineComponent as N, mergeModels as Lt, mergeProps as Rt, normalizeClass as P, normalizeStyle as F, onMounted as zt, openBlock as I, ref as L, renderList as Bt, renderSlot as R, resolveDynamicComponent as Vt, shallowRef as z, toDisplayString as B, unref as V, useModel as Ht, useSlots as H, useTemplateRef as Ut, watch as Wt, withCtx as U } from "vue";
|
|
47
|
+
import { ESIconName as W, SIcon as Gt, createUiKit as Kt, setUiKitLocale as qt, uiKitLocaleEn as Jt, uiKitLocaleRu as Yt, useUiKitI18n as Xt, useUiKitI18n as Zt } from "@shtabapp/ui-kit-primitives";
|
|
48
|
+
import { useResizeObserver as Qt } from "@vueuse/core";
|
|
49
49
|
export * from "@shtabapp/ui-kit-primitives";
|
|
50
50
|
export * from "@shtabapp/ui-kit-tokens";
|
|
51
51
|
//#region src/utils/chart/segmentedBar/resolveSegmentedBarSegmentColor.ts
|
|
52
|
-
var
|
|
52
|
+
var G = [
|
|
53
53
|
"--s-ui-chart-segmented-bar-palette-1",
|
|
54
54
|
"--s-ui-chart-segmented-bar-palette-2",
|
|
55
55
|
"--s-ui-chart-segmented-bar-palette-3",
|
|
@@ -58,7 +58,7 @@ var Xt = [
|
|
|
58
58
|
"--s-ui-chart-segmented-bar-palette-6",
|
|
59
59
|
"--s-ui-chart-segmented-bar-palette-7",
|
|
60
60
|
"--s-ui-chart-segmented-bar-palette-8"
|
|
61
|
-
],
|
|
61
|
+
], K = [
|
|
62
62
|
"--s-ui-chart-segmented-bar-skeleton-palette-1",
|
|
63
63
|
"--s-ui-chart-segmented-bar-skeleton-palette-2",
|
|
64
64
|
"--s-ui-chart-segmented-bar-skeleton-palette-3",
|
|
@@ -67,51 +67,51 @@ var Xt = [
|
|
|
67
67
|
"--s-ui-chart-segmented-bar-skeleton-palette-6",
|
|
68
68
|
"--s-ui-chart-segmented-bar-skeleton-palette-7",
|
|
69
69
|
"--s-ui-chart-segmented-bar-skeleton-palette-8"
|
|
70
|
-
],
|
|
71
|
-
palette:
|
|
72
|
-
paletteFallback:
|
|
73
|
-
skeletonPalette:
|
|
74
|
-
skeletonFallback:
|
|
75
|
-
}),
|
|
70
|
+
], $t = (e, t, n, r = !1) => pt(e, t, n, r, {
|
|
71
|
+
palette: G,
|
|
72
|
+
paletteFallback: G[0],
|
|
73
|
+
skeletonPalette: K,
|
|
74
|
+
skeletonFallback: K[0]
|
|
75
|
+
}), q = /* @__PURE__ */ function(e) {
|
|
76
76
|
return e.INFO_ACCENT = "info-accent", e.INFO_NORMAL = "info-normal", e.SUCCESS = "success", e.WARNING = "warning", e.DANGER = "danger", e.BILLING = "billing", e;
|
|
77
|
-
}({}), q = /* @__PURE__ */ function(e) {
|
|
78
|
-
return e.HORIZONTAL = "horizontal", e.VERTICAL = "vertical", e;
|
|
79
77
|
}({}), J = /* @__PURE__ */ function(e) {
|
|
80
|
-
return e.
|
|
78
|
+
return e.HORIZONTAL = "horizontal", e.VERTICAL = "vertical", e;
|
|
81
79
|
}({}), Y = /* @__PURE__ */ function(e) {
|
|
80
|
+
return e.ICON = "icon", e.AVATAR = "avatar", e;
|
|
81
|
+
}({}), X = /* @__PURE__ */ function(e) {
|
|
82
82
|
return e.BANNER = "banner", e.TOAST = "toast", e;
|
|
83
|
-
}({}),
|
|
84
|
-
[
|
|
85
|
-
[
|
|
86
|
-
[
|
|
87
|
-
[
|
|
88
|
-
[
|
|
89
|
-
[
|
|
90
|
-
},
|
|
83
|
+
}({}), en = {
|
|
84
|
+
[q.INFO_ACCENT]: W.infoCircle,
|
|
85
|
+
[q.INFO_NORMAL]: W.infoCircle,
|
|
86
|
+
[q.SUCCESS]: W.checkCircle,
|
|
87
|
+
[q.WARNING]: W.alertCircle,
|
|
88
|
+
[q.DANGER]: W.dangerCircleFill,
|
|
89
|
+
[q.BILLING]: W.infoCircle
|
|
90
|
+
}, tn = (e, t) => t || en[e], nn = ["role"], rn = { class: "s-ui-notification__body" }, an = {
|
|
91
91
|
key: 0,
|
|
92
92
|
class: "s-ui-notification__leftside"
|
|
93
|
-
},
|
|
93
|
+
}, on = {
|
|
94
94
|
key: 0,
|
|
95
95
|
class: "s-ui-notification__icon"
|
|
96
|
-
},
|
|
96
|
+
}, sn = { class: "s-ui-notification__content" }, cn = { class: "s-ui-notification__title-row" }, ln = { class: "s-ui-notification__title s-ui-typography-label-14-medium" }, un = {
|
|
97
97
|
key: 0,
|
|
98
98
|
class: "s-ui-notification__description-block"
|
|
99
|
-
},
|
|
99
|
+
}, dn = {
|
|
100
100
|
key: 0,
|
|
101
101
|
class: "s-ui-notification__description s-ui-typography-label-12-medium"
|
|
102
|
-
},
|
|
102
|
+
}, fn = {
|
|
103
103
|
key: 1,
|
|
104
104
|
class: "s-ui-notification__actions-stack"
|
|
105
|
-
},
|
|
105
|
+
}, pn = {
|
|
106
106
|
key: 1,
|
|
107
107
|
class: "s-ui-notification__actions-row"
|
|
108
|
-
},
|
|
108
|
+
}, mn = /* @__PURE__ */ N({
|
|
109
109
|
__name: "SNotification",
|
|
110
110
|
props: {
|
|
111
|
-
type: { default: () =>
|
|
112
|
-
layout: { default: () =>
|
|
113
|
-
leftside: { default: () =>
|
|
114
|
-
surface: { default: () =>
|
|
111
|
+
type: { default: () => q.INFO_ACCENT },
|
|
112
|
+
layout: { default: () => J.HORIZONTAL },
|
|
113
|
+
leftside: { default: () => Y.ICON },
|
|
114
|
+
surface: { default: () => X.BANNER },
|
|
115
115
|
title: {},
|
|
116
116
|
description: {},
|
|
117
117
|
linkText: {},
|
|
@@ -138,14 +138,14 @@ var Xt = [
|
|
|
138
138
|
"secondaryAction"
|
|
139
139
|
],
|
|
140
140
|
setup(e, { emit: t }) {
|
|
141
|
-
let n = t, r =
|
|
141
|
+
let n = t, r = H(), i = D(() => [
|
|
142
142
|
`s-ui-notification--type-${e.type}`,
|
|
143
143
|
`s-ui-notification--layout-${e.layout}`,
|
|
144
144
|
`s-ui-notification--surface-${e.surface}`
|
|
145
|
-
]), a =
|
|
145
|
+
]), a = D(() => {
|
|
146
146
|
let t = {};
|
|
147
147
|
return e.width && (t.width = typeof e.width == "number" ? `${e.width}px` : e.width), e.maxWidth && (t.maxWidth = typeof e.maxWidth == "number" ? `${e.maxWidth}px` : e.maxWidth), t;
|
|
148
|
-
}), s =
|
|
148
|
+
}), s = D(() => e.type === q.DANGER ? "alert" : "status"), l = D(() => tn(e.type, e.icon)), u = D(() => e.type === q.BILLING), d = D(() => !!(e.leftside === Y.AVATAR && e.avatar || e.leftside === Y.ICON)), f = D(() => !!(e.description || e.linkText || r.description)), p = D(() => e.showPrimaryButton && (e.primaryButtonText || e.secondaryButtonText)), m = D(() => e.showPrimaryButton && e.primaryButtonText || e.closable), h = D(() => e.type === q.BILLING ? C.MAJOR : C.OUTLINED), g = D(() => e.type === q.BILLING ? S.BILLING : S.MAIN), _ = () => {
|
|
149
149
|
n("close");
|
|
150
150
|
}, v = () => {
|
|
151
151
|
n("linkClick");
|
|
@@ -154,35 +154,35 @@ var Xt = [
|
|
|
154
154
|
}, b = () => {
|
|
155
155
|
n("secondaryAction");
|
|
156
156
|
};
|
|
157
|
-
return (t, n) => (
|
|
158
|
-
class:
|
|
159
|
-
style:
|
|
157
|
+
return (t, n) => (I(), A("div", {
|
|
158
|
+
class: P(["s-ui-notification", i.value]),
|
|
159
|
+
style: F(a.value),
|
|
160
160
|
role: s.value
|
|
161
|
-
}, [
|
|
162
|
-
d.value ? (
|
|
161
|
+
}, [j("div", rn, [
|
|
162
|
+
d.value ? (I(), A("div", an, [e.leftside === V(Y).ICON ? (I(), A("div", on, [It(V(Gt), {
|
|
163
163
|
name: l.value,
|
|
164
164
|
size: 16,
|
|
165
165
|
billing: u.value
|
|
166
|
-
}, null, 8, ["name", "billing"])])) : e.leftside ===
|
|
166
|
+
}, null, 8, ["name", "billing"])])) : e.leftside === V(Y).AVATAR && e.avatar ? (I(), O(V(c), {
|
|
167
167
|
key: 1,
|
|
168
168
|
name: e.avatar.name,
|
|
169
169
|
src: e.avatar.src,
|
|
170
170
|
badge: e.avatar.badge,
|
|
171
|
-
size:
|
|
171
|
+
size: V(o).SIZE_20,
|
|
172
172
|
showName: !1
|
|
173
173
|
}, null, 8, [
|
|
174
174
|
"name",
|
|
175
175
|
"src",
|
|
176
176
|
"badge",
|
|
177
177
|
"size"
|
|
178
|
-
])) :
|
|
179
|
-
|
|
180
|
-
|
|
178
|
+
])) : k("", !0)])) : k("", !0),
|
|
179
|
+
j("div", sn, [
|
|
180
|
+
j("div", cn, [j("span", ln, [R(t.$slots, "title", {}, () => [M(B(e.title), 1)])]), e.layout === V(J).VERTICAL && e.closable ? (I(), O(V(w), {
|
|
181
181
|
key: 0,
|
|
182
182
|
class: "s-ui-notification__close",
|
|
183
|
-
appearance:
|
|
184
|
-
variant:
|
|
185
|
-
size:
|
|
183
|
+
appearance: V(C).BARE,
|
|
184
|
+
variant: V(S).NEUTRAL,
|
|
185
|
+
size: V(x).SMALL,
|
|
186
186
|
"aria-label": e.closeAriaLabel,
|
|
187
187
|
icon: "closeMini",
|
|
188
188
|
onClick: _
|
|
@@ -191,69 +191,69 @@ var Xt = [
|
|
|
191
191
|
"variant",
|
|
192
192
|
"size",
|
|
193
193
|
"aria-label"
|
|
194
|
-
])) :
|
|
195
|
-
f.value ? (
|
|
194
|
+
])) : k("", !0)]),
|
|
195
|
+
f.value ? (I(), A("div", un, [e.description || V(r).description ? (I(), A("span", dn, [R(t.$slots, "description", {}, () => [M(B(e.description), 1)])])) : k("", !0), e.linkText ? (I(), O(V(w), {
|
|
196
196
|
key: 1,
|
|
197
197
|
class: "s-ui-notification__link",
|
|
198
|
-
appearance:
|
|
199
|
-
variant:
|
|
200
|
-
size:
|
|
198
|
+
appearance: V(C).BARE,
|
|
199
|
+
variant: V(S).MAIN,
|
|
200
|
+
size: V(x).SMALL,
|
|
201
201
|
onClick: v
|
|
202
202
|
}, {
|
|
203
|
-
default:
|
|
203
|
+
default: U(() => [M(B(e.linkText), 1)]),
|
|
204
204
|
_: 1
|
|
205
205
|
}, 8, [
|
|
206
206
|
"appearance",
|
|
207
207
|
"variant",
|
|
208
208
|
"size"
|
|
209
|
-
])) :
|
|
210
|
-
e.layout ===
|
|
209
|
+
])) : k("", !0)])) : k("", !0),
|
|
210
|
+
e.layout === V(J).VERTICAL && p.value ? (I(), A("div", fn, [e.showPrimaryButton && e.primaryButtonText ? (I(), O(V(w), {
|
|
211
211
|
key: 0,
|
|
212
212
|
appearance: h.value,
|
|
213
213
|
variant: g.value,
|
|
214
|
-
size:
|
|
214
|
+
size: V(x).SMALL,
|
|
215
215
|
onClick: y
|
|
216
216
|
}, {
|
|
217
|
-
default:
|
|
217
|
+
default: U(() => [M(B(e.primaryButtonText), 1)]),
|
|
218
218
|
_: 1
|
|
219
219
|
}, 8, [
|
|
220
220
|
"appearance",
|
|
221
221
|
"variant",
|
|
222
222
|
"size"
|
|
223
|
-
])) :
|
|
223
|
+
])) : k("", !0), e.showPrimaryButton && e.secondaryButtonText ? (I(), O(V(w), {
|
|
224
224
|
key: 1,
|
|
225
|
-
appearance:
|
|
226
|
-
variant:
|
|
227
|
-
size:
|
|
225
|
+
appearance: V(C).BARE,
|
|
226
|
+
variant: V(S).NEUTRAL,
|
|
227
|
+
size: V(x).SMALL,
|
|
228
228
|
onClick: b
|
|
229
229
|
}, {
|
|
230
|
-
default:
|
|
230
|
+
default: U(() => [M(B(e.secondaryButtonText), 1)]),
|
|
231
231
|
_: 1
|
|
232
232
|
}, 8, [
|
|
233
233
|
"appearance",
|
|
234
234
|
"variant",
|
|
235
235
|
"size"
|
|
236
|
-
])) :
|
|
236
|
+
])) : k("", !0)])) : k("", !0)
|
|
237
237
|
]),
|
|
238
|
-
e.layout ===
|
|
238
|
+
e.layout === V(J).HORIZONTAL && m.value ? (I(), A("div", pn, [e.showPrimaryButton && e.primaryButtonText ? (I(), O(V(w), {
|
|
239
239
|
key: 0,
|
|
240
240
|
appearance: h.value,
|
|
241
241
|
variant: g.value,
|
|
242
|
-
size:
|
|
242
|
+
size: V(x).SMALL,
|
|
243
243
|
onClick: y
|
|
244
244
|
}, {
|
|
245
|
-
default:
|
|
245
|
+
default: U(() => [M(B(e.primaryButtonText), 1)]),
|
|
246
246
|
_: 1
|
|
247
247
|
}, 8, [
|
|
248
248
|
"appearance",
|
|
249
249
|
"variant",
|
|
250
250
|
"size"
|
|
251
|
-
])) :
|
|
251
|
+
])) : k("", !0), e.layout === V(J).HORIZONTAL && e.closable ? (I(), O(V(w), {
|
|
252
252
|
key: 1,
|
|
253
253
|
class: "s-ui-notification__close",
|
|
254
|
-
appearance:
|
|
255
|
-
variant:
|
|
256
|
-
size:
|
|
254
|
+
appearance: V(C).BARE,
|
|
255
|
+
variant: V(S).NEUTRAL,
|
|
256
|
+
size: V(x).SMALL,
|
|
257
257
|
"aria-label": e.closeAriaLabel,
|
|
258
258
|
icon: "closeMini",
|
|
259
259
|
onClick: _
|
|
@@ -262,15 +262,15 @@ var Xt = [
|
|
|
262
262
|
"variant",
|
|
263
263
|
"size",
|
|
264
264
|
"aria-label"
|
|
265
|
-
])) :
|
|
266
|
-
])], 14,
|
|
265
|
+
])) : k("", !0)])) : k("", !0)
|
|
266
|
+
])], 14, nn));
|
|
267
267
|
}
|
|
268
|
-
}),
|
|
268
|
+
}), hn = /* @__PURE__ */ N({
|
|
269
269
|
__name: "SBanner",
|
|
270
270
|
props: {
|
|
271
|
-
type: { default: () =>
|
|
272
|
-
layout: { default: () =>
|
|
273
|
-
leftside: { default: () =>
|
|
271
|
+
type: { default: () => q.INFO_ACCENT },
|
|
272
|
+
layout: { default: () => J.HORIZONTAL },
|
|
273
|
+
leftside: { default: () => Y.ICON },
|
|
274
274
|
title: {},
|
|
275
275
|
description: {},
|
|
276
276
|
linkText: {},
|
|
@@ -296,14 +296,14 @@ var Xt = [
|
|
|
296
296
|
"secondaryAction"
|
|
297
297
|
],
|
|
298
298
|
setup(e, { emit: t }) {
|
|
299
|
-
let n = t, r =
|
|
300
|
-
return (t, i) => (
|
|
299
|
+
let n = t, r = H();
|
|
300
|
+
return (t, i) => (I(), O(mn, {
|
|
301
301
|
class: "s-ui-banner",
|
|
302
302
|
"data-qa": "ui:banner",
|
|
303
303
|
type: e.type,
|
|
304
304
|
layout: e.layout,
|
|
305
305
|
leftside: e.leftside,
|
|
306
|
-
surface:
|
|
306
|
+
surface: V(X).BANNER,
|
|
307
307
|
title: e.title,
|
|
308
308
|
description: e.description,
|
|
309
309
|
linkText: e.linkText,
|
|
@@ -319,13 +319,13 @@ var Xt = [
|
|
|
319
319
|
onLinkClick: i[1] ||= (e) => n("linkClick"),
|
|
320
320
|
onPrimaryAction: i[2] ||= (e) => n("primaryAction"),
|
|
321
321
|
onSecondaryAction: i[3] ||= (e) => n("secondaryAction")
|
|
322
|
-
},
|
|
322
|
+
}, Ft({ _: 2 }, [V(r).title ? {
|
|
323
323
|
name: "title",
|
|
324
|
-
fn:
|
|
324
|
+
fn: U(() => [R(t.$slots, "title")]),
|
|
325
325
|
key: "0"
|
|
326
|
-
} : void 0,
|
|
326
|
+
} : void 0, V(r).description ? {
|
|
327
327
|
name: "description",
|
|
328
|
-
fn:
|
|
328
|
+
fn: U(() => [R(t.$slots, "description")]),
|
|
329
329
|
key: "1"
|
|
330
330
|
} : void 0]), 1032, [
|
|
331
331
|
"type",
|
|
@@ -345,12 +345,12 @@ var Xt = [
|
|
|
345
345
|
"maxWidth"
|
|
346
346
|
]));
|
|
347
347
|
}
|
|
348
|
-
}),
|
|
348
|
+
}), gn = /* @__PURE__ */ N({
|
|
349
349
|
__name: "SToast",
|
|
350
350
|
props: {
|
|
351
|
-
type: { default: () =>
|
|
352
|
-
layout: { default: () =>
|
|
353
|
-
leftside: { default: () =>
|
|
351
|
+
type: { default: () => q.INFO_ACCENT },
|
|
352
|
+
layout: { default: () => J.HORIZONTAL },
|
|
353
|
+
leftside: { default: () => Y.ICON },
|
|
354
354
|
title: {},
|
|
355
355
|
description: {},
|
|
356
356
|
linkText: {},
|
|
@@ -376,14 +376,14 @@ var Xt = [
|
|
|
376
376
|
"secondaryAction"
|
|
377
377
|
],
|
|
378
378
|
setup(e, { emit: t }) {
|
|
379
|
-
let n = t, r =
|
|
380
|
-
return (t, a) => (
|
|
379
|
+
let n = t, r = H(), i = D(() => e.width ?? 360);
|
|
380
|
+
return (t, a) => (I(), O(mn, {
|
|
381
381
|
class: "s-ui-toast",
|
|
382
382
|
"data-qa": "ui:toast",
|
|
383
383
|
type: e.type,
|
|
384
384
|
layout: e.layout,
|
|
385
385
|
leftside: e.leftside,
|
|
386
|
-
surface:
|
|
386
|
+
surface: V(X).TOAST,
|
|
387
387
|
title: e.title,
|
|
388
388
|
description: e.description,
|
|
389
389
|
linkText: e.linkText,
|
|
@@ -399,13 +399,13 @@ var Xt = [
|
|
|
399
399
|
onLinkClick: a[1] ||= (e) => n("linkClick"),
|
|
400
400
|
onPrimaryAction: a[2] ||= (e) => n("primaryAction"),
|
|
401
401
|
onSecondaryAction: a[3] ||= (e) => n("secondaryAction")
|
|
402
|
-
},
|
|
402
|
+
}, Ft({ _: 2 }, [V(r).title ? {
|
|
403
403
|
name: "title",
|
|
404
|
-
fn:
|
|
404
|
+
fn: U(() => [R(t.$slots, "title")]),
|
|
405
405
|
key: "0"
|
|
406
|
-
} : void 0,
|
|
406
|
+
} : void 0, V(r).description ? {
|
|
407
407
|
name: "description",
|
|
408
|
-
fn:
|
|
408
|
+
fn: U(() => [R(t.$slots, "description")]),
|
|
409
409
|
key: "1"
|
|
410
410
|
} : void 0]), 1032, [
|
|
411
411
|
"type",
|
|
@@ -425,13 +425,13 @@ var Xt = [
|
|
|
425
425
|
"width"
|
|
426
426
|
]));
|
|
427
427
|
}
|
|
428
|
-
}),
|
|
428
|
+
}), _n = .05, vn = [
|
|
429
429
|
"data-mounted",
|
|
430
430
|
"data-front",
|
|
431
431
|
"data-expanded",
|
|
432
432
|
"data-removed",
|
|
433
433
|
"data-visible"
|
|
434
|
-
],
|
|
434
|
+
], yn = /* @__PURE__ */ N({
|
|
435
435
|
__name: "SToastProviderToast",
|
|
436
436
|
props: {
|
|
437
437
|
index: {},
|
|
@@ -444,7 +444,7 @@ var Xt = [
|
|
|
444
444
|
},
|
|
445
445
|
emits: ["heightChange"],
|
|
446
446
|
setup(e, { emit: t }) {
|
|
447
|
-
let n = t, r =
|
|
447
|
+
let n = t, r = L(null), i = L(0), a = L(!1), o = D(() => e.index === 0), s = D(() => 1 - e.index * _n), c = D(() => ({
|
|
448
448
|
"--s-ui-toast-provider-toasts-before": String(e.index),
|
|
449
449
|
"--s-ui-toast-provider-lift-amount": `${e.stackPeek * -1}px`,
|
|
450
450
|
"--s-ui-toast-provider-front-toast-height": `${e.frontToastHeight}px`,
|
|
@@ -453,95 +453,95 @@ var Xt = [
|
|
|
453
453
|
"--s-ui-toast-provider-stack-scale": String(s.value),
|
|
454
454
|
zIndex: String(1e3 - e.index)
|
|
455
455
|
}));
|
|
456
|
-
return
|
|
456
|
+
return Qt(r, (e) => {
|
|
457
457
|
let t = e[0]?.contentRect.height ?? 0;
|
|
458
458
|
t !== i.value && (i.value = t, n("heightChange", t));
|
|
459
|
-
}),
|
|
459
|
+
}), zt(() => {
|
|
460
460
|
requestAnimationFrame(() => {
|
|
461
461
|
requestAnimationFrame(() => {
|
|
462
462
|
a.value = !0;
|
|
463
463
|
});
|
|
464
464
|
});
|
|
465
|
-
}), (t, n) => (
|
|
465
|
+
}), (t, n) => (I(), A("div", {
|
|
466
466
|
class: "s-ui-toast-provider__toast",
|
|
467
467
|
"data-mounted": a.value,
|
|
468
468
|
"data-front": o.value,
|
|
469
469
|
"data-expanded": e.expanded,
|
|
470
470
|
"data-removed": e.removed,
|
|
471
471
|
"data-visible": e.visible,
|
|
472
|
-
style:
|
|
473
|
-
}, [
|
|
472
|
+
style: F(c.value)
|
|
473
|
+
}, [j("div", {
|
|
474
474
|
ref_key: "contentRef",
|
|
475
475
|
ref: r,
|
|
476
476
|
class: "s-ui-toast-provider__toast-content"
|
|
477
|
-
}, [
|
|
477
|
+
}, [R(t.$slots, "default")], 512)], 12, vn));
|
|
478
478
|
}
|
|
479
|
-
}),
|
|
480
|
-
let n =
|
|
481
|
-
return n > 1e4 ?
|
|
482
|
-
},
|
|
483
|
-
type:
|
|
484
|
-
layout:
|
|
485
|
-
leftside:
|
|
479
|
+
}), bn = 4e3, xn = 1e4, Sn = 50, Cn = (e, t) => {
|
|
480
|
+
let n = bn + (e.length + (t?.length ?? 0)) * 50;
|
|
481
|
+
return n > 1e4 ? xn : n;
|
|
482
|
+
}, Z = z([]), Q = /* @__PURE__ */ new Map(), wn = 0, Tn = {
|
|
483
|
+
type: q.INFO_ACCENT,
|
|
484
|
+
layout: J.HORIZONTAL,
|
|
485
|
+
leftside: Y.ICON,
|
|
486
486
|
showPrimaryButton: !1,
|
|
487
487
|
closable: !0
|
|
488
|
-
},
|
|
489
|
-
let t =
|
|
490
|
-
t && (window.clearTimeout(t),
|
|
491
|
-
},
|
|
492
|
-
|
|
493
|
-
let t = e.duration === void 0 ?
|
|
488
|
+
}, En = () => `toast-${Date.now()}-${++wn}`, $ = (e) => {
|
|
489
|
+
let t = Q.get(e);
|
|
490
|
+
t && (window.clearTimeout(t), Q.delete(e));
|
|
491
|
+
}, Dn = (e) => {
|
|
492
|
+
$(e.id);
|
|
493
|
+
let t = e.duration === void 0 ? Cn(e.title, e.description) : e.duration;
|
|
494
494
|
if (t > 0) {
|
|
495
495
|
let n = window.setTimeout(() => {
|
|
496
|
-
|
|
496
|
+
On(e.id);
|
|
497
497
|
}, t);
|
|
498
|
-
|
|
498
|
+
Q.set(e.id, n);
|
|
499
499
|
}
|
|
500
|
-
},
|
|
501
|
-
let t =
|
|
500
|
+
}, On = (e) => {
|
|
501
|
+
let t = Z.value.findIndex((t) => t.id === e);
|
|
502
502
|
if (t === -1) return;
|
|
503
|
-
let n =
|
|
504
|
-
n && (
|
|
505
|
-
},
|
|
506
|
-
|
|
507
|
-
},
|
|
508
|
-
|
|
509
|
-
}), e.slice(0, 3)),
|
|
510
|
-
let t = e.id ??
|
|
511
|
-
...
|
|
503
|
+
let n = Z.value[t];
|
|
504
|
+
n && ($(e), n.onClose && n.onClose(), Z.value = Z.value.filter((t) => t.id !== e));
|
|
505
|
+
}, kn = () => {
|
|
506
|
+
Q.forEach((e) => window.clearTimeout(e)), Q.clear(), Z.value = [];
|
|
507
|
+
}, An = (e) => e.length <= 3 ? e : (e.slice(3).forEach((e) => {
|
|
508
|
+
$(e.id);
|
|
509
|
+
}), e.slice(0, 3)), jn = (e) => {
|
|
510
|
+
let t = e.id ?? En(), n = {
|
|
511
|
+
...Tn,
|
|
512
512
|
...e,
|
|
513
513
|
id: t
|
|
514
|
-
}, r =
|
|
514
|
+
}, r = Z.value.findIndex((e) => e.id === t);
|
|
515
515
|
if (r > -1) {
|
|
516
|
-
let e = [...
|
|
517
|
-
e[r] = n,
|
|
518
|
-
} else
|
|
519
|
-
return
|
|
520
|
-
},
|
|
521
|
-
let n =
|
|
516
|
+
let e = [...Z.value];
|
|
517
|
+
e[r] = n, Z.value = An(e);
|
|
518
|
+
} else Z.value = An([n, ...Z.value]);
|
|
519
|
+
return Dn(n), t;
|
|
520
|
+
}, Mn = (e, t) => {
|
|
521
|
+
let n = Z.value.findIndex((t) => t.id === e);
|
|
522
522
|
if (n === -1) return;
|
|
523
|
-
let r =
|
|
523
|
+
let r = Z.value[n];
|
|
524
524
|
if (!r) return;
|
|
525
525
|
let i = {
|
|
526
526
|
...r,
|
|
527
527
|
...t,
|
|
528
528
|
id: r.id
|
|
529
|
-
}, a = [...
|
|
530
|
-
a[n] = i,
|
|
531
|
-
},
|
|
532
|
-
toasts:
|
|
533
|
-
show:
|
|
534
|
-
hide:
|
|
535
|
-
hideAll:
|
|
536
|
-
update:
|
|
537
|
-
}),
|
|
529
|
+
}, a = [...Z.value];
|
|
530
|
+
a[n] = i, Z.value = a, Dn(i);
|
|
531
|
+
}, Nn = () => ({
|
|
532
|
+
toasts: Z,
|
|
533
|
+
show: jn,
|
|
534
|
+
hide: On,
|
|
535
|
+
hideAll: kn,
|
|
536
|
+
update: Mn
|
|
537
|
+
}), Pn = /* @__PURE__ */ N({
|
|
538
538
|
__name: "SToastProvider",
|
|
539
539
|
setup(e) {
|
|
540
|
-
let { toasts: t, hide: n } =
|
|
541
|
-
|
|
540
|
+
let { toasts: t, hide: n } = Nn(), r = D(() => t.value.slice(0, 3)), i = L(!1), a = z({}), o = L(/* @__PURE__ */ new Set()), s = D(() => t.value[0] ?? null), c = D(() => s.value ? a.value[s.value.id] ?? 0 : 0), l = L(0), u = D(() => c.value > 0 ? c.value : l.value);
|
|
541
|
+
Wt(c, (e) => {
|
|
542
542
|
e > 0 && (l.value = e);
|
|
543
543
|
});
|
|
544
|
-
let d =
|
|
544
|
+
let d = D(() => {
|
|
545
545
|
if (r.value.length === 0) return {};
|
|
546
546
|
if (i.value) return { height: `${r.value.reduce((e, t, n) => {
|
|
547
547
|
let r = a.value[t.id] ?? 0, i = n > 0 ? 4 : 0;
|
|
@@ -580,32 +580,32 @@ var Xt = [
|
|
|
580
580
|
}, b = (e) => {
|
|
581
581
|
e.onSecondaryAction && e.onSecondaryAction();
|
|
582
582
|
};
|
|
583
|
-
return (e, t) => (
|
|
583
|
+
return (e, t) => (I(), O(Pt, { to: "body" }, [j("div", {
|
|
584
584
|
class: "s-ui-toast-provider",
|
|
585
585
|
onMouseenter: m,
|
|
586
586
|
onMouseleave: h
|
|
587
|
-
}, [r.value.length > 0 ? (
|
|
587
|
+
}, [r.value.length > 0 ? (I(), A("div", {
|
|
588
588
|
key: 0,
|
|
589
589
|
class: "s-ui-toast-provider__list",
|
|
590
|
-
style:
|
|
591
|
-
}, [(
|
|
590
|
+
style: F(d.value)
|
|
591
|
+
}, [(I(!0), A(Nt, null, Bt(r.value, (t, n) => (I(), O(yn, {
|
|
592
592
|
key: t.id,
|
|
593
593
|
index: n,
|
|
594
594
|
expanded: i.value,
|
|
595
595
|
"front-toast-height": u.value,
|
|
596
|
-
"stack-peek":
|
|
596
|
+
"stack-peek": V(10),
|
|
597
597
|
removed: p(t.id),
|
|
598
|
-
visible: n <
|
|
598
|
+
visible: n < V(3),
|
|
599
599
|
"offset-y": f(n),
|
|
600
600
|
onHeightChange: (e) => g(t.id, e)
|
|
601
601
|
}, {
|
|
602
|
-
default:
|
|
602
|
+
default: U(() => [R(e.$slots, "toast", { toast: t }, () => [t.component ? (I(), O(Vt(t.component), Rt({
|
|
603
603
|
key: 0,
|
|
604
604
|
ref_for: !0
|
|
605
605
|
}, t.componentProps, {
|
|
606
606
|
toast: t,
|
|
607
607
|
onClose: (e) => _(t.id)
|
|
608
|
-
}), null, 16, ["toast", "onClose"])) : (
|
|
608
|
+
}), null, 16, ["toast", "onClose"])) : (I(), O(V(gn), {
|
|
609
609
|
key: 1,
|
|
610
610
|
type: t.type,
|
|
611
611
|
layout: t.layout,
|
|
@@ -655,12 +655,12 @@ var Xt = [
|
|
|
655
655
|
"visible",
|
|
656
656
|
"offset-y",
|
|
657
657
|
"onHeightChange"
|
|
658
|
-
]))), 128))], 4)) :
|
|
658
|
+
]))), 128))], 4)) : k("", !0)], 32)]));
|
|
659
659
|
}
|
|
660
|
-
}),
|
|
660
|
+
}), Fn = 4, In = 4, Ln = 1, Rn = "400 12px var(--s-ui-font-family-label)", zn = 4, Bn = (e, t, n, r, i, a) => {
|
|
661
661
|
let o = Math.min(a, r / 2, i / 2);
|
|
662
662
|
e.beginPath(), e.moveTo(t + o, n), e.lineTo(t + r - o, n), e.arcTo(t + r, n, t + r, n + o, o), e.lineTo(t + r, n + i - o), e.arcTo(t + r, n + i, t + r - o, n + i, o), e.lineTo(t + o, n + i), e.arcTo(t, n + i, t, n + i - o, o), e.lineTo(t, n + o), e.arcTo(t, n, t + o, n, o), e.closePath();
|
|
663
|
-
},
|
|
663
|
+
}, Vn = (e) => {
|
|
664
664
|
let t = e.getProps([
|
|
665
665
|
"x",
|
|
666
666
|
"y",
|
|
@@ -671,14 +671,14 @@ var Xt = [
|
|
|
671
671
|
width: Math.abs(n - i),
|
|
672
672
|
centerY: r
|
|
673
673
|
};
|
|
674
|
-
},
|
|
675
|
-
let i =
|
|
674
|
+
}, Hn = (e, t, n, r) => {
|
|
675
|
+
let i = Vn(t);
|
|
676
676
|
if (!i) return;
|
|
677
|
-
let a = `${n}`, o = e.measureText(a).width +
|
|
678
|
-
if (i.width < o +
|
|
677
|
+
let a = `${n}`, o = e.measureText(a).width + Fn * 2;
|
|
678
|
+
if (i.width < o + zn * 2) return;
|
|
679
679
|
let s = i.left + i.width / 2;
|
|
680
|
-
|
|
681
|
-
},
|
|
680
|
+
Bn(e, s - o / 2, i.centerY - 20 / 2, o, 20, In), e.fillStyle = r.background, e.fill(), e.lineWidth = Ln, e.strokeStyle = r.border, e.stroke(), e.fillStyle = r.text, e.fillText(a, s, i.centerY);
|
|
681
|
+
}, Un = (e) => ({
|
|
682
682
|
id: "segmentedBarBadge",
|
|
683
683
|
afterDatasetsDraw(t) {
|
|
684
684
|
let n = {
|
|
@@ -686,20 +686,20 @@ var Xt = [
|
|
|
686
686
|
border: E(T.pieBadgeBorder, e),
|
|
687
687
|
text: E(T.pieBadgeText, e)
|
|
688
688
|
}, { ctx: r } = t;
|
|
689
|
-
r.save(), r.font =
|
|
689
|
+
r.save(), r.font = Rn, r.textAlign = "center", r.textBaseline = "middle", t.data.datasets.forEach((e, i) => {
|
|
690
690
|
let a = t.getDatasetMeta(i)?.data[0], o = e.data[0];
|
|
691
|
-
a && typeof o == "number" && o > 0 &&
|
|
691
|
+
a && typeof o == "number" && o > 0 && Hn(r, a, o, n);
|
|
692
692
|
}), r.restore();
|
|
693
693
|
}
|
|
694
|
-
}),
|
|
694
|
+
}), Wn = 40, Gn = 4, Kn = 1, qn = [
|
|
695
695
|
"mousemove",
|
|
696
696
|
"mouseout",
|
|
697
697
|
"click",
|
|
698
698
|
"touchstart",
|
|
699
699
|
"touchmove"
|
|
700
|
-
],
|
|
700
|
+
], Jn = ({ segments: e, segmentColors: t, colorHostElement: n, skeleton: r = !1, onSegmentClick: i }) => {
|
|
701
701
|
if (e.length === 0) return null;
|
|
702
|
-
let a = E("--s-ui-color-surface-primary", n), o = e.reduce((e, t) => e + t.value, 0), s =
|
|
702
|
+
let a = E("--s-ui-color-surface-primary", n), o = e.reduce((e, t) => e + t.value, 0), s = st({
|
|
703
703
|
kind: "series",
|
|
704
704
|
skeleton: r,
|
|
705
705
|
colorHostElement: n,
|
|
@@ -716,12 +716,12 @@ var Xt = [
|
|
|
716
716
|
hoverBackgroundColor: t[n],
|
|
717
717
|
borderColor: a,
|
|
718
718
|
borderWidth: {
|
|
719
|
-
left:
|
|
720
|
-
right:
|
|
719
|
+
left: Kn,
|
|
720
|
+
right: Kn
|
|
721
721
|
},
|
|
722
722
|
borderSkipped: !1,
|
|
723
|
-
borderRadius:
|
|
724
|
-
barThickness:
|
|
723
|
+
borderRadius: Gn,
|
|
724
|
+
barThickness: Wn,
|
|
725
725
|
stack: "track"
|
|
726
726
|
}))
|
|
727
727
|
},
|
|
@@ -730,7 +730,7 @@ var Xt = [
|
|
|
730
730
|
responsive: !0,
|
|
731
731
|
maintainAspectRatio: !1,
|
|
732
732
|
layout: { padding: 0 },
|
|
733
|
-
events: r ? [] :
|
|
733
|
+
events: r ? [] : qn,
|
|
734
734
|
onHover: s.onHover,
|
|
735
735
|
onClick: s.onClick,
|
|
736
736
|
hover: r ? void 0 : {
|
|
@@ -755,9 +755,9 @@ var Xt = [
|
|
|
755
755
|
}
|
|
756
756
|
}
|
|
757
757
|
},
|
|
758
|
-
plugins: [...r ? [] : [
|
|
758
|
+
plugins: [...r ? [] : [Un(n)], ...s.plugins]
|
|
759
759
|
};
|
|
760
|
-
},
|
|
760
|
+
}, Yn = [
|
|
761
761
|
4,
|
|
762
762
|
1,
|
|
763
763
|
2,
|
|
@@ -769,7 +769,7 @@ var Xt = [
|
|
|
769
769
|
].map((e, t) => ({
|
|
770
770
|
label: `Series ${t + 1}`,
|
|
771
771
|
value: e
|
|
772
|
-
})),
|
|
772
|
+
})), Xn = { class: "s-ui-chart-segmented-bar__canvas-wrap" }, Zn = /* @__PURE__ */ N({
|
|
773
773
|
__name: "SChartSegmentedBar",
|
|
774
774
|
props: {
|
|
775
775
|
segments: { default: () => [] },
|
|
@@ -784,10 +784,10 @@ var Xt = [
|
|
|
784
784
|
},
|
|
785
785
|
emits: ["segmentClick"],
|
|
786
786
|
setup(e, { expose: t, emit: n }) {
|
|
787
|
-
let r = n, i =
|
|
787
|
+
let r = n, i = lt, a = Ut("chartRootRef"), o = Ut("chartCanvasRef"), s = D(() => e.loading ? Yn : e.segments), c = D(() => s.value.map((t, n) => $t(n, a.value, t.fillColor, e.loading))), l = D(() => s.value.map((e, t) => ({
|
|
788
788
|
segment: e,
|
|
789
789
|
segmentIndex: t
|
|
790
|
-
})).filter(({ segment: e }) => e.value > 0)), u =
|
|
790
|
+
})).filter(({ segment: e }) => e.value > 0)), u = D(() => l.value.map(({ segment: e }) => e)), d = D(() => l.value.map(({ segmentIndex: e }) => c.value[e] ?? "")), f = D(() => {
|
|
791
791
|
let e = /* @__PURE__ */ new Map();
|
|
792
792
|
return l.value.forEach(({ segmentIndex: t }, n) => {
|
|
793
793
|
e.set(t, n);
|
|
@@ -795,42 +795,42 @@ var Xt = [
|
|
|
795
795
|
}), p = (e) => {
|
|
796
796
|
let t = l.value[e];
|
|
797
797
|
t && r("segmentClick", t.segmentIndex, t.segment);
|
|
798
|
-
}, m =
|
|
798
|
+
}, m = St("onSegmentClick"), h = D(() => Jn({
|
|
799
799
|
segments: u.value,
|
|
800
800
|
segmentColors: d.value,
|
|
801
801
|
colorHostElement: a.value,
|
|
802
802
|
skeleton: e.loading,
|
|
803
803
|
onSegmentClick: m() ? p : void 0
|
|
804
|
-
})), g =
|
|
804
|
+
})), g = D(() => s.value.map((e, t) => ({
|
|
805
805
|
label: e.label,
|
|
806
806
|
color: c.value[t] ?? ""
|
|
807
|
-
}))), { chartInstance: _ } =
|
|
807
|
+
}))), { chartInstance: _ } = ct({
|
|
808
808
|
canvasRef: o,
|
|
809
809
|
config: h,
|
|
810
|
-
enabled:
|
|
811
|
-
}), { exportImage: v, handleLegendItemHover: y } =
|
|
810
|
+
enabled: D(() => e.loading || u.value.length > 0)
|
|
811
|
+
}), { exportImage: v, handleLegendItemHover: y } = ut({
|
|
812
812
|
chartInstance: _,
|
|
813
813
|
canvasRef: o,
|
|
814
814
|
colorHostElement: a
|
|
815
815
|
}), b = (e) => {
|
|
816
816
|
y(e === null ? null : f.value.get(e) ?? null);
|
|
817
817
|
};
|
|
818
|
-
return t({ exportImage: v }), (t, n) => (
|
|
818
|
+
return t({ exportImage: v }), (t, n) => (I(), A("div", {
|
|
819
819
|
ref_key: "chartRootRef",
|
|
820
820
|
ref: a,
|
|
821
|
-
class:
|
|
821
|
+
class: P(["s-ui-chart-segmented-bar", { "s-ui-chart-segmented-bar--skeleton": e.loading }]),
|
|
822
822
|
"data-qa": "ui:chart-segmented-bar"
|
|
823
|
-
}, [
|
|
823
|
+
}, [j("div", Xn, [It(V(dt), {
|
|
824
824
|
loading: e.loading,
|
|
825
|
-
type:
|
|
825
|
+
type: V(i).CARTESIAN
|
|
826
826
|
}, {
|
|
827
|
-
default:
|
|
827
|
+
default: U(() => [j("canvas", {
|
|
828
828
|
ref_key: "chartCanvasRef",
|
|
829
829
|
ref: o,
|
|
830
830
|
class: "s-ui-chart-segmented-bar__canvas"
|
|
831
831
|
}, null, 512)]),
|
|
832
832
|
_: 1
|
|
833
|
-
}, 8, ["loading", "type"])]), e.showLegend && g.value.length ? (
|
|
833
|
+
}, 8, ["loading", "type"])]), e.showLegend && g.value.length ? (I(), O(V(xt), {
|
|
834
834
|
key: 0,
|
|
835
835
|
items: g.value,
|
|
836
836
|
disabled: e.loading,
|
|
@@ -840,24 +840,24 @@ var Xt = [
|
|
|
840
840
|
"items",
|
|
841
841
|
"disabled",
|
|
842
842
|
"interactive"
|
|
843
|
-
])) :
|
|
843
|
+
])) : k("", !0)], 2));
|
|
844
844
|
}
|
|
845
|
-
}),
|
|
845
|
+
}), Qn = {
|
|
846
846
|
key: 0,
|
|
847
847
|
class: "s-ui-chart-widget__header"
|
|
848
|
-
},
|
|
848
|
+
}, $n = {
|
|
849
849
|
key: 0,
|
|
850
850
|
class: "s-ui-chart-widget__title-skeleton",
|
|
851
851
|
"aria-hidden": "true"
|
|
852
|
-
},
|
|
852
|
+
}, er = {
|
|
853
853
|
key: 1,
|
|
854
854
|
class: "s-ui-chart-widget__title s-ui-typography-label-16-medium"
|
|
855
|
-
},
|
|
855
|
+
}, tr = { class: "s-ui-chart-widget__controls" }, nr = {
|
|
856
856
|
key: 1,
|
|
857
857
|
class: "s-ui-chart-widget__content"
|
|
858
|
-
},
|
|
858
|
+
}, rr = /* @__PURE__ */ N({
|
|
859
859
|
__name: "SChartWidget",
|
|
860
|
-
props: /*@__PURE__*/
|
|
860
|
+
props: /*@__PURE__*/ Lt({
|
|
861
861
|
title: { default: "" },
|
|
862
862
|
collapsible: {
|
|
863
863
|
type: Boolean,
|
|
@@ -880,16 +880,16 @@ var Xt = [
|
|
|
880
880
|
}),
|
|
881
881
|
emits: ["update:collapsed"],
|
|
882
882
|
setup(e) {
|
|
883
|
-
let t =
|
|
884
|
-
return (n, r) => (
|
|
885
|
-
class:
|
|
883
|
+
let t = Ht(e, "collapsed"), n = H(), { t: r } = Zt(), i = D(() => !!e.title || !!n.title || !!n.actions || e.collapsible), a = D(() => !t.value || !e.collapsible || !e.hideContentWhenCollapsed), o = D(() => r(t.value ? "chartWidget.expand" : "chartWidget.collapse"));
|
|
884
|
+
return (n, r) => (I(), A("div", {
|
|
885
|
+
class: P(["s-ui-chart-widget", { "s-ui-chart-widget--skeleton": e.loading }]),
|
|
886
886
|
"data-qa": "ui:chart-widget"
|
|
887
|
-
}, [i.value ? (
|
|
887
|
+
}, [i.value ? (I(), A("div", Qn, [e.loading ? (I(), A("span", $n)) : (I(), A("span", er, [R(n.$slots, "title", {}, () => [M(B(e.title), 1)])])), j("div", tr, [R(n.$slots, "actions"), e.collapsible ? (I(), O(V(w), {
|
|
888
888
|
key: 0,
|
|
889
|
-
appearance:
|
|
890
|
-
variant:
|
|
891
|
-
size:
|
|
892
|
-
icon: t.value ?
|
|
889
|
+
appearance: V(C).OUTLINED,
|
|
890
|
+
variant: V(S).NEUTRAL,
|
|
891
|
+
size: V(x).SMALL,
|
|
892
|
+
icon: t.value ? V(W).chevronDown : V(W).chevronUp,
|
|
893
893
|
"aria-label": o.value,
|
|
894
894
|
"aria-expanded": !t.value,
|
|
895
895
|
onClick: r[0] ||= (e) => t.value = !t.value
|
|
@@ -900,8 +900,8 @@ var Xt = [
|
|
|
900
900
|
"icon",
|
|
901
901
|
"aria-label",
|
|
902
902
|
"aria-expanded"
|
|
903
|
-
])) :
|
|
903
|
+
])) : k("", !0)])])) : k("", !0), a.value ? (I(), A("div", nr, [R(n.$slots, "default")])) : k("", !0)], 2));
|
|
904
904
|
}
|
|
905
905
|
});
|
|
906
906
|
//#endregion
|
|
907
|
-
export {
|
|
907
|
+
export { Ct as CALENDAR_WEEK_SLOT_COUNT, kt as DAY_TIMELINE_MINUTES, m as DEFAULT_COLOR_PALETTE, p as EAccentColor, C as EButtonAppearance, le as EButtonGroupLayout, x as EButtonSize, x as ESSegmentControlSize, S as EButtonVariant, g as EColorFormat, we as EConnectedPositionStrategy, J as ENotificationLayout, Y as ENotificationLeftside, q as ENotificationType, a as ESAvatarBadge, s as ESAvatarColor, te as ESAvatarGroupSize, i as ESAvatarIconBackground, r as ESAvatarShape, o as ESAvatarSize, e as ESBadgeColor, t as ESBadgePlacement, he as ESCardLayout, fe as ESCheckboxColor, pe as ESCheckboxLabelPlacement, de as ESCheckboxSize, Ae as ESChipColor, je as ESChipSize, h as ESColorPaletteLayout, Se as ESDropdownPlacement, tt as ESInlineInputAppearance, ze as ESInlineMessageValidationStatus, Le as ESInputCustomize, Ve as ESLabelSize, He as ESLabelVariant, We as ESListGap, Je as ESListItemVariant, it as ESPhotoEditShape, at as ESPhotoEditSize, Xe as ESRadioLabelPlacement, Pe as ESSelectSearchable, ve as ESTabAppearance, ye as ESTabSize, Ee as ESTagColor, De as ESTagSize, Qe as ESToggleLabelPlacement, $e as ESToggleSize, se as ESelectionFocusMode, ie as ESelectionMode, oe as ESelectionOrientation, wt as EWorkTimeSource, l as MAX_RECENT_COLORS, _ as RECOMMENDED_COLOR_PALETTE, c as SAvatar, ne as SAvatarGroup, n as SBadge, hn as SBanner, w as SButton, ue as SButtonGroup, Et as SCalendarMonth, Tt as SCalendarWeekGrid, ge as SCard, yt as SChartBurnup, gt as SChartHorizontalBar, xt as SChartLegend, ft as SChartLine, vt as SChartMultiLine, _t as SChartPie, bt as SChartProgress, Zn as SChartSegmentedBar, mt as SChartStackedArea, ht as SChartStackedBar, rr as SChartWidget, me as SCheckbox, Me as SChip, d as SColorArea, v as SColorPalette, f as SColorPicker, u as SColorValues, Dt as SDayTimeline, Ne as SDropdown, Fe as SDropdownMenu, nt as SInlineInput, Be as SInlineMessage, Re as SInput, Ue as SLabel, qe as SList, Ye as SListItem, ot as SPhotoEdit, Ze as SRadio, _e as SSegmentControl, Ie as SSelect, be as STab, xe as STabs, Oe as STag, ke as STagGroup, rt as STextarea, gn as SToast, Pn as SToastProvider, et as SToggle, xn as TOAST_AUTO_DURATION_MAX_MS, bn as TOAST_AUTO_DURATION_MIN_MS, Sn as TOAST_AUTO_DURATION_MS_PER_CHAR, Ot as WORK_TIME_SOURCE_COLOR_VARS, At as WORK_TIME_SOURCE_ORDER, jt as buildWorkTimeLegendItems, Cn as computeAutoDuration, Ce as computeConnectedPosition, Kt as createUiKit, Mt as formatDurationHM, ee as isSameColor, b as normalizeColorValue, y as resolveColorPreview, re as resolveOwnPropOrGroupedOrFallback, qt as setUiKitLocale, Jt as uiKitLocaleEn, Yt as uiKitLocaleRu, Ke as useFlatTreeList, Te as useFloatingOverlay, Ge as useSListEndReached, ae as useSelectionGroup, ce as useSelectionGroupItem, Nn as useToast, Xt as useUiKitI18n };
|