@koide-labs/ui 0.0.10 → 0.0.12
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/components/anchor/index.js +7 -10
- package/dist/components/badge/index.d.ts +1 -1
- package/dist/components/badge/index.js +29 -27
- package/dist/components/collapse/index.js +5 -11
- package/dist/components/heading/index.js +1 -6
- package/dist/components/status-banner/index.d.ts +1 -1
- package/dist/components/status-banner/index.js +15 -13
- package/dist/components/text/index.js +13 -16
- package/dist/components/toast/toast.js +258 -260
- package/dist/components/view/index.js +19 -22
- package/dist/toast.css +1 -1
- package/package.json +16 -19
|
@@ -8,16 +8,13 @@ function p({ external: e, render: r, ...n }) {
|
|
|
8
8
|
return o({
|
|
9
9
|
defaultTagName: "a",
|
|
10
10
|
render: r,
|
|
11
|
-
props: t(
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
},
|
|
19
|
-
n
|
|
20
|
-
)
|
|
11
|
+
props: t(n, {
|
|
12
|
+
className: s.anchor,
|
|
13
|
+
...e ? {
|
|
14
|
+
target: "_blank",
|
|
15
|
+
rel: "noreferrer"
|
|
16
|
+
} : {}
|
|
17
|
+
})
|
|
21
18
|
});
|
|
22
19
|
}
|
|
23
20
|
export {
|
|
@@ -13,4 +13,4 @@ export interface BadgeProps extends Omit<useRender.ComponentProps<"span">, "chil
|
|
|
13
13
|
/** Tagline of badge. */
|
|
14
14
|
tagline?: string;
|
|
15
15
|
}
|
|
16
|
-
export declare function Badge({ icon, name, color, shiny, tagline, render, ...props }: BadgeProps): import("react/jsx-runtime").JSX.Element;
|
|
16
|
+
export declare function Badge({ icon, name, color, shiny, tagline, render, className, ...props }: BadgeProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,41 +1,43 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { jsx as e, jsxs as
|
|
3
|
-
import { c as
|
|
4
|
-
import { Icon as
|
|
5
|
-
import { Text as
|
|
6
|
-
import { Tooltip as
|
|
7
|
-
import { View as
|
|
8
|
-
import { u as
|
|
9
|
-
import { m as
|
|
10
|
-
import '../../index8.css';const
|
|
11
|
-
badge:
|
|
12
|
-
badge_shiny:
|
|
2
|
+
import { jsx as e, jsxs as g, Fragment as p } from "react/jsx-runtime";
|
|
3
|
+
import { c as f } from "../../clsx-OuTLNxxd.js";
|
|
4
|
+
import { Icon as u } from "../icon/index.js";
|
|
5
|
+
import { Text as _ } from "../text/index.js";
|
|
6
|
+
import { Tooltip as b } from "../tooltip/index.js";
|
|
7
|
+
import { View as h } from "../view/index.js";
|
|
8
|
+
import { u as x } from "../../useRender-CLx7dR_1.js";
|
|
9
|
+
import { m as y } from "../../useRenderElement-DwToLA61.js";
|
|
10
|
+
import '../../index8.css';const T = "_badge_sf2gl_1", j = "_badge_shiny_sf2gl_16", t = {
|
|
11
|
+
badge: T,
|
|
12
|
+
badge_shiny: j
|
|
13
13
|
};
|
|
14
|
-
function
|
|
14
|
+
function V({
|
|
15
15
|
icon: r,
|
|
16
16
|
name: m,
|
|
17
17
|
color: n,
|
|
18
18
|
shiny: i,
|
|
19
19
|
tagline: s,
|
|
20
20
|
render: a,
|
|
21
|
-
|
|
21
|
+
className: l,
|
|
22
|
+
...d
|
|
22
23
|
}) {
|
|
23
|
-
const
|
|
24
|
+
const c = x({
|
|
24
25
|
defaultTagName: "span",
|
|
25
26
|
render: a,
|
|
26
|
-
props:
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
27
|
+
props: y(d, {
|
|
28
|
+
className: f(
|
|
29
|
+
t.badge,
|
|
30
|
+
i && t.badge_shiny,
|
|
31
|
+
l
|
|
32
|
+
),
|
|
33
|
+
children: /* @__PURE__ */ g(p, { children: [
|
|
34
|
+
r ? /* @__PURE__ */ e(u, { name: r }) : null,
|
|
35
|
+
m
|
|
36
|
+
] })
|
|
37
|
+
})
|
|
38
|
+
}), o = /* @__PURE__ */ e(h, { color: n, children: c });
|
|
39
|
+
return s ? /* @__PURE__ */ e(b, { trigger: o, children: /* @__PURE__ */ e(_, { size: "sm", multiline: !0, children: s }) }) : o;
|
|
38
40
|
}
|
|
39
41
|
export {
|
|
40
|
-
|
|
42
|
+
V as Badge
|
|
41
43
|
};
|
|
@@ -24,17 +24,11 @@ function R({
|
|
|
24
24
|
defaultTagName: "div",
|
|
25
25
|
render: o,
|
|
26
26
|
ref: l,
|
|
27
|
-
props: _(
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
s && t.collapse_expand
|
|
33
|
-
),
|
|
34
|
-
style: { "--collapse-height": `${n}px` }
|
|
35
|
-
},
|
|
36
|
-
a
|
|
37
|
-
)
|
|
27
|
+
props: _(a, {
|
|
28
|
+
"aria-hidden": !s,
|
|
29
|
+
className: p(t.collapse, s && t.collapse_expand),
|
|
30
|
+
style: { "--collapse-height": `${n}px` }
|
|
31
|
+
})
|
|
38
32
|
});
|
|
39
33
|
}
|
|
40
34
|
export {
|
|
@@ -14,4 +14,4 @@ export interface StatusBannerProps extends Omit<useRender.ComponentProps<"div">,
|
|
|
14
14
|
/** Size, defaults to lg */
|
|
15
15
|
size?: Extract<Size, "md" | "lg">;
|
|
16
16
|
}
|
|
17
|
-
export declare function StatusBanner({ color, icon, title, description, size, render, ...props }: StatusBannerProps): import("react/jsx-runtime").JSX.Element;
|
|
17
|
+
export declare function StatusBanner({ color, icon, title, description, size, render, className, ...props }: StatusBannerProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsxs as _, jsx as s } from "react/jsx-runtime";
|
|
3
|
-
import { c as
|
|
4
|
-
import { Heading as
|
|
5
|
-
import { Icon as
|
|
6
|
-
import { Text as
|
|
3
|
+
import { c as b } from "../../clsx-OuTLNxxd.js";
|
|
4
|
+
import { Heading as d } from "../heading/index.js";
|
|
5
|
+
import { Icon as g } from "../icon/index.js";
|
|
6
|
+
import { Text as p } from "../text/index.js";
|
|
7
7
|
import { View as i } from "../view/index.js";
|
|
8
8
|
import '../../index3.css';const t = {
|
|
9
9
|
"status-banner": "_status-banner_zygt6_1",
|
|
@@ -26,32 +26,34 @@ import '../../index3.css';const t = {
|
|
|
26
26
|
description: "md"
|
|
27
27
|
}
|
|
28
28
|
};
|
|
29
|
-
function
|
|
29
|
+
function w({
|
|
30
30
|
color: e,
|
|
31
31
|
icon: r,
|
|
32
32
|
title: o,
|
|
33
33
|
description: l,
|
|
34
34
|
size: n = "lg",
|
|
35
35
|
render: u,
|
|
36
|
-
|
|
36
|
+
className: c,
|
|
37
|
+
...m
|
|
37
38
|
}) {
|
|
38
39
|
return /* @__PURE__ */ _(
|
|
39
40
|
i,
|
|
40
41
|
{
|
|
41
42
|
render: u,
|
|
42
|
-
...
|
|
43
|
+
...m,
|
|
43
44
|
color: e,
|
|
44
|
-
className:
|
|
45
|
+
className: b(
|
|
45
46
|
t["status-banner"],
|
|
46
47
|
t[`status-banner_size_${n}`],
|
|
47
|
-
e ? t["status-banner_variant_colorway"] : t["status-banner_variant_neutral"]
|
|
48
|
+
e ? t["status-banner_variant_colorway"] : t["status-banner_variant_neutral"],
|
|
49
|
+
c
|
|
48
50
|
),
|
|
49
51
|
children: [
|
|
50
|
-
r ? /* @__PURE__ */ s(
|
|
52
|
+
r ? /* @__PURE__ */ s(g, { name: r, size: a[n].icon }) : null,
|
|
51
53
|
/* @__PURE__ */ _(i, { className: t["status-banner__content"], children: [
|
|
52
|
-
/* @__PURE__ */ s(
|
|
54
|
+
/* @__PURE__ */ s(d, { level: 1, size: a[n].title, color: "inherit", children: o }),
|
|
53
55
|
/* @__PURE__ */ s(
|
|
54
|
-
|
|
56
|
+
p,
|
|
55
57
|
{
|
|
56
58
|
className: t["status-banner__description"],
|
|
57
59
|
multiline: !0,
|
|
@@ -66,5 +68,5 @@ function x({
|
|
|
66
68
|
);
|
|
67
69
|
}
|
|
68
70
|
export {
|
|
69
|
-
|
|
71
|
+
w as StatusBanner
|
|
70
72
|
};
|
|
@@ -29,22 +29,19 @@ function P({
|
|
|
29
29
|
return m({
|
|
30
30
|
defaultTagName: "span",
|
|
31
31
|
render: x,
|
|
32
|
-
props: r(
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
},
|
|
46
|
-
o
|
|
47
|
-
)
|
|
32
|
+
props: r(o, {
|
|
33
|
+
className: i(
|
|
34
|
+
c.view,
|
|
35
|
+
t.text,
|
|
36
|
+
t[`text_color_${l}`],
|
|
37
|
+
t[`text_size_${s}`],
|
|
38
|
+
!e && t["text_clip-line"],
|
|
39
|
+
!e && _ > 1 && t["text_clamp-lines"]
|
|
40
|
+
),
|
|
41
|
+
style: {
|
|
42
|
+
"--text-max-lines": Math.max(_, 1)
|
|
43
|
+
}
|
|
44
|
+
})
|
|
48
45
|
});
|
|
49
46
|
}
|
|
50
47
|
export {
|