@rafael_dias/akoma 0.4.0 → 0.8.1
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/README.md +27 -4
- package/content/README.md +2 -0
- package/content/colors.md +79 -0
- package/content/decisions.md +3 -3
- package/content/icons.md +76 -0
- package/content/implementation.md +1 -1
- package/content/moods.md +12 -0
- package/dist/akoma.cjs +1 -1
- package/dist/akoma.css +1 -1
- package/dist/akoma.js +453 -231
- package/dist/index.d.ts +180 -12
- package/package.json +5 -2
- package/src/styles/accent-palettes.css +239 -0
- package/src/styles/index.css +1 -0
- package/src/styles/motion.css +8 -0
- package/src/styles/tokens.css +43 -71
package/dist/akoma.js
CHANGED
|
@@ -1,24 +1,25 @@
|
|
|
1
|
-
import { computed as e,
|
|
1
|
+
import { computed as e, createBlock as t, createCommentVNode as n, createElementBlock as r, createElementVNode as i, createTextVNode as a, defineComponent as o, inject as s, nextTick as c, normalizeClass as l, normalizeStyle as u, onMounted as d, onUnmounted as f, openBlock as p, provide as m, reactive as h, ref as g, renderSlot as _, toDisplayString as v, toRef as y, unref as b, useId as x, watch as ee } from "vue";
|
|
2
|
+
import { completeIconSet as S } from "@sysvale/cuida-icons";
|
|
2
3
|
//#region \0rolldown/runtime.js
|
|
3
|
-
var
|
|
4
|
+
var C = Object.defineProperty, te = (e, t) => {
|
|
4
5
|
let n = {};
|
|
5
|
-
for (var r in e)
|
|
6
|
+
for (var r in e) C(n, r, {
|
|
6
7
|
get: e[r],
|
|
7
8
|
enumerable: !0
|
|
8
9
|
});
|
|
9
|
-
return t ||
|
|
10
|
-
},
|
|
10
|
+
return t || C(n, Symbol.toStringTag, { value: "Module" }), n;
|
|
11
|
+
}, ne = [
|
|
11
12
|
"type",
|
|
12
13
|
"disabled",
|
|
13
14
|
"aria-busy"
|
|
14
|
-
],
|
|
15
|
+
], re = {
|
|
15
16
|
key: 0,
|
|
16
17
|
class: "ak-button__spinner",
|
|
17
18
|
"aria-hidden": "true"
|
|
18
|
-
},
|
|
19
|
+
}, ie = {
|
|
19
20
|
key: 1,
|
|
20
21
|
class: "ak-button__icon"
|
|
21
|
-
},
|
|
22
|
+
}, ae = { class: "ak-button__label" }, oe = /*@__PURE__*/ o({
|
|
22
23
|
__name: "AkButton",
|
|
23
24
|
props: {
|
|
24
25
|
variant: { default: "primary" },
|
|
@@ -38,8 +39,8 @@ var h = Object.defineProperty, g = (e, t) => {
|
|
|
38
39
|
}
|
|
39
40
|
},
|
|
40
41
|
setup(e) {
|
|
41
|
-
return (
|
|
42
|
-
class:
|
|
42
|
+
return (t, a) => (p(), r("button", {
|
|
43
|
+
class: l(["ak-button tap-scale", [
|
|
43
44
|
`ak-button--${e.variant}`,
|
|
44
45
|
`ak-button--${e.size}`,
|
|
45
46
|
{
|
|
@@ -51,25 +52,25 @@ var h = Object.defineProperty, g = (e, t) => {
|
|
|
51
52
|
disabled: e.disabled || e.loading,
|
|
52
53
|
"aria-busy": e.loading || void 0
|
|
53
54
|
}, [
|
|
54
|
-
e.loading ? (
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
], 10,
|
|
55
|
+
e.loading ? (p(), r("span", re)) : n("", !0),
|
|
56
|
+
t.$slots.icon && !e.loading ? (p(), r("span", ie, [_(t.$slots, "icon", {}, void 0, !0)])) : n("", !0),
|
|
57
|
+
i("span", ae, [_(t.$slots, "default", {}, void 0, !0)])
|
|
58
|
+
], 10, ne));
|
|
58
59
|
}
|
|
59
|
-
}),
|
|
60
|
+
}), w = (e, t) => {
|
|
60
61
|
let n = e.__vccOpts || e;
|
|
61
62
|
for (let [e, r] of t) n[e] = r;
|
|
62
63
|
return n;
|
|
63
|
-
},
|
|
64
|
+
}, T = /*#__PURE__*/ w(oe, [["__scopeId", "data-v-7786dae9"]]), E = /*#__PURE__*/ w(/* @__PURE__ */ o({
|
|
64
65
|
__name: "AkBadge",
|
|
65
66
|
props: {
|
|
66
67
|
variant: { default: "neutral" },
|
|
67
68
|
label: {}
|
|
68
69
|
},
|
|
69
70
|
setup(e) {
|
|
70
|
-
return (t,
|
|
71
|
+
return (t, n) => (p(), r("span", { class: l(["ak-badge", `ak-badge--${e.variant}`]) }, [_(t.$slots, "default", {}, () => [a(v(e.label), 1)], !0)], 2));
|
|
71
72
|
}
|
|
72
|
-
}), [["__scopeId", "data-v-02933f09"]]),
|
|
73
|
+
}), [["__scopeId", "data-v-02933f09"]]), se = ["disabled", "aria-pressed"], D = /*#__PURE__*/ w(/* @__PURE__ */ o({
|
|
73
74
|
__name: "AkChip",
|
|
74
75
|
props: {
|
|
75
76
|
active: {
|
|
@@ -84,29 +85,29 @@ var h = Object.defineProperty, g = (e, t) => {
|
|
|
84
85
|
},
|
|
85
86
|
emits: ["click"],
|
|
86
87
|
setup(e, { emit: t }) {
|
|
87
|
-
let
|
|
88
|
-
return (t, i) => (
|
|
88
|
+
let n = t;
|
|
89
|
+
return (t, i) => (p(), r("button", {
|
|
89
90
|
type: "button",
|
|
90
|
-
class:
|
|
91
|
-
style:
|
|
91
|
+
class: l(["ak-chip tap-scale", { "ak-chip--active": e.active }]),
|
|
92
|
+
style: u(e.active && e.color ? { "--ak-chip-active-bg": e.color } : void 0),
|
|
92
93
|
disabled: e.disabled,
|
|
93
94
|
"aria-pressed": e.active,
|
|
94
|
-
onClick: i[0] ||= (e) =>
|
|
95
|
-
}, [
|
|
95
|
+
onClick: i[0] ||= (e) => n("click", e)
|
|
96
|
+
}, [_(t.$slots, "default", {}, void 0, !0)], 14, se));
|
|
96
97
|
}
|
|
97
|
-
}), [["__scopeId", "data-v-c782362c"]]),
|
|
98
|
+
}), [["__scopeId", "data-v-c782362c"]]), ce = {
|
|
98
99
|
key: 0,
|
|
99
100
|
class: "ak-card__media"
|
|
100
|
-
},
|
|
101
|
+
}, le = {
|
|
101
102
|
key: 1,
|
|
102
103
|
class: "ak-card__header"
|
|
103
|
-
},
|
|
104
|
+
}, ue = {
|
|
104
105
|
key: 2,
|
|
105
106
|
class: "ak-card__body"
|
|
106
|
-
},
|
|
107
|
+
}, de = {
|
|
107
108
|
key: 3,
|
|
108
109
|
class: "ak-card__footer"
|
|
109
|
-
},
|
|
110
|
+
}, O = /*#__PURE__*/ w(/* @__PURE__ */ o({
|
|
110
111
|
__name: "AkCard",
|
|
111
112
|
props: {
|
|
112
113
|
interactive: {
|
|
@@ -116,21 +117,21 @@ var h = Object.defineProperty, g = (e, t) => {
|
|
|
116
117
|
padding: { default: "md" }
|
|
117
118
|
},
|
|
118
119
|
setup(e) {
|
|
119
|
-
return (
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
120
|
+
return (t, i) => (p(), r("article", { class: l(["ak-card", [`ak-card--pad-${e.padding}`, { "ak-card--interactive": e.interactive }]]) }, [
|
|
121
|
+
t.$slots.media ? (p(), r("div", ce, [_(t.$slots, "media", {}, void 0, !0)])) : n("", !0),
|
|
122
|
+
t.$slots.header ? (p(), r("div", le, [_(t.$slots, "header", {}, void 0, !0)])) : n("", !0),
|
|
123
|
+
t.$slots.default ? (p(), r("div", ue, [_(t.$slots, "default", {}, void 0, !0)])) : n("", !0),
|
|
124
|
+
t.$slots.footer ? (p(), r("div", de, [_(t.$slots, "footer", {}, void 0, !0)])) : n("", !0)
|
|
124
125
|
], 2));
|
|
125
126
|
}
|
|
126
|
-
}), [["__scopeId", "data-v-73ac6197"]]),
|
|
127
|
+
}), [["__scopeId", "data-v-73ac6197"]]), fe = {
|
|
127
128
|
key: 0,
|
|
128
129
|
class: "ak-field__label"
|
|
129
|
-
},
|
|
130
|
+
}, pe = {
|
|
130
131
|
key: 0,
|
|
131
132
|
class: "ak-field__required",
|
|
132
133
|
"aria-hidden": "true"
|
|
133
|
-
},
|
|
134
|
+
}, me = [
|
|
134
135
|
"id",
|
|
135
136
|
"type",
|
|
136
137
|
"value",
|
|
@@ -141,7 +142,7 @@ var h = Object.defineProperty, g = (e, t) => {
|
|
|
141
142
|
"autocomplete",
|
|
142
143
|
"aria-invalid",
|
|
143
144
|
"aria-describedby"
|
|
144
|
-
],
|
|
145
|
+
], he = ["id"], k = /*#__PURE__*/ w(/* @__PURE__ */ o({
|
|
145
146
|
__name: "AkInput",
|
|
146
147
|
props: {
|
|
147
148
|
modelValue: { default: "" },
|
|
@@ -163,46 +164,46 @@ var h = Object.defineProperty, g = (e, t) => {
|
|
|
163
164
|
name: {}
|
|
164
165
|
},
|
|
165
166
|
emits: ["update:modelValue"],
|
|
166
|
-
setup(
|
|
167
|
-
let
|
|
168
|
-
function
|
|
167
|
+
setup(t, { emit: o }) {
|
|
168
|
+
let s = t, c = o, u = x(), d = e(() => `ak-input-${u}`), f = e(() => s.hint || s.error ? `ak-input-hint-${u}` : void 0);
|
|
169
|
+
function m(e) {
|
|
169
170
|
let t = e.target;
|
|
170
|
-
|
|
171
|
+
c("update:modelValue", t.value);
|
|
171
172
|
}
|
|
172
|
-
return (e, o) => (
|
|
173
|
-
"ak-field--disabled":
|
|
174
|
-
"ak-field--error": !!
|
|
173
|
+
return (e, o) => (p(), r("label", { class: l(["ak-field", {
|
|
174
|
+
"ak-field--disabled": t.disabled,
|
|
175
|
+
"ak-field--error": !!t.error
|
|
175
176
|
}]) }, [
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
id:
|
|
179
|
-
class:
|
|
180
|
-
type:
|
|
181
|
-
value:
|
|
182
|
-
placeholder:
|
|
183
|
-
disabled:
|
|
184
|
-
required:
|
|
185
|
-
name:
|
|
186
|
-
autocomplete:
|
|
187
|
-
"aria-invalid": !!
|
|
188
|
-
"aria-describedby":
|
|
189
|
-
onInput:
|
|
190
|
-
}, null, 42,
|
|
191
|
-
|
|
177
|
+
t.label ? (p(), r("span", fe, [a(v(t.label) + " ", 1), t.required ? (p(), r("span", pe, "*")) : n("", !0)])) : n("", !0),
|
|
178
|
+
i("input", {
|
|
179
|
+
id: d.value,
|
|
180
|
+
class: l(["ak-field__control", `ak-field__control--${t.size}`]),
|
|
181
|
+
type: t.type,
|
|
182
|
+
value: t.modelValue,
|
|
183
|
+
placeholder: t.placeholder,
|
|
184
|
+
disabled: t.disabled,
|
|
185
|
+
required: t.required,
|
|
186
|
+
name: t.name,
|
|
187
|
+
autocomplete: t.autocomplete,
|
|
188
|
+
"aria-invalid": !!t.error || void 0,
|
|
189
|
+
"aria-describedby": f.value,
|
|
190
|
+
onInput: m
|
|
191
|
+
}, null, 42, me),
|
|
192
|
+
t.error || t.hint ? (p(), r("span", {
|
|
192
193
|
key: 1,
|
|
193
|
-
id:
|
|
194
|
+
id: f.value,
|
|
194
195
|
class: "ak-field__hint"
|
|
195
|
-
},
|
|
196
|
+
}, v(t.error || t.hint), 9, he)) : n("", !0)
|
|
196
197
|
], 2));
|
|
197
198
|
}
|
|
198
|
-
}), [["__scopeId", "data-v-60d7d2d0"]]),
|
|
199
|
+
}), [["__scopeId", "data-v-60d7d2d0"]]), ge = {
|
|
199
200
|
key: 0,
|
|
200
201
|
class: "ak-field__label"
|
|
201
|
-
},
|
|
202
|
+
}, _e = {
|
|
202
203
|
key: 0,
|
|
203
204
|
class: "ak-field__required",
|
|
204
205
|
"aria-hidden": "true"
|
|
205
|
-
},
|
|
206
|
+
}, ve = [
|
|
206
207
|
"id",
|
|
207
208
|
"value",
|
|
208
209
|
"placeholder",
|
|
@@ -212,7 +213,7 @@ var h = Object.defineProperty, g = (e, t) => {
|
|
|
212
213
|
"rows",
|
|
213
214
|
"aria-invalid",
|
|
214
215
|
"aria-describedby"
|
|
215
|
-
],
|
|
216
|
+
], ye = ["id"], A = /*#__PURE__*/ w(/* @__PURE__ */ o({
|
|
216
217
|
__name: "AkTextarea",
|
|
217
218
|
props: {
|
|
218
219
|
modelValue: { default: "" },
|
|
@@ -232,68 +233,68 @@ var h = Object.defineProperty, g = (e, t) => {
|
|
|
232
233
|
name: {}
|
|
233
234
|
},
|
|
234
235
|
emits: ["update:modelValue"],
|
|
235
|
-
setup(
|
|
236
|
-
let
|
|
237
|
-
function
|
|
236
|
+
setup(t, { emit: o }) {
|
|
237
|
+
let s = t, c = o, u = x(), d = e(() => `ak-textarea-${u}`), f = e(() => s.hint || s.error ? `ak-textarea-hint-${u}` : void 0);
|
|
238
|
+
function m(e) {
|
|
238
239
|
let t = e.target;
|
|
239
|
-
|
|
240
|
+
c("update:modelValue", t.value);
|
|
240
241
|
}
|
|
241
|
-
return (e, o) => (
|
|
242
|
-
"ak-field--disabled":
|
|
243
|
-
"ak-field--error": !!
|
|
242
|
+
return (e, o) => (p(), r("label", { class: l(["ak-field", {
|
|
243
|
+
"ak-field--disabled": t.disabled,
|
|
244
|
+
"ak-field--error": !!t.error
|
|
244
245
|
}]) }, [
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
id:
|
|
246
|
+
t.label ? (p(), r("span", ge, [a(v(t.label) + " ", 1), t.required ? (p(), r("span", _e, "*")) : n("", !0)])) : n("", !0),
|
|
247
|
+
i("textarea", {
|
|
248
|
+
id: d.value,
|
|
248
249
|
class: "ak-field__control",
|
|
249
|
-
value:
|
|
250
|
-
placeholder:
|
|
251
|
-
disabled:
|
|
252
|
-
required:
|
|
253
|
-
name:
|
|
254
|
-
rows:
|
|
255
|
-
"aria-invalid": !!
|
|
256
|
-
"aria-describedby":
|
|
257
|
-
onInput:
|
|
258
|
-
}, null, 40,
|
|
259
|
-
|
|
250
|
+
value: t.modelValue,
|
|
251
|
+
placeholder: t.placeholder,
|
|
252
|
+
disabled: t.disabled,
|
|
253
|
+
required: t.required,
|
|
254
|
+
name: t.name,
|
|
255
|
+
rows: t.rows,
|
|
256
|
+
"aria-invalid": !!t.error || void 0,
|
|
257
|
+
"aria-describedby": f.value,
|
|
258
|
+
onInput: m
|
|
259
|
+
}, null, 40, ve),
|
|
260
|
+
t.error || t.hint ? (p(), r("span", {
|
|
260
261
|
key: 1,
|
|
261
|
-
id:
|
|
262
|
+
id: f.value,
|
|
262
263
|
class: "ak-field__hint"
|
|
263
|
-
},
|
|
264
|
+
}, v(t.error || t.hint), 9, ye)) : n("", !0)
|
|
264
265
|
], 2));
|
|
265
266
|
}
|
|
266
|
-
}), [["__scopeId", "data-v-d34da198"]]),
|
|
267
|
+
}), [["__scopeId", "data-v-d34da198"]]), be = { class: "ak-empty" }, j = {
|
|
267
268
|
class: "ak-empty__icon",
|
|
268
269
|
"aria-hidden": "true"
|
|
269
|
-
},
|
|
270
|
+
}, M = {
|
|
270
271
|
key: 0,
|
|
271
272
|
class: "ak-empty__glyph"
|
|
272
|
-
},
|
|
273
|
+
}, N = { class: "ak-empty__title" }, xe = {
|
|
273
274
|
key: 0,
|
|
274
275
|
class: "ak-empty__description"
|
|
275
|
-
},
|
|
276
|
+
}, Se = {
|
|
276
277
|
key: 1,
|
|
277
278
|
class: "ak-empty__action"
|
|
278
|
-
},
|
|
279
|
+
}, P = /*#__PURE__*/ w(/* @__PURE__ */ o({
|
|
279
280
|
__name: "AkEmptyState",
|
|
280
281
|
props: {
|
|
281
282
|
title: {},
|
|
282
283
|
description: {}
|
|
283
284
|
},
|
|
284
285
|
setup(e) {
|
|
285
|
-
return (
|
|
286
|
-
|
|
287
|
-
a[0] ||=
|
|
288
|
-
a[1] ||=
|
|
289
|
-
|
|
286
|
+
return (t, a) => (p(), r("div", be, [
|
|
287
|
+
i("div", j, [
|
|
288
|
+
a[0] ||= i("span", { class: "ak-empty__ring ak-empty__ring--outer" }, null, -1),
|
|
289
|
+
a[1] ||= i("span", { class: "ak-empty__ring ak-empty__ring--inner" }, null, -1),
|
|
290
|
+
t.$slots.icon ? (p(), r("span", M, [_(t.$slots, "icon", {}, void 0, !0)])) : n("", !0)
|
|
290
291
|
]),
|
|
291
|
-
|
|
292
|
-
e.description ? (
|
|
293
|
-
|
|
292
|
+
i("h3", N, v(e.title), 1),
|
|
293
|
+
e.description ? (p(), r("p", xe, v(e.description), 1)) : n("", !0),
|
|
294
|
+
t.$slots.action ? (p(), r("div", Se, [_(t.$slots, "action", {}, void 0, !0)])) : n("", !0)
|
|
294
295
|
]));
|
|
295
296
|
}
|
|
296
|
-
}), [["__scopeId", "data-v-ab81ece0"]]),
|
|
297
|
+
}), [["__scopeId", "data-v-ab81ece0"]]), F = /*#__PURE__*/ w(/* @__PURE__ */ o({
|
|
297
298
|
__name: "AkShimmer",
|
|
298
299
|
props: {
|
|
299
300
|
width: { default: "100%" },
|
|
@@ -304,9 +305,9 @@ var h = Object.defineProperty, g = (e, t) => {
|
|
|
304
305
|
function t(e) {
|
|
305
306
|
return e === "sm" || e === "md" || e === "lg" || e === "full" ? `var(--radius-${e})` : e;
|
|
306
307
|
}
|
|
307
|
-
return (
|
|
308
|
+
return (n, i) => (p(), r("div", {
|
|
308
309
|
class: "ak-shimmer",
|
|
309
|
-
style:
|
|
310
|
+
style: u({
|
|
310
311
|
width: e.width,
|
|
311
312
|
height: e.height,
|
|
312
313
|
borderRadius: t(e.radius)
|
|
@@ -314,26 +315,62 @@ var h = Object.defineProperty, g = (e, t) => {
|
|
|
314
315
|
"aria-hidden": "true"
|
|
315
316
|
}, null, 4));
|
|
316
317
|
}
|
|
317
|
-
}), [["__scopeId", "data-v-de7bd16d"]]),
|
|
318
|
+
}), [["__scopeId", "data-v-de7bd16d"]]), I = /*#__PURE__*/ w(/* @__PURE__ */ o({
|
|
318
319
|
__name: "AkAmbientBg",
|
|
319
320
|
props: { contained: {
|
|
320
321
|
type: Boolean,
|
|
321
322
|
default: !1
|
|
322
323
|
} },
|
|
323
324
|
setup(e) {
|
|
324
|
-
return (t,
|
|
325
|
-
class:
|
|
325
|
+
return (t, n) => (p(), r("div", {
|
|
326
|
+
class: l(["ambient", { "ambient--contained": e.contained }]),
|
|
326
327
|
"aria-hidden": "true"
|
|
327
|
-
}, [...
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
328
|
+
}, [...n[0] ||= [
|
|
329
|
+
i("span", { class: "ambient__orb ambient__orb--1" }, null, -1),
|
|
330
|
+
i("span", { class: "ambient__orb ambient__orb--2" }, null, -1),
|
|
331
|
+
i("span", { class: "ambient__orb ambient__orb--3" }, null, -1)
|
|
331
332
|
]], 2));
|
|
332
333
|
}
|
|
333
|
-
}), [["__scopeId", "data-v-b34dece3"]]),
|
|
334
|
+
}), [["__scopeId", "data-v-b34dece3"]]), L = new Map(S.map((e) => [e.name, Ce(e.data)]));
|
|
335
|
+
function Ce(e) {
|
|
336
|
+
let t = e.match(/<path\b[^>]*\/>/g);
|
|
337
|
+
return t?.length ? `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor">${t.map((e) => e.replace(/\sfill="[^"]*"/g, "").replace(/\s(fill-rule|clip-rule)="[^"]*"/g, "")).join("")}</svg>` : e;
|
|
338
|
+
}
|
|
339
|
+
function R(e) {
|
|
340
|
+
return L.get(e) ?? "";
|
|
341
|
+
}
|
|
342
|
+
//#endregion
|
|
343
|
+
//#region src/components/AkIcon.vue?vue&type=script&setup=true&lang.ts
|
|
344
|
+
var we = [
|
|
345
|
+
"role",
|
|
346
|
+
"aria-label",
|
|
347
|
+
"aria-hidden",
|
|
348
|
+
"innerHTML"
|
|
349
|
+
], z = /*#__PURE__*/ w(/* @__PURE__ */ o({
|
|
350
|
+
__name: "AkIcon",
|
|
351
|
+
props: {
|
|
352
|
+
name: {},
|
|
353
|
+
size: { default: 20 },
|
|
354
|
+
label: {}
|
|
355
|
+
},
|
|
356
|
+
setup(t) {
|
|
357
|
+
let n = t, i = e(() => typeof n.size == "number" ? `${n.size}px` : n.size), a = e(() => R(n.name));
|
|
358
|
+
return (e, n) => (p(), r("span", {
|
|
359
|
+
class: l(["ak-icon", { "ak-icon--missing": !a.value }]),
|
|
360
|
+
style: u({
|
|
361
|
+
width: i.value,
|
|
362
|
+
height: i.value
|
|
363
|
+
}),
|
|
364
|
+
role: t.label ? "img" : void 0,
|
|
365
|
+
"aria-label": t.label,
|
|
366
|
+
"aria-hidden": !t.label || void 0,
|
|
367
|
+
innerHTML: a.value
|
|
368
|
+
}, null, 14, we));
|
|
369
|
+
}
|
|
370
|
+
}), [["__scopeId", "data-v-083f6c55"]]), Te = ["aria-orientation"], Ee = {
|
|
334
371
|
key: 0,
|
|
335
372
|
class: "ak-divider__label"
|
|
336
|
-
},
|
|
373
|
+
}, B = /*#__PURE__*/ w(/* @__PURE__ */ o({
|
|
337
374
|
__name: "AkDivider",
|
|
338
375
|
props: {
|
|
339
376
|
spacing: { default: "md" },
|
|
@@ -344,26 +381,26 @@ var h = Object.defineProperty, g = (e, t) => {
|
|
|
344
381
|
}
|
|
345
382
|
},
|
|
346
383
|
setup(e) {
|
|
347
|
-
return (
|
|
348
|
-
class:
|
|
384
|
+
return (t, i) => (p(), r("div", {
|
|
385
|
+
class: l(["ak-divider", [e.vertical ? "ak-divider--vertical" : "ak-divider--horizontal", `ak-divider--spacing-${e.spacing}`]]),
|
|
349
386
|
role: "separator",
|
|
350
387
|
"aria-orientation": e.vertical ? "vertical" : "horizontal"
|
|
351
|
-
}, [e.label && !e.vertical ? (
|
|
388
|
+
}, [e.label && !e.vertical ? (p(), r("span", Ee, v(e.label), 1)) : n("", !0)], 10, Te));
|
|
352
389
|
}
|
|
353
|
-
}), [["__scopeId", "data-v-17bc7513"]]),
|
|
390
|
+
}), [["__scopeId", "data-v-17bc7513"]]), De = {
|
|
354
391
|
key: 0,
|
|
355
392
|
class: "ak-progress__meta"
|
|
356
|
-
},
|
|
393
|
+
}, Oe = {
|
|
357
394
|
key: 0,
|
|
358
395
|
class: "ak-progress__label"
|
|
359
|
-
},
|
|
396
|
+
}, ke = {
|
|
360
397
|
key: 1,
|
|
361
398
|
class: "ak-progress__value numeric"
|
|
362
|
-
},
|
|
399
|
+
}, Ae = [
|
|
363
400
|
"aria-valuenow",
|
|
364
401
|
"aria-valuemax",
|
|
365
402
|
"aria-label"
|
|
366
|
-
],
|
|
403
|
+
], V = /*#__PURE__*/ w(/* @__PURE__ */ o({
|
|
367
404
|
__name: "AkProgress",
|
|
368
405
|
props: {
|
|
369
406
|
value: { default: 0 },
|
|
@@ -376,74 +413,74 @@ var h = Object.defineProperty, g = (e, t) => {
|
|
|
376
413
|
default: !1
|
|
377
414
|
}
|
|
378
415
|
},
|
|
379
|
-
setup(
|
|
380
|
-
let a =
|
|
416
|
+
setup(t) {
|
|
417
|
+
let a = t, o = e(() => a.max <= 0 ? 0 : Math.min(100, Math.max(0, a.value / a.max * 100))), s = e(() => ({
|
|
381
418
|
width: `${o.value}%`,
|
|
382
419
|
...a.color ? { background: a.color } : {}
|
|
383
420
|
}));
|
|
384
|
-
return (e, a) => (
|
|
421
|
+
return (e, a) => (p(), r("div", { class: l(["ak-progress", `ak-progress--${t.size}`]) }, [t.label || t.showValue ? (p(), r("div", De, [t.label ? (p(), r("span", Oe, v(t.label), 1)) : n("", !0), t.showValue ? (p(), r("span", ke, v(Math.round(o.value)) + "%", 1)) : n("", !0)])) : n("", !0), i("div", {
|
|
385
422
|
class: "ak-progress__track",
|
|
386
423
|
role: "progressbar",
|
|
387
|
-
"aria-valuenow":
|
|
424
|
+
"aria-valuenow": t.value,
|
|
388
425
|
"aria-valuemin": 0,
|
|
389
|
-
"aria-valuemax":
|
|
390
|
-
"aria-label":
|
|
391
|
-
}, [
|
|
426
|
+
"aria-valuemax": t.max,
|
|
427
|
+
"aria-label": t.label
|
|
428
|
+
}, [i("span", {
|
|
392
429
|
class: "ak-progress__fill",
|
|
393
|
-
style:
|
|
394
|
-
}, null, 4)], 8,
|
|
430
|
+
style: u(s.value)
|
|
431
|
+
}, null, 4)], 8, Ae)], 2));
|
|
395
432
|
}
|
|
396
|
-
}), [["__scopeId", "data-v-ed0a6fcd"]]),
|
|
433
|
+
}), [["__scopeId", "data-v-ed0a6fcd"]]), je = { class: "ak-section-header" }, Me = { class: "ak-section-header__title" }, Ne = {
|
|
397
434
|
key: 0,
|
|
398
435
|
class: "ak-section-header__action"
|
|
399
|
-
},
|
|
436
|
+
}, H = /*#__PURE__*/ w(/* @__PURE__ */ o({
|
|
400
437
|
__name: "AkSectionHeader",
|
|
401
438
|
props: { title: {} },
|
|
402
439
|
setup(e) {
|
|
403
|
-
return (
|
|
440
|
+
return (t, o) => (p(), r("header", je, [i("h2", Me, [_(t.$slots, "default", {}, () => [a(v(e.title), 1)], !0)]), t.$slots.action ? (p(), r("div", Ne, [_(t.$slots, "action", {}, void 0, !0)])) : n("", !0)]));
|
|
404
441
|
}
|
|
405
|
-
}), [["__scopeId", "data-v-65fca8d1"]]),
|
|
442
|
+
}), [["__scopeId", "data-v-65fca8d1"]]), U = { class: "ak-list" }, W = /*#__PURE__*/ w(/* @__PURE__ */ o({
|
|
406
443
|
__name: "AkList",
|
|
407
444
|
setup(e) {
|
|
408
|
-
return
|
|
445
|
+
return m("ak-list", !0), (e, t) => (p(), r("ul", U, [_(e.$slots, "default", {}, void 0, !0)]));
|
|
409
446
|
}
|
|
410
|
-
}), [["__scopeId", "data-v-708bdd68"]]),
|
|
447
|
+
}), [["__scopeId", "data-v-708bdd68"]]), Pe = ["disabled"], Fe = {
|
|
411
448
|
key: 0,
|
|
412
449
|
class: "ak-list-row__leading"
|
|
413
|
-
},
|
|
450
|
+
}, Ie = { class: "ak-list-row__content" }, Le = { class: "ak-list-row__title" }, Re = {
|
|
414
451
|
key: 0,
|
|
415
452
|
class: "ak-list-row__subtitle"
|
|
416
|
-
},
|
|
453
|
+
}, ze = {
|
|
417
454
|
key: 1,
|
|
418
455
|
class: "ak-list-row__trailing"
|
|
419
|
-
},
|
|
456
|
+
}, Be = {
|
|
420
457
|
key: 0,
|
|
421
458
|
class: "ak-list-row__leading"
|
|
422
|
-
},
|
|
459
|
+
}, Ve = { class: "ak-list-row__content" }, He = { class: "ak-list-row__title" }, Ue = {
|
|
423
460
|
key: 0,
|
|
424
461
|
class: "ak-list-row__subtitle"
|
|
425
|
-
},
|
|
462
|
+
}, We = {
|
|
426
463
|
key: 1,
|
|
427
464
|
class: "ak-list-row__trailing"
|
|
428
|
-
},
|
|
465
|
+
}, Ge = ["disabled"], Ke = {
|
|
429
466
|
key: 0,
|
|
430
467
|
class: "ak-list-row__leading"
|
|
431
|
-
},
|
|
468
|
+
}, qe = { class: "ak-list-row__content" }, Je = { class: "ak-list-row__title" }, Ye = {
|
|
432
469
|
key: 0,
|
|
433
470
|
class: "ak-list-row__subtitle"
|
|
434
|
-
},
|
|
471
|
+
}, Xe = {
|
|
435
472
|
key: 1,
|
|
436
473
|
class: "ak-list-row__trailing"
|
|
437
|
-
},
|
|
474
|
+
}, Ze = {
|
|
438
475
|
key: 0,
|
|
439
476
|
class: "ak-list-row__leading"
|
|
440
|
-
},
|
|
477
|
+
}, Qe = { class: "ak-list-row__content" }, $e = { class: "ak-list-row__title" }, et = {
|
|
441
478
|
key: 0,
|
|
442
479
|
class: "ak-list-row__subtitle"
|
|
443
|
-
},
|
|
480
|
+
}, tt = {
|
|
444
481
|
key: 1,
|
|
445
482
|
class: "ak-list-row__trailing"
|
|
446
|
-
},
|
|
483
|
+
}, G = /*#__PURE__*/ w(/* @__PURE__ */ o({
|
|
447
484
|
__name: "AkListRow",
|
|
448
485
|
props: {
|
|
449
486
|
interactive: {
|
|
@@ -460,8 +497,8 @@ var h = Object.defineProperty, g = (e, t) => {
|
|
|
460
497
|
default: !0
|
|
461
498
|
}
|
|
462
499
|
},
|
|
463
|
-
setup(
|
|
464
|
-
let a =
|
|
500
|
+
setup(t) {
|
|
501
|
+
let a = t, o = s("ak-list", !1), c = e(() => [
|
|
465
502
|
"ak-list-row",
|
|
466
503
|
`ak-list-row--pad-${a.padding}`,
|
|
467
504
|
{
|
|
@@ -469,56 +506,56 @@ var h = Object.defineProperty, g = (e, t) => {
|
|
|
469
506
|
"ak-list-row--disabled": a.disabled
|
|
470
507
|
}
|
|
471
508
|
]);
|
|
472
|
-
return (e, a) =>
|
|
509
|
+
return (e, a) => b(o) ? (p(), r("li", {
|
|
473
510
|
key: 0,
|
|
474
|
-
class:
|
|
475
|
-
}, [
|
|
511
|
+
class: l(["ak-list-row-item", { "ak-list-row-item--divider": t.divider }])
|
|
512
|
+
}, [t.interactive ? (p(), r("button", {
|
|
476
513
|
key: 0,
|
|
477
514
|
type: "button",
|
|
478
|
-
class:
|
|
479
|
-
disabled:
|
|
515
|
+
class: l(c.value),
|
|
516
|
+
disabled: t.disabled
|
|
480
517
|
}, [
|
|
481
|
-
e.$slots.leading ? (
|
|
482
|
-
|
|
483
|
-
e.$slots.trailing ? (
|
|
484
|
-
], 10,
|
|
518
|
+
e.$slots.leading ? (p(), r("span", Fe, [_(e.$slots, "leading", {}, void 0, !0)])) : n("", !0),
|
|
519
|
+
i("span", Ie, [i("span", Le, [_(e.$slots, "default", {}, void 0, !0)]), e.$slots.subtitle ? (p(), r("span", Re, [_(e.$slots, "subtitle", {}, void 0, !0)])) : n("", !0)]),
|
|
520
|
+
e.$slots.trailing ? (p(), r("span", ze, [_(e.$slots, "trailing", {}, void 0, !0)])) : n("", !0)
|
|
521
|
+
], 10, Pe)) : (p(), r("div", {
|
|
485
522
|
key: 1,
|
|
486
|
-
class:
|
|
523
|
+
class: l(c.value)
|
|
487
524
|
}, [
|
|
488
|
-
e.$slots.leading ? (
|
|
489
|
-
|
|
490
|
-
e.$slots.trailing ? (
|
|
491
|
-
], 2))], 2)) :
|
|
525
|
+
e.$slots.leading ? (p(), r("span", Be, [_(e.$slots, "leading", {}, void 0, !0)])) : n("", !0),
|
|
526
|
+
i("span", Ve, [i("span", He, [_(e.$slots, "default", {}, void 0, !0)]), e.$slots.subtitle ? (p(), r("span", Ue, [_(e.$slots, "subtitle", {}, void 0, !0)])) : n("", !0)]),
|
|
527
|
+
e.$slots.trailing ? (p(), r("span", We, [_(e.$slots, "trailing", {}, void 0, !0)])) : n("", !0)
|
|
528
|
+
], 2))], 2)) : t.interactive ? (p(), r("button", {
|
|
492
529
|
key: 1,
|
|
493
530
|
type: "button",
|
|
494
|
-
class:
|
|
495
|
-
disabled:
|
|
531
|
+
class: l(c.value),
|
|
532
|
+
disabled: t.disabled
|
|
496
533
|
}, [
|
|
497
|
-
e.$slots.leading ? (
|
|
498
|
-
|
|
499
|
-
e.$slots.trailing ? (
|
|
500
|
-
], 10,
|
|
534
|
+
e.$slots.leading ? (p(), r("span", Ke, [_(e.$slots, "leading", {}, void 0, !0)])) : n("", !0),
|
|
535
|
+
i("span", qe, [i("span", Je, [_(e.$slots, "default", {}, void 0, !0)]), e.$slots.subtitle ? (p(), r("span", Ye, [_(e.$slots, "subtitle", {}, void 0, !0)])) : n("", !0)]),
|
|
536
|
+
e.$slots.trailing ? (p(), r("span", Xe, [_(e.$slots, "trailing", {}, void 0, !0)])) : n("", !0)
|
|
537
|
+
], 10, Ge)) : (p(), r("div", {
|
|
501
538
|
key: 2,
|
|
502
|
-
class:
|
|
539
|
+
class: l(c.value)
|
|
503
540
|
}, [
|
|
504
|
-
e.$slots.leading ? (
|
|
505
|
-
|
|
506
|
-
e.$slots.trailing ? (
|
|
541
|
+
e.$slots.leading ? (p(), r("span", Ze, [_(e.$slots, "leading", {}, void 0, !0)])) : n("", !0),
|
|
542
|
+
i("span", Qe, [i("span", $e, [_(e.$slots, "default", {}, void 0, !0)]), e.$slots.subtitle ? (p(), r("span", et, [_(e.$slots, "subtitle", {}, void 0, !0)])) : n("", !0)]),
|
|
543
|
+
e.$slots.trailing ? (p(), r("span", tt, [_(e.$slots, "trailing", {}, void 0, !0)])) : n("", !0)
|
|
507
544
|
], 2));
|
|
508
545
|
}
|
|
509
|
-
}), [["__scopeId", "data-v-9f8ea96f"]]),
|
|
546
|
+
}), [["__scopeId", "data-v-9f8ea96f"]]), nt = [
|
|
510
547
|
"type",
|
|
511
548
|
"disabled",
|
|
512
549
|
"aria-label",
|
|
513
550
|
"aria-busy"
|
|
514
|
-
],
|
|
551
|
+
], rt = {
|
|
515
552
|
key: 0,
|
|
516
553
|
class: "ak-icon-button__spinner",
|
|
517
554
|
"aria-hidden": "true"
|
|
518
|
-
},
|
|
555
|
+
}, it = {
|
|
519
556
|
key: 1,
|
|
520
557
|
class: "ak-icon-button__icon"
|
|
521
|
-
},
|
|
558
|
+
}, K = /*#__PURE__*/ w(/* @__PURE__ */ o({
|
|
522
559
|
__name: "AkIconButton",
|
|
523
560
|
props: {
|
|
524
561
|
variant: { default: "ghost" },
|
|
@@ -532,35 +569,45 @@ var h = Object.defineProperty, g = (e, t) => {
|
|
|
532
569
|
default: !1
|
|
533
570
|
},
|
|
534
571
|
type: { default: "button" },
|
|
535
|
-
label: {}
|
|
572
|
+
label: {},
|
|
573
|
+
icon: {}
|
|
536
574
|
},
|
|
537
|
-
setup(
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
575
|
+
setup(n) {
|
|
576
|
+
let i = n, a = e(() => ({
|
|
577
|
+
sm: 18,
|
|
578
|
+
md: 20,
|
|
579
|
+
lg: 22
|
|
580
|
+
})[i.size]);
|
|
581
|
+
return (e, i) => (p(), r("button", {
|
|
582
|
+
class: l(["ak-icon-button tap-scale", [
|
|
583
|
+
`ak-icon-button--${n.variant}`,
|
|
584
|
+
`ak-icon-button--${n.size}`,
|
|
585
|
+
{ "ak-icon-button--loading": n.loading }
|
|
543
586
|
]]),
|
|
544
|
-
type:
|
|
545
|
-
disabled:
|
|
546
|
-
"aria-label":
|
|
547
|
-
"aria-busy":
|
|
548
|
-
}, [
|
|
587
|
+
type: n.type,
|
|
588
|
+
disabled: n.disabled || n.loading,
|
|
589
|
+
"aria-label": n.label,
|
|
590
|
+
"aria-busy": n.loading || void 0
|
|
591
|
+
}, [n.loading ? (p(), r("span", rt)) : (p(), r("span", it, [n.icon ? (p(), t(z, {
|
|
592
|
+
key: 0,
|
|
593
|
+
name: n.icon,
|
|
594
|
+
size: a.value
|
|
595
|
+
}, null, 8, ["name", "size"])) : _(e.$slots, "default", {}, void 0, !0, 1)]))], 10, nt));
|
|
549
596
|
}
|
|
550
|
-
}), [["__scopeId", "data-v-
|
|
597
|
+
}), [["__scopeId", "data-v-b4833b10"]]), at = {
|
|
551
598
|
key: 0,
|
|
552
599
|
class: "ak-switch__copy"
|
|
553
|
-
},
|
|
600
|
+
}, ot = {
|
|
554
601
|
key: 0,
|
|
555
602
|
class: "ak-switch__label"
|
|
556
|
-
},
|
|
603
|
+
}, st = {
|
|
557
604
|
key: 1,
|
|
558
605
|
class: "ak-switch__description"
|
|
559
|
-
},
|
|
606
|
+
}, ct = { class: "ak-switch__control" }, lt = [
|
|
560
607
|
"id",
|
|
561
608
|
"checked",
|
|
562
609
|
"disabled"
|
|
563
|
-
],
|
|
610
|
+
], q = /*#__PURE__*/ w(/* @__PURE__ */ o({
|
|
564
611
|
__name: "AkSwitch",
|
|
565
612
|
props: {
|
|
566
613
|
modelValue: {
|
|
@@ -575,48 +622,223 @@ var h = Object.defineProperty, g = (e, t) => {
|
|
|
575
622
|
}
|
|
576
623
|
},
|
|
577
624
|
emits: ["update:modelValue"],
|
|
578
|
-
setup(
|
|
579
|
-
let o = a,
|
|
580
|
-
function
|
|
625
|
+
setup(t, { emit: a }) {
|
|
626
|
+
let o = a, s = x(), c = e(() => `ak-switch-${s}`);
|
|
627
|
+
function u(e) {
|
|
581
628
|
let t = e.target;
|
|
582
629
|
o("update:modelValue", t.checked);
|
|
583
630
|
}
|
|
584
|
-
return (e, a) => (
|
|
585
|
-
"ak-switch--disabled":
|
|
586
|
-
"ak-switch--on":
|
|
587
|
-
}]) }, [
|
|
588
|
-
id:
|
|
631
|
+
return (e, a) => (p(), r("label", { class: l(["ak-switch", {
|
|
632
|
+
"ak-switch--disabled": t.disabled,
|
|
633
|
+
"ak-switch--on": t.modelValue
|
|
634
|
+
}]) }, [t.label || t.description ? (p(), r("span", at, [t.label ? (p(), r("span", ot, v(t.label), 1)) : n("", !0), t.description ? (p(), r("span", st, v(t.description), 1)) : n("", !0)])) : n("", !0), i("span", ct, [i("input", {
|
|
635
|
+
id: c.value,
|
|
589
636
|
class: "ak-switch__input",
|
|
590
637
|
type: "checkbox",
|
|
591
638
|
role: "switch",
|
|
592
|
-
checked:
|
|
593
|
-
disabled:
|
|
594
|
-
onChange:
|
|
595
|
-
}, null, 40,
|
|
639
|
+
checked: t.modelValue,
|
|
640
|
+
disabled: t.disabled,
|
|
641
|
+
onChange: u
|
|
642
|
+
}, null, 40, lt), a[0] ||= i("span", {
|
|
596
643
|
class: "ak-switch__track",
|
|
597
644
|
"aria-hidden": "true"
|
|
598
|
-
}, [
|
|
645
|
+
}, [i("span", { class: "ak-switch__thumb" })], -1)])], 2));
|
|
646
|
+
}
|
|
647
|
+
}), [["__scopeId", "data-v-d49f3b2e"]]), J = Symbol("ak-tab-bar"), ut = {
|
|
648
|
+
class: "ak-tab-bar",
|
|
649
|
+
"aria-label": "Primary"
|
|
650
|
+
}, Y = /*#__PURE__*/ w(/* @__PURE__ */ o({
|
|
651
|
+
__name: "AkTabBar",
|
|
652
|
+
props: { modelValue: {} },
|
|
653
|
+
emits: ["update:modelValue"],
|
|
654
|
+
setup(e, { emit: t }) {
|
|
655
|
+
let n = e, a = t, o = g(null), s = h(/* @__PURE__ */ new Map()), v = g({
|
|
656
|
+
x: 0,
|
|
657
|
+
y: 0,
|
|
658
|
+
w: 0,
|
|
659
|
+
h: 0,
|
|
660
|
+
ready: !1
|
|
661
|
+
});
|
|
662
|
+
function b() {
|
|
663
|
+
let e = o.value, t = s.get(n.modelValue);
|
|
664
|
+
if (!e || !t) {
|
|
665
|
+
v.value.ready = !1;
|
|
666
|
+
return;
|
|
667
|
+
}
|
|
668
|
+
let r = e.getBoundingClientRect(), i = (t.querySelector(".ak-tab-bar__icon") ?? t).getBoundingClientRect();
|
|
669
|
+
v.value = {
|
|
670
|
+
x: i.left - r.left,
|
|
671
|
+
y: i.top - r.top,
|
|
672
|
+
w: i.width,
|
|
673
|
+
h: i.height,
|
|
674
|
+
ready: !0
|
|
675
|
+
};
|
|
676
|
+
}
|
|
677
|
+
function x(e, t) {
|
|
678
|
+
s.set(e, t), c(b);
|
|
679
|
+
}
|
|
680
|
+
function S(e) {
|
|
681
|
+
s.delete(e), c(b);
|
|
682
|
+
}
|
|
683
|
+
let C;
|
|
684
|
+
return d(() => {
|
|
685
|
+
c(b), C = new ResizeObserver(() => b()), o.value && C.observe(o.value);
|
|
686
|
+
}), f(() => C?.disconnect()), ee(() => n.modelValue, () => void c(b)), m(J, {
|
|
687
|
+
active: y(n, "modelValue"),
|
|
688
|
+
select: (e) => a("update:modelValue", e),
|
|
689
|
+
register: x,
|
|
690
|
+
unregister: S
|
|
691
|
+
}), (e, t) => (p(), r("nav", ut, [i("div", {
|
|
692
|
+
ref_key: "trackRef",
|
|
693
|
+
ref: o,
|
|
694
|
+
class: "ak-tab-bar__track",
|
|
695
|
+
role: "tablist"
|
|
696
|
+
}, [i("span", {
|
|
697
|
+
class: l(["ak-tab-bar__indicator", { "ak-tab-bar__indicator--ready": v.value.ready }]),
|
|
698
|
+
style: u({
|
|
699
|
+
transform: `translate(${v.value.x}px, ${v.value.y}px)`,
|
|
700
|
+
width: `${v.value.w}px`,
|
|
701
|
+
height: `${v.value.h}px`
|
|
702
|
+
}),
|
|
703
|
+
"aria-hidden": "true"
|
|
704
|
+
}, null, 6), _(e.$slots, "default", {}, void 0, !0)], 512)]));
|
|
599
705
|
}
|
|
600
|
-
}), [["__scopeId", "data-v-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
}
|
|
706
|
+
}), [["__scopeId", "data-v-636977ec"]]), dt = [
|
|
707
|
+
"aria-selected",
|
|
708
|
+
"aria-label",
|
|
709
|
+
"disabled"
|
|
710
|
+
], ft = {
|
|
711
|
+
class: "ak-tab-bar__icon",
|
|
712
|
+
"aria-hidden": "true"
|
|
713
|
+
}, pt = { class: "ak-tab-bar__label" }, X = /*#__PURE__*/ w(/* @__PURE__ */ o({
|
|
714
|
+
__name: "AkTabBarItem",
|
|
715
|
+
props: {
|
|
716
|
+
value: {},
|
|
717
|
+
label: {},
|
|
718
|
+
icon: {},
|
|
719
|
+
disabled: {
|
|
720
|
+
type: Boolean,
|
|
721
|
+
default: !1
|
|
722
|
+
}
|
|
723
|
+
},
|
|
724
|
+
setup(a) {
|
|
725
|
+
let o = a, c = s(J);
|
|
726
|
+
if (!c) throw Error("AkTabBarItem must be used inside AkTabBar");
|
|
727
|
+
let u = c, m = g(null), h = e(() => u.active.value === o.value);
|
|
728
|
+
d(() => {
|
|
729
|
+
m.value && u.register(o.value, m.value);
|
|
730
|
+
}), f(() => {
|
|
731
|
+
u.unregister(o.value);
|
|
732
|
+
});
|
|
733
|
+
function y() {
|
|
734
|
+
o.disabled || u.select(o.value);
|
|
735
|
+
}
|
|
736
|
+
return (e, o) => (p(), r("button", {
|
|
737
|
+
ref_key: "itemRef",
|
|
738
|
+
ref: m,
|
|
739
|
+
type: "button",
|
|
740
|
+
class: l(["ak-tab-bar__item", { "ak-tab-bar__item--active": h.value }]),
|
|
741
|
+
role: "tab",
|
|
742
|
+
"aria-selected": h.value,
|
|
743
|
+
"aria-label": a.label,
|
|
744
|
+
disabled: a.disabled,
|
|
745
|
+
onClick: y
|
|
746
|
+
}, [i("span", ft, [_(e.$slots, "icon", {}, () => [a.icon ? (p(), t(z, {
|
|
747
|
+
key: 0,
|
|
748
|
+
name: a.icon,
|
|
749
|
+
size: 20
|
|
750
|
+
}, null, 8, ["name"])) : n("", !0)], !0)]), i("span", pt, v(a.label), 1)], 10, dt));
|
|
751
|
+
}
|
|
752
|
+
}), [["__scopeId", "data-v-2a73a441"]]), mt = /* @__PURE__ */ te({
|
|
753
|
+
AkAmbientBg: () => I,
|
|
754
|
+
AkBadge: () => E,
|
|
755
|
+
AkButton: () => T,
|
|
756
|
+
AkCard: () => O,
|
|
757
|
+
AkChip: () => D,
|
|
758
|
+
AkDivider: () => B,
|
|
759
|
+
AkEmptyState: () => P,
|
|
760
|
+
AkIcon: () => z,
|
|
761
|
+
AkIconButton: () => K,
|
|
762
|
+
AkInput: () => k,
|
|
763
|
+
AkList: () => W,
|
|
764
|
+
AkListRow: () => G,
|
|
765
|
+
AkProgress: () => V,
|
|
766
|
+
AkSectionHeader: () => H,
|
|
767
|
+
AkShimmer: () => F,
|
|
768
|
+
AkSwitch: () => q,
|
|
769
|
+
AkTabBar: () => Y,
|
|
770
|
+
AkTabBarItem: () => X,
|
|
771
|
+
AkTextarea: () => A
|
|
772
|
+
}), ht = { install(e, t = {}) {
|
|
618
773
|
let n = t.prefix ?? "";
|
|
619
|
-
for (let [t, r] of Object.entries(
|
|
620
|
-
} }
|
|
774
|
+
for (let [t, r] of Object.entries(mt)) e.component(`${n}${t}`, r);
|
|
775
|
+
} }, Z = {
|
|
776
|
+
violet: {
|
|
777
|
+
label: "Violet",
|
|
778
|
+
description: "Mineral violet — default for App mood.",
|
|
779
|
+
sample: "#6658b8",
|
|
780
|
+
light: "#8578c9",
|
|
781
|
+
dark: "#4f4299"
|
|
782
|
+
},
|
|
783
|
+
evergreen: {
|
|
784
|
+
label: "Evergreen",
|
|
785
|
+
description: "Confident green — default for Site mood.",
|
|
786
|
+
sample: "#2e684f",
|
|
787
|
+
light: "#3f8566",
|
|
788
|
+
dark: "#1f4a37"
|
|
789
|
+
},
|
|
790
|
+
teal: {
|
|
791
|
+
label: "Teal",
|
|
792
|
+
description: "Calm mineral teal for productivity and wellness apps.",
|
|
793
|
+
sample: "#3a7d85",
|
|
794
|
+
light: "#4f96a0",
|
|
795
|
+
dark: "#2a5f66"
|
|
796
|
+
},
|
|
797
|
+
ocean: {
|
|
798
|
+
label: "Ocean",
|
|
799
|
+
description: "Trustworthy blue for data-heavy products.",
|
|
800
|
+
sample: "#3d6a94",
|
|
801
|
+
light: "#5584ad",
|
|
802
|
+
dark: "#2d5174"
|
|
803
|
+
},
|
|
804
|
+
amber: {
|
|
805
|
+
label: "Amber",
|
|
806
|
+
description: "Warm gold for optimistic, human interfaces.",
|
|
807
|
+
sample: "#9a702d",
|
|
808
|
+
light: "#b8893f",
|
|
809
|
+
dark: "#7a5720"
|
|
810
|
+
},
|
|
811
|
+
rose: {
|
|
812
|
+
label: "Rose",
|
|
813
|
+
description: "Dusty rose for lifestyle and creative tools.",
|
|
814
|
+
sample: "#a8586a",
|
|
815
|
+
light: "#c07082",
|
|
816
|
+
dark: "#8a4556"
|
|
817
|
+
},
|
|
818
|
+
coral: {
|
|
819
|
+
label: "Coral",
|
|
820
|
+
description: "Terracotta warmth without feeling playful.",
|
|
821
|
+
sample: "#b5644a",
|
|
822
|
+
light: "#cd7d62",
|
|
823
|
+
dark: "#944f39"
|
|
824
|
+
},
|
|
825
|
+
slate: {
|
|
826
|
+
label: "Slate",
|
|
827
|
+
description: "Blue-gray for neutral B2B surfaces.",
|
|
828
|
+
sample: "#4a5d73",
|
|
829
|
+
light: "#627890",
|
|
830
|
+
dark: "#384858"
|
|
831
|
+
}
|
|
832
|
+
}, gt = Object.keys(Z), Q = "violet", $ = "evergreen";
|
|
833
|
+
function _t(e, t) {
|
|
834
|
+
if (t === "auto") {
|
|
835
|
+
delete e.dataset.accent;
|
|
836
|
+
return;
|
|
837
|
+
}
|
|
838
|
+
e.dataset.accent = t;
|
|
839
|
+
}
|
|
840
|
+
function vt(e, t) {
|
|
841
|
+
return t || (e === "site" ? $ : Q);
|
|
842
|
+
}
|
|
621
843
|
//#endregion
|
|
622
|
-
export {
|
|
844
|
+
export { I as AkAmbientBg, E as AkBadge, T as AkButton, O as AkCard, D as AkChip, B as AkDivider, P as AkEmptyState, z as AkIcon, K as AkIconButton, k as AkInput, W as AkList, G as AkListRow, V as AkProgress, H as AkSectionHeader, F as AkShimmer, q as AkSwitch, Y as AkTabBar, X as AkTabBarItem, A as AkTextarea, ht as Akoma, gt as accentPaletteIds, Z as accentPalettes, Q as appDefaultAccent, _t as applyAccentPalette, L as cuidaIconMap, R as getCuidaIconMarkup, vt as resolveAccentPalette, $ as siteDefaultAccent };
|