@pgcorp/ui-kit 0.11.0 → 0.12.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.
Files changed (34) hide show
  1. package/README.md +136 -11
  2. package/dist/assets/src/components/shared/controls/SButton.css_vue_type_style_index_0_src_a5d8f7e0_scoped_a5d8f7e0_lang.css +2 -0
  3. package/dist/assets/src/components/shared/controls/SChoiceCards.css_vue_type_style_index_0_src_af9fa9d1_scoped_af9fa9d1_lang.css +2 -0
  4. package/dist/assets/src/components/shared/data-display/{SCodeEditor.css_vue_type_style_index_0_src_124ca461_scoped_124ca461_lang.css → SCodeEditor.css_vue_type_style_index_0_src_3ad533d9_scoped_3ad533d9_lang.css} +1 -1
  5. package/dist/assets/src/components/shared/data-display/SStatus.css_vue_type_style_index_0_src_3ce41a12_scoped_3ce41a12_lang.css +2 -0
  6. package/dist/assets/src/components/shared/data-display/SVirtualList.css_vue_type_style_index_0_src_cee8c247_scoped_cee8c247_lang.css +2 -0
  7. package/dist/src/components/layout/SSideMenuButton.vue.d.ts +1 -1
  8. package/dist/src/components/shared/controls/SButton.vue.d.ts +3 -0
  9. package/dist/src/components/shared/controls/SButton.vue.js +2 -2
  10. package/dist/src/components/shared/controls/SButton.vue_vue_type_script_setup_true_lang.js +103 -99
  11. package/dist/src/components/shared/controls/SChoiceCards.vue.d.ts +1 -0
  12. package/dist/src/components/shared/controls/SChoiceCards.vue.js +2 -2
  13. package/dist/src/components/shared/controls/SChoiceCards.vue_vue_type_script_setup_true_lang.js +53 -49
  14. package/dist/src/components/shared/controls/SMenuSurface.vue.d.ts +2 -2
  15. package/dist/src/components/shared/controls/STextarea.vue.d.ts +4 -0
  16. package/dist/src/components/shared/controls/STextarea.vue_vue_type_script_setup_true_lang.js +5 -1
  17. package/dist/src/components/shared/data-display/SCodeEditor.vue.d.ts +90 -7
  18. package/dist/src/components/shared/data-display/SCodeEditor.vue.js +2 -2
  19. package/dist/src/components/shared/data-display/SStatus.vue.d.ts +7 -0
  20. package/dist/src/components/shared/data-display/SStatus.vue.js +2 -2
  21. package/dist/src/components/shared/data-display/SStatus.vue_vue_type_script_setup_true_lang.js +28 -21
  22. package/dist/src/components/shared/data-display/SVirtualList.vue.d.ts +2 -0
  23. package/dist/src/components/shared/data-display/SVirtualList.vue.js +2 -2
  24. package/dist/src/components/shared/data-display/SVirtualList.vue_vue_type_script_setup_true_lang.js +317 -210
  25. package/dist/src/internal/useBinaryInput.js +3 -2
  26. package/package.json +1 -1
  27. package/src/components/shared/controls/SButton.css +28 -0
  28. package/src/components/shared/controls/SChoiceCards.css +10 -3
  29. package/src/components/shared/data-display/SStatus.css +4 -0
  30. package/src/components/shared/data-display/SVirtualList.css +12 -0
  31. package/dist/assets/src/components/shared/controls/SButton.css_vue_type_style_index_0_src_52ad38b1_scoped_52ad38b1_lang.css +0 -2
  32. package/dist/assets/src/components/shared/controls/SChoiceCards.css_vue_type_style_index_0_src_627a8628_scoped_627a8628_lang.css +0 -2
  33. package/dist/assets/src/components/shared/data-display/SStatus.css_vue_type_style_index_0_src_c76fa058_scoped_c76fa058_lang.css +0 -2
  34. package/dist/assets/src/components/shared/data-display/SVirtualList.css_vue_type_style_index_0_src_1717877d_scoped_1717877d_lang.css +0 -2
@@ -1,29 +1,30 @@
1
1
  import { ChevronRight as e } from "../../icons/_internal/generatedSputnigUiIconComponents.js";
2
2
  import { useOwnedAttrs as t } from "../../../internal/ownedAttrs.js";
