@ac-design/design-system 2.4.5 → 2.5.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/dist/lib/compat.css +18 -0
- package/dist/lib/components/AcCopyButton.vue.d.ts +1 -1
- package/dist/lib/components/AcCopyButton.vue_vue_type_script_setup_true_lang.js +40 -40
- package/dist/lib/components/AcNavbar.vue_vue_type_script_setup_true_lang.js +25 -24
- package/dist/lib/components/AcProductTag.js +5 -0
- package/dist/lib/components/AcProductTag.vue.d.ts +7 -0
- package/dist/lib/components/AcProductTag.vue_vue_type_script_setup_true_lang.js +15 -0
- package/dist/lib/components/AcSidebarBrand.js +5 -0
- package/dist/lib/components/AcSidebarBrand.vue.d.ts +27 -0
- package/dist/lib/components/AcSidebarBrand.vue_vue_type_script_setup_true_lang.js +76 -0
- package/dist/lib/components/index.d.ts +2 -0
- package/dist/lib/index.js +45 -43
- package/package.json +1 -1
package/dist/lib/compat.css
CHANGED
|
@@ -1260,6 +1260,12 @@ button:is([data-ac-ds], [data-ac-ds] *), input:where([type="button"], [type="res
|
|
|
1260
1260
|
.max-w-250:where([data-ac-ds], [data-ac-ds] *) {
|
|
1261
1261
|
max-width: calc(var(--spacing) * 250) !important;
|
|
1262
1262
|
}
|
|
1263
|
+
.max-w-\[135px\]:where([data-ac-ds], [data-ac-ds] *) {
|
|
1264
|
+
max-width: 135px !important;
|
|
1265
|
+
}
|
|
1266
|
+
.max-w-\[146px\]:where([data-ac-ds], [data-ac-ds] *) {
|
|
1267
|
+
max-width: 146px !important;
|
|
1268
|
+
}
|
|
1263
1269
|
.max-w-\[280px\]:where([data-ac-ds], [data-ac-ds] *) {
|
|
1264
1270
|
max-width: 280px !important;
|
|
1265
1271
|
}
|
|
@@ -1356,6 +1362,9 @@ button:is([data-ac-ds], [data-ac-ds] *), input:where([type="button"], [type="res
|
|
|
1356
1362
|
.grow:where([data-ac-ds], [data-ac-ds] *) {
|
|
1357
1363
|
flex-grow: 1 !important;
|
|
1358
1364
|
}
|
|
1365
|
+
.basis-\[80px\]:where([data-ac-ds], [data-ac-ds] *) {
|
|
1366
|
+
flex-basis: 80px !important;
|
|
1367
|
+
}
|
|
1359
1368
|
.basis-\[240px\]:where([data-ac-ds], [data-ac-ds] *) {
|
|
1360
1369
|
flex-basis: 240px !important;
|
|
1361
1370
|
}
|
|
@@ -2905,6 +2914,9 @@ button:is([data-ac-ds], [data-ac-ds] *), input:where([type="button"], [type="res
|
|
|
2905
2914
|
.object-cover:where([data-ac-ds], [data-ac-ds] *) {
|
|
2906
2915
|
object-fit: cover !important;
|
|
2907
2916
|
}
|
|
2917
|
+
.object-left:where([data-ac-ds], [data-ac-ds] *) {
|
|
2918
|
+
object-position: left !important;
|
|
2919
|
+
}
|
|
2908
2920
|
.p-0:where([data-ac-ds], [data-ac-ds] *) {
|
|
2909
2921
|
padding: 0px !important;
|
|
2910
2922
|
}
|
|
@@ -5763,6 +5775,12 @@ button:is([data-ac-ds], [data-ac-ds] *), input:where([type="button"], [type="res
|
|
|
5763
5775
|
width: calc(var(--spacing) * 4) !important;
|
|
5764
5776
|
height: calc(var(--spacing) * 4) !important;
|
|
5765
5777
|
}
|
|
5778
|
+
.\[\&\>svg\]\:h-auto > svg:where([data-ac-ds], [data-ac-ds] *) {
|
|
5779
|
+
height: auto !important;
|
|
5780
|
+
}
|
|
5781
|
+
.\[\&\>svg\]\:w-full > svg:where([data-ac-ds], [data-ac-ds] *) {
|
|
5782
|
+
width: 100% !important;
|
|
5783
|
+
}
|
|
5766
5784
|
.\[\&\>svg\]\:shrink-0 > svg:where([data-ac-ds], [data-ac-ds] *) {
|
|
5767
5785
|
flex-shrink: 0 !important;
|
|
5768
5786
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
export interface Props {
|
|
2
2
|
/** The text copied to the clipboard, e.g. a cluster ID, IP address or endpoint. */
|
|
3
3
|
value: string;
|
|
4
|
-
/** What the value is, in lower case: "cluster ID", "public IP".
|
|
4
|
+
/** What the value is, in lower case: "cluster ID", "public IP". The tooltip and screen readers say "Copy cluster ID", then "Copied cluster ID". Without it they say "Copy" and "Copied". */
|
|
5
5
|
label?: string;
|
|
6
6
|
/** Text shown instead of `value`, e.g. the first 8 characters of a UUID. The tooltip shows the full value. */
|
|
7
7
|
display?: string;
|
|
@@ -3,15 +3,15 @@ import { copyText as t } from "../composables/copyText.js";
|
|
|
3
3
|
import { Fragment as n, computed as r, createBlock as i, createCommentVNode as a, createElementBlock as o, createElementVNode as s, createTextVNode as c, createVNode as l, defineComponent as u, mergeProps as d, nextTick as f, normalizeClass as p, onBeforeUnmount as m, openBlock as h, ref as g, renderSlot as _, toDisplayString as v, unref as y, useAttrs as b, withCtx as x, withModifiers as S } from "vue";
|
|
4
4
|
import { Check as C, Copy as w } from "@lucide/vue";
|
|
5
5
|
//#region src/lib/components/AcCopyButton.vue?vue&type=script&setup=true&lang.ts
|
|
6
|
-
var T = ["aria-label"], E = { class: "sr-only" }, D = { class: "block font-mono break-all" }, O = {
|
|
6
|
+
var T = ["aria-label"], E = { class: "sr-only" }, D = { class: "block font-mono break-all" }, O = { class: "block text-on-tooltip/70" }, k = {
|
|
7
7
|
class: "sr-only",
|
|
8
8
|
role: "status"
|
|
9
|
-
},
|
|
9
|
+
}, A = 1500, j = /*@__PURE__*/ u({
|
|
10
10
|
inheritAttrs: !1,
|
|
11
11
|
__name: "AcCopyButton",
|
|
12
12
|
props: {
|
|
13
13
|
value: {},
|
|
14
|
-
label: { default: "
|
|
14
|
+
label: { default: "" },
|
|
15
15
|
display: { default: "" },
|
|
16
16
|
mono: {
|
|
17
17
|
type: Boolean,
|
|
@@ -25,68 +25,68 @@ var T = ["aria-label"], E = { class: "sr-only" }, D = { class: "block font-mono
|
|
|
25
25
|
variant: { default: "plain" }
|
|
26
26
|
},
|
|
27
27
|
emits: ["copy"],
|
|
28
|
-
setup(u, { expose:
|
|
29
|
-
let
|
|
30
|
-
class:
|
|
31
|
-
style:
|
|
32
|
-
})),
|
|
33
|
-
let { class: e, style: t, ...n } =
|
|
28
|
+
setup(u, { expose: j, emit: M }) {
|
|
29
|
+
let N = u, P = M, F = b(), I = g(null), L = g(null), R = g("idle"), z = g(!1), B, V = r(() => ({
|
|
30
|
+
class: F.class,
|
|
31
|
+
style: F.style
|
|
32
|
+
})), H = r(() => {
|
|
33
|
+
let { class: e, style: t, ...n } = F;
|
|
34
34
|
return n;
|
|
35
|
-
}),
|
|
36
|
-
function
|
|
37
|
-
let e =
|
|
38
|
-
|
|
35
|
+
}), U = r(() => N.display || N.value), W = r(() => N.label ? ` ${N.label}` : ""), G = r(() => N.label || "value"), K = r(() => !N.iconOnly && (z.value || !!N.display && N.display !== N.value)), q = r(() => N.iconOnly ? N.size === "small" ? "size-6 justify-center rounded-6" : "size-7 justify-center rounded-8" : N.variant === "chip" ? N.size === "small" ? "gap-1.5 rounded-8 px-2 py-0.5 text-xs" : "gap-1.5 rounded-8 px-2.5 py-1 text-base" : N.size === "small" ? "gap-1 rounded-4 text-xs" : N.size === "normal" ? "gap-1.5 rounded-6 text-base" : "gap-1 rounded-4"), J = r(() => N.iconOnly ? "text-muted hover:bg-surface-sunken hover:text-heading" : N.variant === "chip" ? "border border-border bg-surface-sunken/50 text-muted hover:border-border-dark hover:text-heading" : N.size ? "text-heading" : ""), Y = r(() => N.iconOnly && N.size !== "small" ? "size-4" : "size-3.5"), X = r(() => N.iconOnly ? "" : N.variant === "chip" ? "text-muted opacity-60 group-hover:opacity-100 group-focus-visible:opacity-100" : "text-muted opacity-0 group-hover:opacity-100 group-focus-visible:opacity-100 pointer-coarse:opacity-100");
|
|
36
|
+
function Z() {
|
|
37
|
+
let e = L.value;
|
|
38
|
+
z.value = !!e && e.scrollWidth > e.clientWidth + 1;
|
|
39
39
|
}
|
|
40
|
-
async function
|
|
41
|
-
clearTimeout(
|
|
40
|
+
async function Q() {
|
|
41
|
+
clearTimeout(B);
|
|
42
42
|
try {
|
|
43
|
-
await t(
|
|
43
|
+
await t(N.value), R.value = "copied", P("copy", N.value);
|
|
44
44
|
} catch {
|
|
45
|
-
|
|
45
|
+
R.value = "failed";
|
|
46
46
|
}
|
|
47
|
-
|
|
47
|
+
B = setTimeout(() => R.value = "idle", A), await f(), $();
|
|
48
48
|
}
|
|
49
|
-
function
|
|
50
|
-
let e =
|
|
51
|
-
e &&
|
|
49
|
+
function $() {
|
|
50
|
+
let e = I.value?.closest("[data-testid=\"ac-tooltip\"]");
|
|
51
|
+
e && I.value?.matches(":hover") && e.dispatchEvent(new PointerEvent("pointerenter", { pointerType: "mouse" }));
|
|
52
52
|
}
|
|
53
|
-
function
|
|
54
|
-
|
|
53
|
+
function ee() {
|
|
54
|
+
I.value?.focus();
|
|
55
55
|
}
|
|
56
|
-
return m(() => clearTimeout(
|
|
56
|
+
return m(() => clearTimeout(B)), j({ focus: ee }), (t, r) => (h(), o("span", d({ class: "inline-flex max-w-full min-w-0 align-middle" }, V.value, {
|
|
57
57
|
"data-ac-ds": "",
|
|
58
58
|
"data-testid": "ac-copy-button"
|
|
59
59
|
}), [l(e, {
|
|
60
60
|
class: "min-w-0 flex-auto",
|
|
61
|
-
delay:
|
|
61
|
+
delay: R.value === "idle" ? 300 : 0
|
|
62
62
|
}, {
|
|
63
|
-
content: x(() => [
|
|
63
|
+
content: x(() => [R.value === "copied" ? (h(), o(n, { key: 0 }, [c("Copied" + v(W.value), 1)], 64)) : R.value === "failed" ? (h(), o(n, { key: 1 }, [c("Couldn't copy" + v(W.value) + ". The browser blocked the clipboard.", 1)], 64)) : K.value ? (h(), o(n, { key: 2 }, [s("span", D, v(u.value), 1), s("span", O, "Click to copy" + v(W.value), 1)], 64)) : (h(), o(n, { key: 3 }, [c("Copy" + v(W.value), 1)], 64))]),
|
|
64
64
|
default: x(() => [s("button", d({
|
|
65
65
|
ref_key: "button",
|
|
66
|
-
ref:
|
|
66
|
+
ref: I,
|
|
67
67
|
type: "button",
|
|
68
|
-
class: ["group inline-flex max-w-full min-w-0 flex-auto cursor-pointer items-center text-left transition-[color,background-color,border-color] duration-200 focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-surface focus-visible:outline-none", [
|
|
69
|
-
"aria-label": u.iconOnly ? `Copy ${
|
|
70
|
-
},
|
|
71
|
-
onClick: S(
|
|
72
|
-
onPointerenter:
|
|
73
|
-
onFocus:
|
|
74
|
-
}), [u.iconOnly ? a("", !0) : (h(), o(n, { key: 0 }, [s("span", E, v(`Copy ${
|
|
68
|
+
class: ["group inline-flex max-w-full min-w-0 flex-auto cursor-pointer items-center text-left transition-[color,background-color,border-color] duration-200 focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-surface focus-visible:outline-none", [q.value, J.value]],
|
|
69
|
+
"aria-label": u.iconOnly ? `Copy ${G.value}` : void 0
|
|
70
|
+
}, H.value, {
|
|
71
|
+
onClick: S(Q, ["stop"]),
|
|
72
|
+
onPointerenter: Z,
|
|
73
|
+
onFocus: Z
|
|
74
|
+
}), [u.iconOnly ? a("", !0) : (h(), o(n, { key: 0 }, [s("span", E, v(`Copy ${G.value}: `), 1), s("span", {
|
|
75
75
|
ref_key: "text",
|
|
76
|
-
ref:
|
|
76
|
+
ref: L,
|
|
77
77
|
class: p(["min-w-0 truncate", u.mono && "font-mono"])
|
|
78
|
-
}, [_(t.$slots, "default", {}, () => [c(v(
|
|
78
|
+
}, [_(t.$slots, "default", {}, () => [c(v(U.value), 1)])], 2)], 64)), R.value === "copied" ? (h(), i(y(C), {
|
|
79
79
|
key: 1,
|
|
80
|
-
class: p(["shrink-0 text-primary",
|
|
80
|
+
class: p(["shrink-0 text-primary", Y.value]),
|
|
81
81
|
"aria-hidden": "true"
|
|
82
82
|
}, null, 8, ["class"])) : (h(), i(y(w), {
|
|
83
83
|
key: 2,
|
|
84
|
-
class: p(["shrink-0 transition-opacity duration-200", [
|
|
84
|
+
class: p(["shrink-0 transition-opacity duration-200", [Y.value, X.value]]),
|
|
85
85
|
"aria-hidden": "true"
|
|
86
86
|
}, null, 8, ["class"]))], 16, T)]),
|
|
87
87
|
_: 3
|
|
88
|
-
}, 8, ["delay"]), s("span",
|
|
88
|
+
}, 8, ["delay"]), s("span", k, v(R.value === "copied" ? `Copied ${G.value}` : R.value === "failed" ? `Couldn't copy ${G.value}` : ""), 1)], 16));
|
|
89
89
|
}
|
|
90
90
|
});
|
|
91
91
|
//#endregion
|
|
92
|
-
export {
|
|
92
|
+
export { j as default };
|
|
@@ -1,12 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
1
|
+
import e from "./AcProductTag.js";
|
|
2
|
+
import { createBlock as t, createCommentVNode as n, createElementBlock as r, createVNode as i, defineComponent as a, normalizeClass as o, openBlock as s, renderSlot as c, unref as l } from "vue";
|
|
3
|
+
import { Menu as u } from "@lucide/vue";
|
|
3
4
|
//#region src/lib/components/AcNavbar.vue?vue&type=script&setup=true&lang.ts
|
|
4
|
-
var
|
|
5
|
+
var d = ["aria-label"], f = {
|
|
5
6
|
key: 1,
|
|
6
7
|
class: "flex shrink-0 items-center gap-2"
|
|
7
|
-
}, f = {
|
|
8
|
-
key: 0,
|
|
9
|
-
class: "inline-flex items-center rounded-6 border border-primary/25 bg-primary/10 px-1.5 py-0.5 text-sm font-semibold tracking-wide text-primary-strong uppercase"
|
|
10
8
|
}, p = ["aria-label"], m = {
|
|
11
9
|
key: 3,
|
|
12
10
|
class: "hidden min-w-0 shrink sm:block sm:w-48 md:w-60 lg:w-80 xl:w-96"
|
|
@@ -22,7 +20,7 @@ var u = ["aria-label"], d = {
|
|
|
22
20
|
}, v = {
|
|
23
21
|
key: 6,
|
|
24
22
|
class: "flex shrink-0 items-center gap-0.5 sm:gap-3"
|
|
25
|
-
}, y = /*@__PURE__*/
|
|
23
|
+
}, y = /*@__PURE__*/ a({
|
|
26
24
|
__name: "AcNavbar",
|
|
27
25
|
props: {
|
|
28
26
|
menuButton: { default: "mobile" },
|
|
@@ -36,37 +34,40 @@ var u = ["aria-label"], d = {
|
|
|
36
34
|
searchPosition: { default: "start" }
|
|
37
35
|
},
|
|
38
36
|
emits: ["menu"],
|
|
39
|
-
setup(
|
|
37
|
+
setup(a, { emit: y }) {
|
|
40
38
|
let b = y;
|
|
41
|
-
return (y, x) => (
|
|
42
|
-
class:
|
|
39
|
+
return (y, x) => (s(), r("header", {
|
|
40
|
+
class: o(["top-0 z-30 flex h-18 shrink-0 items-center gap-2 border-b border-border/80 bg-surface/90 px-4 backdrop-blur-sm sm:gap-4 sm:px-6", a.sticky && "sticky"]),
|
|
43
41
|
"data-ac-ds": "",
|
|
44
42
|
"data-testid": "ac-navbar"
|
|
45
43
|
}, [
|
|
46
|
-
|
|
44
|
+
a.menuButton === "never" ? n("", !0) : (s(), r("button", {
|
|
47
45
|
key: 0,
|
|
48
46
|
type: "button",
|
|
49
|
-
class:
|
|
50
|
-
"md:hidden":
|
|
51
|
-
"lg:hidden":
|
|
47
|
+
class: o(["inline-flex size-9.5 shrink-0 cursor-pointer items-center justify-center rounded-10 border border-transparent text-muted transition-colors duration-200 hover:border-border hover:bg-surface-sunken/50 hover:text-heading focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-surface focus-visible:outline-none", {
|
|
48
|
+
"md:hidden": a.menuButton === "mobile",
|
|
49
|
+
"lg:hidden": a.menuButton === "tablet"
|
|
52
50
|
}]),
|
|
53
|
-
"aria-label":
|
|
51
|
+
"aria-label": a.menuLabel,
|
|
54
52
|
"data-ac-ds": "",
|
|
55
53
|
"data-testid": "ac-navbar-menu",
|
|
56
54
|
onClick: x[0] ||= (e) => b("menu")
|
|
57
|
-
}, [
|
|
55
|
+
}, [i(l(u), {
|
|
58
56
|
class: "size-5",
|
|
59
57
|
"aria-hidden": "true"
|
|
60
|
-
})], 10,
|
|
61
|
-
y.$slots.brand ||
|
|
62
|
-
|
|
58
|
+
})], 10, d)),
|
|
59
|
+
y.$slots.brand || a.productName ? (s(), r("div", f, [c(y.$slots, "brand"), a.productName ? (s(), t(e, {
|
|
60
|
+
key: 0,
|
|
61
|
+
label: a.productName
|
|
62
|
+
}, null, 8, ["label"])) : n("", !0)])) : n("", !0),
|
|
63
|
+
y.$slots.default ? (s(), r("nav", {
|
|
63
64
|
key: 2,
|
|
64
|
-
"aria-label":
|
|
65
|
+
"aria-label": a.label,
|
|
65
66
|
class: "hidden items-center gap-1 md:flex"
|
|
66
|
-
}, [
|
|
67
|
-
y.$slots.search &&
|
|
68
|
-
y.$slots.start ? (
|
|
69
|
-
y.$slots.actions ? (
|
|
67
|
+
}, [c(y.$slots, "default")], 8, p)) : n("", !0),
|
|
68
|
+
y.$slots.search && a.searchPosition === "start" ? (s(), r("div", m, [c(y.$slots, "search")])) : n("", !0),
|
|
69
|
+
y.$slots.start ? (s(), r("div", h, [c(y.$slots, "start")])) : (s(), r("div", g, [y.$slots.search && a.searchPosition === "center" ? (s(), r("div", _, [c(y.$slots, "search")])) : n("", !0)])),
|
|
70
|
+
y.$slots.actions ? (s(), r("div", v, [c(y.$slots, "actions")])) : n("", !0)
|
|
70
71
|
], 2));
|
|
71
72
|
}
|
|
72
73
|
});
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export interface Props {
|
|
2
|
+
/** The product's short name, shown in capitals, e.g. `"Console"`, `"DB"` or `"Billing"`. */
|
|
3
|
+
label: string;
|
|
4
|
+
}
|
|
5
|
+
declare const __VLS_export: import("vue").DefineComponent<Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
6
|
+
declare const _default: typeof __VLS_export;
|
|
7
|
+
export default _default;
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { createElementBlock as e, defineComponent as t, openBlock as n, toDisplayString as r } from "vue";
|
|
2
|
+
//#region src/lib/components/AcProductTag.vue?vue&type=script&setup=true&lang.ts
|
|
3
|
+
var i = {
|
|
4
|
+
class: "inline-flex h-5 shrink-0 items-center rounded-6 border border-primary/25 bg-primary/10 px-1.5 text-sm leading-none font-semibold tracking-wide whitespace-nowrap text-primary-strong uppercase",
|
|
5
|
+
"data-ac-ds": "",
|
|
6
|
+
"data-testid": "ac-product-tag"
|
|
7
|
+
}, a = /*@__PURE__*/ t({
|
|
8
|
+
__name: "AcProductTag",
|
|
9
|
+
props: { label: {} },
|
|
10
|
+
setup(t) {
|
|
11
|
+
return (a, o) => (n(), e("span", i, r(t.label), 1));
|
|
12
|
+
}
|
|
13
|
+
});
|
|
14
|
+
//#endregion
|
|
15
|
+
export { a as default };
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
export interface Props {
|
|
2
|
+
/** Short product tag after the logo, e.g. `"Console"`, `"DB"` or `"Billing"`. Empty hides it; the collapsed rail never shows it. */
|
|
3
|
+
productName?: string;
|
|
4
|
+
/** Image URL of a custom (white-label) logo. Empty draws the AppsCode logo. */
|
|
5
|
+
logo?: string;
|
|
6
|
+
/** Image URL of a square mark for the collapsed rail. Empty draws the AppsCode mark. */
|
|
7
|
+
mark?: string;
|
|
8
|
+
/** Shows only the mark, for the 56px rail. Pass the sidebar header slot's `collapsed`. */
|
|
9
|
+
collapsed?: boolean;
|
|
10
|
+
/** Route for `RouterLink` (needs vue-router in the app). */
|
|
11
|
+
to?: string | Record<string, unknown>;
|
|
12
|
+
/** Plain link, when there's no router. */
|
|
13
|
+
href?: string;
|
|
14
|
+
/** Accessible name of the link. */
|
|
15
|
+
label?: string;
|
|
16
|
+
}
|
|
17
|
+
declare const __VLS_export: import("vue").DefineComponent<Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<Props> & Readonly<{}>, {
|
|
18
|
+
label: string;
|
|
19
|
+
mark: string;
|
|
20
|
+
href: string;
|
|
21
|
+
to: string | Record<string, unknown>;
|
|
22
|
+
logo: string;
|
|
23
|
+
collapsed: boolean;
|
|
24
|
+
productName: string;
|
|
25
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
26
|
+
declare const _default: typeof __VLS_export;
|
|
27
|
+
export default _default;
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
import e from "./AcLogo.js";
|
|
2
|
+
import t from "./AcProductTag.js";
|
|
3
|
+
import { Fragment as n, computed as r, createBlock as i, createCommentVNode as a, createElementBlock as o, createVNode as s, defineComponent as c, getCurrentInstance as l, mergeProps as u, openBlock as d, resolveDynamicComponent as f, withCtx as p } from "vue";
|
|
4
|
+
//#region src/lib/components/AcSidebarBrand.vue?vue&type=script&setup=true&lang.ts
|
|
5
|
+
var m = {
|
|
6
|
+
class: "min-w-0 flex-1",
|
|
7
|
+
"data-ac-ds": "",
|
|
8
|
+
"data-testid": "ac-sidebar-brand"
|
|
9
|
+
}, h = ["src"], g = ["src"], _ = {
|
|
10
|
+
key: 1,
|
|
11
|
+
class: "flex max-w-[135px] min-w-0 grow basis-[80px] [&>svg]:h-auto [&>svg]:w-full"
|
|
12
|
+
}, v = /*@__PURE__*/ c({
|
|
13
|
+
__name: "AcSidebarBrand",
|
|
14
|
+
props: {
|
|
15
|
+
productName: { default: "" },
|
|
16
|
+
logo: { default: "" },
|
|
17
|
+
mark: { default: "" },
|
|
18
|
+
collapsed: {
|
|
19
|
+
type: Boolean,
|
|
20
|
+
default: !1
|
|
21
|
+
},
|
|
22
|
+
to: { default: void 0 },
|
|
23
|
+
href: { default: void 0 },
|
|
24
|
+
label: { default: "Home" }
|
|
25
|
+
},
|
|
26
|
+
setup(c) {
|
|
27
|
+
let v = c, y = l()?.appContext.components.RouterLink, b = r(() => {
|
|
28
|
+
if (v.to !== void 0 && y) return {
|
|
29
|
+
is: y,
|
|
30
|
+
attrs: {
|
|
31
|
+
to: v.to,
|
|
32
|
+
"aria-label": v.label
|
|
33
|
+
}
|
|
34
|
+
};
|
|
35
|
+
let e = v.href ?? (typeof v.to == "string" ? v.to : void 0);
|
|
36
|
+
return e ? {
|
|
37
|
+
is: "a",
|
|
38
|
+
attrs: {
|
|
39
|
+
href: e,
|
|
40
|
+
"aria-label": v.label
|
|
41
|
+
}
|
|
42
|
+
} : {
|
|
43
|
+
is: "div",
|
|
44
|
+
attrs: {}
|
|
45
|
+
};
|
|
46
|
+
}), x = r(() => b.value.is === "div" ? "AppsCode" : "");
|
|
47
|
+
return (r, l) => (d(), o("div", m, [(d(), i(f(b.value.is), u(b.value.attrs, { class: "flex w-fit max-w-full min-w-0 flex-wrap items-center gap-x-2 gap-y-1.5 rounded-8 no-underline focus-visible:ring-2 focus-visible:ring-ring focus-visible:outline-none" }), {
|
|
48
|
+
default: p(() => [c.collapsed ? (d(), o(n, { key: 0 }, [c.mark ? (d(), o("img", {
|
|
49
|
+
key: 0,
|
|
50
|
+
src: c.mark,
|
|
51
|
+
alt: "",
|
|
52
|
+
class: "size-7 rounded-6 object-contain"
|
|
53
|
+
}, null, 8, h)) : (d(), i(e, {
|
|
54
|
+
key: 1,
|
|
55
|
+
variant: "mark",
|
|
56
|
+
size: 28,
|
|
57
|
+
label: x.value
|
|
58
|
+
}, null, 8, ["label"]))], 64)) : (d(), o(n, { key: 1 }, [c.logo ? (d(), o("img", {
|
|
59
|
+
key: 0,
|
|
60
|
+
src: c.logo,
|
|
61
|
+
alt: "",
|
|
62
|
+
class: "block h-8 max-w-[146px] min-w-0 object-contain object-left",
|
|
63
|
+
"data-testid": "ac-sidebar-brand-logo"
|
|
64
|
+
}, null, 8, g)) : (d(), o("span", _, [s(e, {
|
|
65
|
+
size: 28,
|
|
66
|
+
label: x.value
|
|
67
|
+
}, null, 8, ["label"])])), c.productName ? (d(), i(t, {
|
|
68
|
+
key: 2,
|
|
69
|
+
label: c.productName
|
|
70
|
+
}, null, 8, ["label"])) : a("", !0)], 64))]),
|
|
71
|
+
_: 1
|
|
72
|
+
}, 16))]));
|
|
73
|
+
}
|
|
74
|
+
});
|
|
75
|
+
//#endregion
|
|
76
|
+
export { v as default };
|
|
@@ -61,6 +61,7 @@ export { default as AcPagination } from "./AcPagination.vue";
|
|
|
61
61
|
export { default as AcPreloader } from "./AcPreloader.vue";
|
|
62
62
|
export { default as AcProgress } from "./AcProgress.vue";
|
|
63
63
|
export { default as AcProductHero } from "./AcProductHero.vue";
|
|
64
|
+
export { default as AcProductTag } from "./AcProductTag.vue";
|
|
64
65
|
export { default as AcRadioCard } from "./AcRadioCard.vue";
|
|
65
66
|
export { default as AcResourceCard } from "./AcResourceCard.vue";
|
|
66
67
|
export { default as AcSearchBar } from "./AcSearchBar.vue";
|
|
@@ -69,6 +70,7 @@ export { default as AcSegmentedControl } from "./AcSegmentedControl.vue";
|
|
|
69
70
|
export { default as AcSettingsRow } from "./AcSettingsRow.vue";
|
|
70
71
|
export { default as AcSelect } from "./AcSelect.vue";
|
|
71
72
|
export { default as AcSidebar } from "./AcSidebar.vue";
|
|
73
|
+
export { default as AcSidebarBrand } from "./AcSidebarBrand.vue";
|
|
72
74
|
export { default as AcSidebarItem } from "./AcSidebarItem.vue";
|
|
73
75
|
export { default as AcSidebarSection } from "./AcSidebarSection.vue";
|
|
74
76
|
export { default as AcSidePanel } from "./AcSidePanel.vue";
|
package/dist/lib/index.js
CHANGED
|
@@ -59,46 +59,48 @@ import $ from "./components/AcSelect.js";
|
|
|
59
59
|
import se from "./components/AcKeyValueInput.js";
|
|
60
60
|
import ce from "./components/AcLoader.js";
|
|
61
61
|
import le from "./components/AcLocaleSwitcher.js";
|
|
62
|
-
import ue from "./components/
|
|
63
|
-
import de from "./components/
|
|
64
|
-
import fe from "./components/
|
|
65
|
-
import pe from "./components/
|
|
66
|
-
import me from "./components/
|
|
67
|
-
import he from "./components/
|
|
68
|
-
import ge from "./components/
|
|
69
|
-
import _e from "./components/
|
|
70
|
-
import ve from "./components/
|
|
71
|
-
import ye from "./components/
|
|
72
|
-
import be from "./components/
|
|
73
|
-
import xe from "./components/
|
|
74
|
-
import Se from "./components/
|
|
75
|
-
import Ce from "./components/
|
|
76
|
-
import we from "./components/
|
|
77
|
-
import Te from "./components/
|
|
78
|
-
import Ee from "./components/
|
|
79
|
-
import De from "./components/
|
|
80
|
-
import Oe from "./components/
|
|
81
|
-
import ke from "./components/
|
|
82
|
-
import Ae from "./components/
|
|
83
|
-
import je from "./components/
|
|
84
|
-
import Me from "./components/
|
|
85
|
-
import Ne from "./components/
|
|
86
|
-
import Pe from "./components/
|
|
87
|
-
import Fe from "./components/
|
|
88
|
-
import Ie from "./components/
|
|
89
|
-
import Le from "./components/
|
|
90
|
-
import Re from "./components/
|
|
91
|
-
import ze from "./components/
|
|
92
|
-
import
|
|
93
|
-
import Ve from "./components/
|
|
94
|
-
import He from "./
|
|
95
|
-
import
|
|
96
|
-
import
|
|
97
|
-
import Ke from "./
|
|
98
|
-
import qe from "./components/
|
|
99
|
-
import
|
|
100
|
-
import
|
|
101
|
-
import {
|
|
102
|
-
import {
|
|
103
|
-
import {
|
|
104
|
-
|
|
62
|
+
import ue from "./components/AcProductTag.js";
|
|
63
|
+
import de from "./components/AcNavbar.js";
|
|
64
|
+
import fe from "./components/AcNotificationMenu.js";
|
|
65
|
+
import pe from "./components/AcNumberInput.js";
|
|
66
|
+
import me from "./components/AcPage.js";
|
|
67
|
+
import he from "./components/AcPagination.js";
|
|
68
|
+
import ge from "./components/AcPreloader.js";
|
|
69
|
+
import _e from "./components/AcProgress.js";
|
|
70
|
+
import ve from "./components/AcProductHero.js";
|
|
71
|
+
import ye from "./components/AcRadioCard.js";
|
|
72
|
+
import be from "./components/AcTag.js";
|
|
73
|
+
import xe from "./components/AcResourceCard.js";
|
|
74
|
+
import Se from "./components/AcSectionContent.js";
|
|
75
|
+
import Ce from "./components/AcSegmentedControl.js";
|
|
76
|
+
import we from "./components/AcSettingsRow.js";
|
|
77
|
+
import Te from "./components/AcSidebar.js";
|
|
78
|
+
import Ee from "./components/AcSidebarBrand.js";
|
|
79
|
+
import De from "./components/AcSidebarItem.js";
|
|
80
|
+
import Oe from "./components/AcSidebarSection.js";
|
|
81
|
+
import ke from "./components/AcSidePanel.js";
|
|
82
|
+
import Ae from "./components/AcSideTabs.js";
|
|
83
|
+
import je from "./components/AcSlider.js";
|
|
84
|
+
import Me from "./components/AcStatCard.js";
|
|
85
|
+
import Ne from "./components/AcStatusBar.js";
|
|
86
|
+
import Pe from "./components/AcSteps.js";
|
|
87
|
+
import Fe from "./components/AcSwitch.js";
|
|
88
|
+
import Ie from "./components/AcSwitchCard.js";
|
|
89
|
+
import Le from "./components/AcTable.js";
|
|
90
|
+
import Re from "./components/AcTabs.js";
|
|
91
|
+
import ze from "./components/AcTagInput.js";
|
|
92
|
+
import Be from "./components/AcTaintInput.js";
|
|
93
|
+
import Ve from "./components/AcTextarea.js";
|
|
94
|
+
import { useColorMode as He } from "./composables/useColorMode.js";
|
|
95
|
+
import Ue from "./components/AcThemeMode.js";
|
|
96
|
+
import We from "./components/AcTimePicker.js";
|
|
97
|
+
import { showToast as Ge, useToast as Ke } from "./composables/useToast.js";
|
|
98
|
+
import qe from "./components/AcToaster.js";
|
|
99
|
+
import Je from "./components/AcUsageCard.js";
|
|
100
|
+
import Ye from "./components/AcUserMenu.js";
|
|
101
|
+
import { useTablePagination as Xe } from "./composables/useTablePagination.js";
|
|
102
|
+
import { useApiPagination as Ze } from "./composables/useApiPagination.js";
|
|
103
|
+
import { useBulkSelection as Qe } from "./composables/useBulkSelection.js";
|
|
104
|
+
import { useFormValidation as $e } from "./composables/useFormValidation.js";
|
|
105
|
+
import { HSLToHex as et, HexToHSL as tt, MIN_CONTRAST as nt, contrastOnWhite as rt, getThemeHSL as it, hexToHsl as at, hslToHex as ot, readableLightness as st, setThemeHSL as ct, useBrandColor as lt } from "./composables/useBrandColor.js";
|
|
106
|
+
export { ee as AcAccordion, te as AcAccordionItem, r as AcAlert, o as AcAppSwitcher, s as AcAvatar, d as AcBadge, f as AcBanner, p as AcBreadcrumb, m as AcBulkActionBar, n as AcButton, h as AcButtons, g as AcCard, y as AcCellValue, b as AcCheckBox, x as AcCheckList, S as AcCheckRadio, C as AcCircularProgress, w as AcClusterSwitcher, T as AcColorInput, E as AcCommandBlock, D as AcConfirmModal, O as AcContentHeader, k as AcContentLayout, j as AcContentTable, M as AcCopyButton, N as AcCostSummary, P as AcDatePicker, I as AcDeleteConfirmationModal, I as AcDeleteModal, L as AcDivider, R as AcDropdown, z as AcDropdownDivider, B as AcDropdownItem, V as AcEmptyState, H as AcErrorState, U as AcFeatureCard, W as AcFileUpload, q as AcFontScale, J as AcFooter, Y as AcForm, X as AcFormArray, Z as AcFormFooter, Q as AcFormSection, ne as AcHeader, re as AcHeaderItem, ie as AcHeaderItems, ae as AcInfoTable, F as AcInput, oe as AcKbd, se as AcKeyValueInput, ce as AcLoader, le as AcLocaleSwitcher, i as AcLogo, _ as AcModal, de as AcNavbar, a as AcNavbarItem, fe as AcNotificationMenu, pe as AcNumberInput, me as AcPage, he as AcPagination, ge as AcPreloader, ve as AcProductHero, ue as AcProductTag, _e as AcProgress, ye as AcRadioCard, xe as AcResourceCard, A as AcSearchBar, Se as AcSectionContent, Ce as AcSegmentedControl, $ as AcSelect, we as AcSettingsRow, ke as AcSidePanel, Ae as AcSideTabs, Te as AcSidebar, Ee as AcSidebarBrand, De as AcSidebarItem, Oe as AcSidebarSection, v as AcSkeleton, je as AcSlider, e as AcSpinner, Me as AcStatCard, Ne as AcStatusBar, Pe as AcSteps, Fe as AcSwitch, Ie as AcSwitchCard, Le as AcTable, Re as AcTabs, be as AcTag, ze as AcTagInput, Be as AcTaintInput, Ve as AcTextarea, Ue as AcThemeMode, We as AcTimePicker, qe as AcToaster, t as AcTooltip, Je as AcUsageCard, Ye as AcUserMenu, G as FONT_SCALES, et as HSLToHex, tt as HexToHSL, nt as MIN_CONTRAST, rt as contrastOnWhite, it as getThemeHSL, at as hexToHsl, ot as hslToHex, c as humanizeState, l as normalizeState, st as readableLightness, ct as setThemeHSL, Ge as showToast, u as statusMeta, Ze as useApiPagination, lt as useBrandColor, Qe as useBulkSelection, He as useColorMode, K as useFontScale, $e as useFormValidation, Xe as useTablePagination, Ke as useToast };
|