3
- import { resolveSemanticToneBinding as n } from "../../../internal/semanticTone.js";
4
- import r from "../data-display/SBadge.vue.js";
5
- import { PassiveContentBoundary as i, useInteractiveLeafRegistration as a } from "../../../internal/passiveContentContract.js";
6
- import { resolveLinkTarget as o } from "../../../internal/linkTarget.js";
7
- import { useTreeActionRegistration as s } from "../_internal/treeRuntime.js";
8
- import c from "../data-display/SProgressIndicator.vue.js";
9
- import { computed as l, createBlock as u, createCommentVNode as d, createElementBlock as f, createElementVNode as p, createTextVNode as m, createVNode as h, defineComponent as g, mergeProps as _, openBlock as v, ref as y, resolveDynamicComponent as b, toDisplayString as x, unref as S, useSlots as C, watchEffect as ee, withCtx as w } from "vue";
10
- import { RouterLink as T } from "vue-router";
3
+ import { validateExactString as n } from "../../../internal/runtimeContract.js";
4
+ import { resolveSemanticToneBinding as r } from "../../../internal/semanticTone.js";
5
+ import i from "../data-display/SBadge.vue.js";
6
+ import { PassiveContentBoundary as a, useInteractiveLeafRegistration as o } from "../../../internal/passiveContentContract.js";
7
+ import { resolveLinkTarget as s } from "../../../internal/linkTarget.js";
8
+ import { useTreeActionRegistration as c } from "../_internal/treeRuntime.js";
9
+ import l from "../data-display/SProgressIndicator.vue.js";
10
+ import { computed as u, createBlock as d, createCommentVNode as f, createElementBlock as p, createElementVNode as m, createTextVNode as h, createVNode as g, defineComponent as _, mergeProps as v, openBlock as y, ref as b, resolveDynamicComponent as x, toDisplayString as S, unref as C, useSlots as ee, watchEffect as w, withCtx as T } from "vue";
11
+ import { RouterLink as E } from "vue-router";
11
12
  //#region src/components/shared/controls/SButton.vue?vue&type=script&setup=true&lang.ts
12
- var E = {
13
+ var D = {
13
14
  key: 0,
14
15
  class: "s-button__loader",
15
16
  "aria-hidden": "true"
16
- }, D = { class: "s-button__content" }, O = ["data-expanded"], k = {
17
+ }, O = { class: "s-button__content" }, k = ["data-expanded"], A = {
17
18
  key: 2,
18
19
  class: "s-button__label"
19
- }, A = {
20
+ }, j = {
20
21
  key: 4,
21
22
  class: "s-button__badge-slot"
22
- }, j = {
23
+ }, M = {
23
24
  key: 5,
24
25
  class: "s-button__shortcut",
25
26
  "aria-hidden": "true"
26
- }, M = ["data-expanded"], N = /*@__PURE__*/ g({
27
+ }, N = ["data-expanded"], P = /*@__PURE__*/ _({
27
28
  inheritAttrs: !1,
28
29
  __name: "SButton",
29
30
  props: {
@@ -56,6 +57,7 @@ var E = {
56
57
  contentAlign: { default: "center" },
57
58
  appearance: { default: "solid" },
58
59
  shape: { default: "default" },
60
+ labelOverflow: { default: "truncate" },
59
61
  pressed: {
60
62
  type: [Boolean, String],
61
63
  default: () => void 0
@@ -72,8 +74,8 @@ var E = {
72
74
  type: {}
73
75
  },
74
76
  emits: ["click"],
75
- setup(g, { expose: N, emit: P }) {
76
- let F = [
77
+ setup(_, { expose: P, emit: F }) {
78
+ let I = [
77
79
  "primary",
78
80
  "secondary",
79
81
  "success",
@@ -81,43 +83,43 @@ var E = {
81
83
  "warn",
82
84
  "danger",
83
85
  "contrast"
84
- ], I = P, L = C(), R = () => L.default?.() ?? [], z = y(null), B = t({
86
+ ], L = F, R = ee(), z = () => R.default?.() ?? [], B = b(null), V = t({
85
87
  component: "SButton",
86
88
  owner: "native button"
87
- }), V = l(() => n("SButton", "severity", g.severity, F)), H = s({
89
+ }), H = u(() => r("SButton", "severity", _.severity, I)), U = u(() => n("SButton", "labelOverflow", _.labelOverflow, ["truncate", "wrap"])), W = c({
88
90
  owner: "SButton",
89
- element: z,
90
- disabled: () => g.disabled || g.loading
91
+ element: B,
92
+ disabled: () => _.disabled || _.loading
91
93
  });
92
- a({ owner: "SButton" });
93
- let U = l(() => {
94
- let e = g.href !== void 0, t = g.to !== void 0;
94
+ o({ owner: "SButton" });
95
+ let G = u(() => {
96
+ let e = _.href !== void 0, t = _.to !== void 0;
95
97
  if (e && t) throw TypeError("SButton: передайте не более одного navigation target — href или to");
96
98
  if (!e && !t) return null;
97
- if (g.type !== void 0) throw TypeError("SButton: navigation target несовместим с native button type");
98
- return o({
99
- href: g.href,
100
- to: g.to,
101
- target: g.target,
102
- rel: g.rel,
99
+ if (_.type !== void 0) throw TypeError("SButton: navigation target несовместим с native button type");
100
+ return s({
101
+ href: _.href,
102
+ to: _.to,
103
+ target: _.target,
104
+ rel: _.rel,
103
105
  owner: "SButton"
104
106
  });
105
- }), W = l(() => g.disabled || g.loading), G = l(() => {
106
- let e = U.value;
107
- return !e || W.value ? e ? "a" : "button" : e.kind === "router" ? T : "a";
108
- }), K = l(() => {
109
- let e = B.bindings(), t = H ? {
107
+ }), K = u(() => _.disabled || _.loading), q = u(() => {
108
+ let e = G.value;
109
+ return !e || K.value ? e ? "a" : "button" : e.kind === "router" ? E : "a";
110
+ }), J = u(() => {
111
+ let e = V.bindings(), t = W ? {
110
112
  ...e,
111
113
  tabindex: -1
112
- } : e, n = g.disclosure ? {
114
+ } : e, n = _.disclosure ? {
113
115
  ...t,
114
- "aria-expanded": g.disclosure.expanded,
115
- "aria-controls": g.disclosure.controls
116
- } : t, r = U.value, i = r === null ? {
116
+ "aria-expanded": _.disclosure.expanded,
117
+ "aria-controls": _.disclosure.controls
118
+ } : t, r = G.value, i = r === null ? {
117
119
  ...n,
118
- disabled: g.disabled || g.loading || void 0,
119
- type: g.type ?? "button"
120
- } : W.value ? {
120
+ disabled: _.disabled || _.loading || void 0,
121
+ type: _.type ?? "button"
122
+ } : K.value ? {
121
123
  ...n,
122
124
  "aria-disabled": !0,
123
125
  tabindex: -1
@@ -125,119 +127,120 @@ var E = {
125
127
  ...n,
126
128
  ...r.bindings
127
129
  };
128
- if (!g.loading) return i;
130
+ if (!_.loading) return i;
129
131
  let a = i["aria-label"], o = [
130
- g.loadingLabel,
131
- g.label,
132
+ _.loadingLabel,
133
+ _.label,
132
134
  a
133
135
  ].find((e) => typeof e == "string" && e.trim().length > 0);
134
- if (!o && !L.default) throw Error("SButton: loading action requires label, loadingLabel, or aria-label");
136
+ if (!o && !R.default) throw Error("SButton: loading action requires label, loadingLabel, or aria-label");
135
137
  return o ? {
136
138
  ...i,
137
139
  "aria-label": o
138
140
  } : i;
139
- }), q = {
141
+ }), Y = {
140
142
  owner: "SButton",
141
143
  region: "passive default content",
142
144
  guidance: "Вынесите независимое действие в соседний SButton. / Move the independent action to a sibling SButton."
143
145
  };
144
- ee(() => {
145
- let e = U.value;
146
- if (e && g.pressed !== void 0) throw Error("SButton: navigation target несовместим с pressed toggle semantics");
147
- if (e && g.disclosure !== void 0) throw Error("SButton: navigation target несовместим с disclosure trigger semantics");
148
- if (g.disclosure && g.disclosure.controls.trim().length === 0) throw Error("SButton: disclosure.controls must be a non-empty id");
149
- let t = g.disclosure?.iconPlacement ?? "trailing";
150
- if (g.disclosure && (t === "leading" && g.leadingIcon || t === "trailing" && g.trailingIcon)) throw Error(`SButton: disclosure ${t} icon conflicts with the matching icon prop`);
146
+ w(() => {
147
+ let e = G.value;
148
+ if (e && _.pressed !== void 0) throw Error("SButton: navigation target несовместим с pressed toggle semantics");
149
+ if (e && _.disclosure !== void 0) throw Error("SButton: navigation target несовместим с disclosure trigger semantics");
150
+ if (_.disclosure && _.disclosure.controls.trim().length === 0) throw Error("SButton: disclosure.controls must be a non-empty id");
151
+ let t = _.disclosure?.iconPlacement ?? "trailing";
152
+ if (_.disclosure && (t === "leading" && _.leadingIcon || t === "trailing" && _.trailingIcon)) throw Error(`SButton: disclosure ${t} icon conflicts with the matching icon prop`);
151
153
  });
152
- let J = l(() => g.iconOnly || g.label === "" && !!(g.leadingIcon || g.trailingIcon || L.default)), Y = l(() => g.label === void 0 || g.label === "" && !g.leadingIcon && !g.trailingIcon), X = l(() => g.size === "lg" ? "sm" : "xs");
153
- function Z(e) {
154
+ let X = u(() => _.iconOnly || _.label === "" && !!(_.leadingIcon || _.trailingIcon || R.default)), Z = u(() => _.label === void 0 || _.label === "" && !_.leadingIcon && !_.trailingIcon), Q = u(() => _.size === "lg" ? "sm" : "xs");
155
+ function te(e) {
154
156
  if (e === null) {
155
- z.value = null;
157
+ B.value = null;
156
158
  return;
157
159
  }
158
160
  if (e instanceof HTMLButtonElement || e instanceof HTMLAnchorElement) {
159
- z.value = e;
161
+ B.value = e;
160
162
  return;
161
163
  }
162
164
  let t = Reflect.get(e, "$el");
163
165
  if (!(t instanceof HTMLAnchorElement)) throw TypeError("SButton: RouterLink root must resolve to an HTMLAnchorElement");
164
- z.value = t;
166
+ B.value = t;
165
167
  }
166
- function Q(e) {
167
- if (U.value && W.value) {
168
+ function ne(e) {
169
+ if (G.value && K.value) {
168
170
  e.preventDefault(), e.stopImmediatePropagation();
169
171
  return;
170
172
  }
171
- I("click", e);
173
+ L("click", e);
172
174
  }
173
175
  let $ = () => {
174
- let e = z.value;
176
+ let e = B.value;
175
177
  if (!e) throw Error("SButton: interactive element is unavailable");
176
178
  return e;
177
179
  };
178
- return N({
180
+ return P({
179
181
  getElement: $,
180
182
  focus: (e) => $().focus(e)
181
- }), (t, n) => (v(), u(b(G.value), _({ ref: Z }, K.value, {
182
- "data-s-tone": V.value["data-s-tone"],
183
+ }), (t, n) => (y(), d(x(q.value), v({ ref: te }, J.value, {
184
+ "data-s-tone": H.value["data-s-tone"],
183
185
  class: "s-button",
184
- "data-size": g.size,
185
- "data-width": g.width,
186
- "data-content-align": g.contentAlign,
187
- "data-density": g.density,
188
- "data-spacing": g.spacing,
189
- "data-hover-surface": g.hoverSurface,
190
- "data-icon-only": J.value,
191
- "data-icon-size": g.iconSize,
192
- "data-appearance": g.appearance,
193
- "data-shape": g.shape,
194
- "data-loading": g.loading || void 0,
195
- "aria-pressed": g.pressed,
196
- "aria-busy": g.busy || g.loading || void 0,
197
- onClick: Q
186
+ "data-size": _.size,
187
+ "data-width": _.width,
188
+ "data-content-align": _.contentAlign,
189
+ "data-density": _.density,
190
+ "data-spacing": _.spacing,
191
+ "data-hover-surface": _.hoverSurface,
192
+ "data-icon-only": X.value,
193
+ "data-icon-size": _.iconSize,
194
+ "data-appearance": _.appearance,
195
+ "data-shape": _.shape,
196
+ "data-label-overflow": U.value,
197
+ "data-loading": _.loading || void 0,
198
+ "aria-pressed": _.pressed,
199
+ "aria-busy": _.busy || _.loading || void 0,
200
+ onClick: ne
198
201
  }), {
199
- default: w(() => [g.loading ? (v(), f("span", E, [h(c, {
202
+ default: T(() => [_.loading ? (y(), p("span", D, [g(l, {
200
203
  accessibility: { mode: "decorative" },
201
- size: X.value
202
- }, null, 8, ["size"])])) : d("", !0), p("span", D, [
203
- g.disclosure?.iconPlacement === "leading" ? (v(), f("span", {
204
+ size: Q.value
205
+ }, null, 8, ["size"])])) : f("", !0), m("span", O, [
206
+ _.disclosure?.iconPlacement === "leading" ? (y(), p("span", {
204
207
  key: 0,
205
208
  class: "s-button__disclosure-icon s-button__icon s-button__icon--leading",
206
- "data-expanded": g.disclosure.expanded,
209
+ "data-expanded": _.disclosure.expanded,
207
210
  "data-disclosure-icon": "",
208
211
  "aria-hidden": "true"
209
- }, [h(S(e))], 8, O)) : g.leadingIcon ? (v(), u(b(g.leadingIcon), {
212
+ }, [g(C(e))], 8, k)) : _.leadingIcon ? (y(), d(x(_.leadingIcon), {
210
213
  key: 1,
211
214
  class: "s-button__icon s-button__icon--leading",
212
215
  "aria-hidden": "true"
213
- })) : d("", !0),
214
- g.label ? (v(), f("span", k, x(g.label), 1)) : d("", !0),
215
- Y.value ? (v(), u(S(i), {
216
+ })) : f("", !0),
217
+ _.label ? (y(), p("span", A, S(_.label), 1)) : f("", !0),
218
+ Z.value ? (y(), d(C(a), {
216
219
  key: 3,
217
- contract: q
220
+ contract: Y
218
221
  }, {
219
- default: w(() => [(v(), u(b(R)))]),
222
+ default: T(() => [(y(), d(x(z)))]),
220
223
  _: 1
221
- })) : d("", !0),
222
- g.badge === void 0 ? d("", !0) : (v(), f("span", A, [h(r, {
223
- severity: g.badgeSeverity,
224
+ })) : f("", !0),
225
+ _.badge === void 0 ? f("", !0) : (y(), p("span", j, [g(i, {
226
+ severity: _.badgeSeverity,
224
227
  size: "xs"
225
228
  }, {
226
- default: w(() => [m(x(g.badge), 1)]),
229
+ default: T(() => [h(S(_.badge), 1)]),
227
230
  _: 1
228
231
  }, 8, ["severity"])])),
229
- g.shortcut ? (v(), f("span", j, x(g.shortcut), 1)) : d("", !0),
230
- g.disclosure && g.disclosure.iconPlacement !== "leading" && g.disclosure.iconPlacement !== "none" ? (v(), f("span", {
232
+ _.shortcut ? (y(), p("span", M, S(_.shortcut), 1)) : f("", !0),
233
+ _.disclosure && _.disclosure.iconPlacement !== "leading" && _.disclosure.iconPlacement !== "none" ? (y(), p("span", {
231
234
  key: 6,
232
235
  class: "s-button__disclosure-icon s-button__icon s-button__icon--trailing",
233
- "data-expanded": g.disclosure.expanded,
236
+ "data-expanded": _.disclosure.expanded,
234
237
  "data-disclosure-icon": "",
235
238
  "aria-hidden": "true"
236
- }, [h(S(e))], 8, M)) : g.trailingIcon ? (v(), u(b(g.trailingIcon), {
239
+ }, [g(C(e))], 8, N)) : _.trailingIcon ? (y(), d(x(_.trailingIcon), {
237
240
  key: 7,
238
241
  class: "s-button__icon s-button__icon--trailing",
239
242
  "aria-hidden": "true"
240
- })) : d("", !0)
243
+ })) : f("", !0)
241
244
  ])]),
242
245
  _: 1
243
246
  }, 16, [
@@ -252,6 +255,7 @@ var E = {
252
255
  "data-icon-size",
253
256
  "data-appearance",
254
257
  "data-shape",
258
+ "data-label-overflow",
255
259
  "data-loading",
256
260
  "aria-pressed",
257
261
  "aria-busy"
@@ -259,4 +263,4 @@ var E = {
259
263
  }
260
264
  });
261
265
  //#endregion
262
- export { N as default };
266
+ export { P as default };
@@ -21,6 +21,7 @@ export interface Props<T extends PublicSelectionKey = string> {
21
21
  invalid?: boolean;
22
22
  disabled?: boolean;
23
23
  readonly?: boolean;
24
+ appearance?: 'cards' | 'rows';
24
25
  columns?: 'auto' | '2' | '3';
25
26
  density?: 'default' | 'compact';
26
27
  selectionIndicator?: 'mark' | 'none';
@@ -1,8 +1,8 @@
1
- import "../../../../assets/src/components/shared/controls/SChoiceCards.css_vue_type_style_index_0_src_627a8628_scoped_627a8628_lang.css";
1
+ import "../../../../assets/src/components/shared/controls/SChoiceCards.css_vue_type_style_index_0_src_af9fa9d1_scoped_af9fa9d1_lang.css";
2
2
  import e from "../../../../_virtual/_plugin-vue_export-helper.js";
3
3
  import t from "./SChoiceCards.vue_vue_type_script_setup_true_lang.js";
4
4
  /* empty css */
5
5
  //#region src/components/shared/controls/SChoiceCards.vue
6
- var n = /*#__PURE__*/ e(t, [["__scopeId", "data-v-627a8628"]]);
6
+ var n = /*#__PURE__*/ e(t, [["__scopeId", "data-v-af9fa9d1"]]);
7
7
  //#endregion
8
8
  export { n as default };
@@ -1,27 +1,29 @@
1
1
  import { useOwnedAttrs as e } from "../../../internal/ownedAttrs.js";
2
- import { useInteractiveLeafRegistration as t } from "../../../internal/passiveContentContract.js";
3
- import n from "./SFieldGroup.vue.js";
4
- import { useRadioGroup as r } from "../_internal/useRadioGroup.js";
5
- import { Fragment as i, computed as a, createBlock as o, createCommentVNode as s, createElementBlock as c, createElementVNode as l, createSlots as u, defineComponent as d, mergeProps as f, openBlock as p, renderList as m, renderSlot as h, toDisplayString as g, unref as _, withCtx as v } from "vue";
2
+ import { validateExactString as t } from "../../../internal/runtimeContract.js";
3
+ import { useInteractiveLeafRegistration as n } from "../../../internal/passiveContentContract.js";
4
+ import r from "./SFieldGroup.vue.js";
5
+ import { useRadioGroup as i } from "../_internal/useRadioGroup.js";
6
+ import { Fragment as a, computed as o, createBlock as s, createCommentVNode as c, createElementBlock as l, createElementVNode as u, createSlots as d, defineComponent as f, mergeProps as p, openBlock as m, renderList as h, renderSlot as g, toDisplayString as _, unref as v, withCtx as y } from "vue";
6
7
  //#region src/components/shared/controls/SChoiceCards.vue?vue&type=script&setup=true&lang.ts
7
- var y = [
8
+ var b = [
9
+ "data-appearance",
8
10
  "data-columns",
9
11
  "data-density",
10
12
  "data-selection-indicator"
11
- ], b = {
13
+ ], x = {
12
14
  key: 0,
13
15
  class: "s-choice-card__kicker"
14
- }, x = { class: "s-choice-card__title" }, S = {
16
+ }, S = { class: "s-choice-card__title" }, C = {
15
17
  key: 1,
16
18
  class: "s-choice-card__description"
17
- }, C = {
19
+ }, w = {
18
20
  key: 2,
19
21
  class: "s-choice-card__meta"
20
- }, w = {
22
+ }, T = {
21
23
  key: 3,
22
24
  class: "s-choice-card__mark",
23
25
  "aria-hidden": "true"
24
- }, T = /*@__PURE__*/ d({
26
+ }, E = /*@__PURE__*/ f({
25
27
  inheritAttrs: !1,
26
28
  __name: "SChoiceCards",
27
29
  props: {
@@ -47,65 +49,67 @@ var y = [
47
49
  type: Boolean,
48
50
  default: !1
49
51
  },
52
+ appearance: { default: "cards" },
50
53
  columns: { default: "auto" },
51
54
  density: { default: "default" },
52
55
  selectionIndicator: { default: "mark" }
53
56
  },
54
57
  emits: ["update:modelValue"],
55
- setup(d, { emit: T }) {
56
- let E = d, D = T, O = e({
58
+ setup(f, { emit: E }) {
59
+ let D = f, O = E, k = e({
57
60
  component: "SChoiceCards",
58
61
  owner: "field group"
59
62
  });
60
- t({ owner: "SChoiceCards" });
61
- let k = r({
62
- options: a(() => E.options),
63
- selectedValue: a(() => E.modelValue),
64
- disabled: a(() => E.disabled),
65
- readonly: a(() => E.readonly),
66
- update: (e) => D("update:modelValue", e),
63
+ n({ owner: "SChoiceCards" });
64
+ let A = o(() => t("SChoiceCards", "appearance", D.appearance, ["cards", "rows"])), j = i({
65
+ options: o(() => D.options),
66
+ selectedValue: o(() => D.modelValue),
67
+ disabled: o(() => D.disabled),
68
+ readonly: o(() => D.readonly),
69
+ update: (e) => O("update:modelValue", e),
67
70
  component: "SChoiceCards"
68
71
  });
69
- return (e, t) => (p(), o(n, f(_(O).bindings(), {
70
- id: d.id,
71
- label: d.label,
72
- "help-text": d.helpText,
73
- "error-message": d.errorMessage,
74
- required: d.required,
75
- invalid: d.invalid,
76
- disabled: d.disabled,
77
- readonly: d.readonly
78
- }), u({
79
- default: v(({ describedBy: e, labelId: t }) => [l("div", f({
72
+ return (e, t) => (m(), s(r, p(v(k).bindings(), {
73
+ id: f.id,
74
+ label: f.label,
75
+ "help-text": f.helpText,
76
+ "error-message": f.errorMessage,
77
+ required: f.required,
78
+ invalid: f.invalid,
79
+ disabled: f.disabled,
80
+ readonly: f.readonly
81
+ }), d({
82
+ default: y(({ describedBy: e, labelId: t }) => [u("div", p({
80
83
  class: "s-choice-cards",
81
- "data-columns": d.columns,
82
- "data-density": d.density,
83
- "data-selection-indicator": d.selectionIndicator
84
- }, _(k).groupBindings({
84
+ "data-appearance": A.value,
85
+ "data-columns": f.columns,
86
+ "data-density": f.density,
87
+ "data-selection-indicator": f.selectionIndicator
88
+ }, v(j).groupBindings({
85
89
  labelledBy: t,
86
90
  describedBy: e,
87
- required: d.required,
88
- invalid: d.invalid
89
- })), [(p(!0), c(i, null, m(d.options, (e) => (p(), c("button", f({
90
- key: _(k).optionToken(e.value),
91
+ required: f.required,
92
+ invalid: f.invalid
93
+ })), [(m(!0), l(a, null, h(f.options, (e) => (m(), l("button", p({
94
+ key: v(j).optionToken(e.value),
91
95
  ref_for: !0,
92
- ref: _(k).optionRef(e.value),
96
+ ref: v(j).optionRef(e.value),
93
97
  class: "s-choice-card"
94
- }, { ref_for: !0 }, _(k).optionBindings(e)), [
95
- e.kicker ? (p(), c("span", b, g(e.kicker), 1)) : s("", !0),
96
- l("span", x, g(e.title), 1),
97
- e.description ? (p(), c("span", S, g(e.description), 1)) : s("", !0),
98
- e.meta ? (p(), c("span", C, g(e.meta), 1)) : s("", !0),
99
- d.selectionIndicator === "mark" && e.value === d.modelValue ? (p(), c("span", w, "✓")) : s("", !0)
100
- ], 16))), 128))], 16, y)]),
98
+ }, { ref_for: !0 }, v(j).optionBindings(e)), [
99
+ e.kicker ? (m(), l("span", x, _(e.kicker), 1)) : c("", !0),
100
+ u("span", S, _(e.title), 1),
101
+ e.description ? (m(), l("span", C, _(e.description), 1)) : c("", !0),
102
+ e.meta ? (m(), l("span", w, _(e.meta), 1)) : c("", !0),
103
+ f.selectionIndicator === "mark" && e.value === f.modelValue ? (m(), l("span", T, "✓")) : c("", !0)
104
+ ], 16))), 128))], 16, b)]),
101
105
  _: 2
102
106
  }, [e.$slots.help ? {
103
107
  name: "help",
104
- fn: v(() => [h(e.$slots, "help", {}, void 0, !0)]),
108
+ fn: y(() => [g(e.$slots, "help", {}, void 0, !0)]),
105
109
  key: "0"
106
110
  } : void 0, e.$slots.error ? {
107
111
  name: "error",
108
- fn: v(() => [h(e.$slots, "error", {}, void 0, !0)]),
112
+ fn: y(() => [g(e.$slots, "error", {}, void 0, !0)]),
109
113
  key: "1"
110
114
  } : void 0]), 1040, [
111
115
  "id",
@@ -120,4 +124,4 @@ var y = [
120
124
  }
121
125
  });
122
126
  //#endregion
123
- export { T as default };
127
+ export { E as default };
@@ -17,15 +17,15 @@ export interface SMenuSurfaceApi {
17
17
  declare const __VLS_export: import('vue').DefineComponent<Props, SMenuSurfaceApi, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
18
18
  select: (item: SMenuSelectableEntry, event: SMenuActivationEvent) => any;
19
19
  escape: () => any;
20
- tab: (event: KeyboardEvent) => any;
21
20
  "focus-exit": (event: FocusEvent) => any;
21
+ tab: (event: KeyboardEvent) => any;
22
22
  "submenu-back": () => any;
23
23
  "dismiss-tree": () => any;
24
24
  }, string, import('vue').PublicProps, Readonly<Props> & Readonly<{
25
25
  onSelect?: ((item: SMenuSelectableEntry, event: SMenuActivationEvent) => any) | undefined;
26
26
  onEscape?: (() => any) | undefined;
27
- onTab?: ((event: KeyboardEvent) => any) | undefined;
28
27
  "onFocus-exit"?: ((event: FocusEvent) => any) | undefined;
28
+ onTab?: ((event: KeyboardEvent) => any) | undefined;
29
29
  "onSubmenu-back"?: (() => any) | undefined;
30
30
  "onDismiss-tree"?: (() => any) | undefined;
31
31
  }>, {
@@ -75,10 +75,12 @@ export interface Props {
75
75
  monospace?: boolean;
76
76
  }
77
77
  declare const __VLS_export: import('vue').DefineComponent<Props, STextareaApi, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {} & {
78
+ blur: (focusEvent: FocusEvent) => any;
78
79
  click: (mouseEvent: MouseEvent) => any;
79
80
  compositionend: (compositionEvent: CompositionEvent) => any;
80
81
  compositionstart: (compositionEvent: CompositionEvent) => any;
81
82
  compositionupdate: (compositionEvent: CompositionEvent) => any;
83
+ focus: (focusEvent: FocusEvent) => any;
82
84
  keydown: (keyboardEvent: KeyboardEvent) => any;
83
85
  keyup: (keyboardEvent: KeyboardEvent) => any;
84
86
  paste: (clipboardEvent: ClipboardEvent) => any;
@@ -86,10 +88,12 @@ declare const __VLS_export: import('vue').DefineComponent<Props, STextareaApi, {
86
88
  "selection-change": (selection: STextareaSelection) => any;
87
89
  "state-change": (state: STextareaState) => any;
88
90
  }, string, import('vue').PublicProps, Readonly<Props> & Readonly<{
91
+ onBlur?: ((focusEvent: FocusEvent) => any) | undefined;
89
92
  onClick?: ((mouseEvent: MouseEvent) => any) | undefined;
90
93
  onCompositionend?: ((compositionEvent: CompositionEvent) => any) | undefined;
91
94
  onCompositionstart?: ((compositionEvent: CompositionEvent) => any) | undefined;
92
95
  onCompositionupdate?: ((compositionEvent: CompositionEvent) => any) | undefined;
96
+ onFocus?: ((focusEvent: FocusEvent) => any) | undefined;
93
97
  onKeydown?: ((keyboardEvent: KeyboardEvent) => any) | undefined;
94
98
  onKeyup?: ((keyboardEvent: KeyboardEvent) => any) | undefined;
95
99
  onPaste?: ((clipboardEvent: ClipboardEvent) => any) | undefined;
@@ -76,6 +76,8 @@ var se = [
76
76
  "keydown",
77
77
  "keyup",
78
78
  "click",
79
+ "focus",
80
+ "blur",
79
81
  "paste",
80
82
  "compositionstart",
81
83
  "compositionupdate",
@@ -390,8 +392,10 @@ var se = [
390
392
  onKeydown: ye,
391
393
  onKeyup: be,
392
394
  onClick: xe,
395
+ onFocus: n[0] ||= (e) => w("focus", e),
396
+ onBlur: n[1] ||= (e) => w("blur", e),
393
397
  onSelect: Se,
394
- onPaste: n[0] ||= (e) => w("paste", e),
398
+ onPaste: n[2] ||= (e) => w("paste", e),
395
399
  onCompositionstart: Ce,
396
400
  onCompositionupdate: we,
397
401
  onCompositionend: Te