@arthurzakharov/ui-kit 2.11.0 → 2.13.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/timetable-CqiWwUNY.css +1 -0
- package/dist/components/sidebar/sidebar.component.d.ts +3 -2
- package/dist/components/sidebar/sidebar.component.js +65 -51
- package/dist/components/timetable/timetable.component.js +11 -12
- package/package.json +1 -1
- package/dist/assets/timetable-C4OGIa6M.css +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
._Timetable_zg6h3_1{display:flex;flex-direction:column;gap:var(--rm-ui-padding-xxs)}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { PropsWithChildren } from 'react';
|
|
1
|
+
import { PropsWithChildren, ReactNode } from 'react';
|
|
2
2
|
import { CertificationsProps } from '../certifications';
|
|
3
3
|
import { UserPanelProps } from '../user-panel';
|
|
4
4
|
import { State } from '../../controls/utils';
|
|
@@ -16,6 +16,7 @@ export interface SidebarProps extends PropsWithChildren<Base> {
|
|
|
16
16
|
info: SidebarInfo[];
|
|
17
17
|
user: UserPanelProps;
|
|
18
18
|
certifications: CertificationsProps;
|
|
19
|
+
extras?: ReactNode;
|
|
19
20
|
}
|
|
20
|
-
export declare const Sidebar: ({ children, isButtonVisible, isUserOpen, title, steps, info, certifications, user, ...base }: SidebarProps) => import("react/jsx-runtime").JSX.Element;
|
|
21
|
+
export declare const Sidebar: ({ children, isButtonVisible, isUserOpen, title, steps, info, certifications, user, extras, ...base }: SidebarProps) => import("react/jsx-runtime").JSX.Element;
|
|
21
22
|
export {};
|
|
@@ -1,78 +1,92 @@
|
|
|
1
|
-
import { jsx as t, jsxs as o, Fragment as
|
|
2
|
-
import { clsx as
|
|
3
|
-
import { FadeScale as
|
|
4
|
-
import { Certifications as
|
|
5
|
-
import { Line as
|
|
6
|
-
import { Text as
|
|
7
|
-
import { UserPanel as
|
|
1
|
+
import { jsx as t, jsxs as o, Fragment as S } from "react/jsx-runtime";
|
|
2
|
+
import { clsx as c, baseProps as f } from "../../utils/functions/functions.util.js";
|
|
3
|
+
import { FadeScale as v } from "../../animations/fade-scale/fade-scale.component.js";
|
|
4
|
+
import { Certifications as A } from "../certifications/certifications.component.js";
|
|
5
|
+
import { Line as d } from "../line/line.component.js";
|
|
6
|
+
import { Text as m } from "../text/text.component.js";
|
|
7
|
+
import { UserPanel as B } from "../user-panel/user-panel.component.js";
|
|
8
8
|
import "../../controls/primitives/box/box.component.js";
|
|
9
9
|
import "../../utils/content/content.component.js";
|
|
10
10
|
import "lucide-react";
|
|
11
11
|
import "usehooks-ts";
|
|
12
12
|
import { Status as x } from "../../controls/primitives/status/status.component.js";
|
|
13
|
-
import '../../assets/sidebar-DyDlIXV0.css';const y = "_Sidebar_17t5d_1",
|
|
13
|
+
import '../../assets/sidebar-DyDlIXV0.css';const y = "_Sidebar_17t5d_1", T = "_Board_17t5d_5", R = "_SidebarTitle_17t5d_11", z = "_SidebarButton_17t5d_12", C = "_Steps_17t5d_16", $ = "_Info_17t5d_17", j = "_Step_17t5d_16", F = "_InfoRow_17t5d_30", P = "_NothingAbove_17t5d_44", i = {
|
|
14
14
|
Sidebar: y,
|
|
15
|
-
Board:
|
|
16
|
-
SidebarTitle:
|
|
17
|
-
SidebarButton:
|
|
18
|
-
Steps:
|
|
19
|
-
Info:
|
|
20
|
-
Step:
|
|
21
|
-
InfoRow:
|
|
22
|
-
NothingAbove:
|
|
23
|
-
},
|
|
15
|
+
Board: T,
|
|
16
|
+
SidebarTitle: R,
|
|
17
|
+
SidebarButton: z,
|
|
18
|
+
Steps: C,
|
|
19
|
+
Info: $,
|
|
20
|
+
Step: j,
|
|
21
|
+
InfoRow: F,
|
|
22
|
+
NothingAbove: P
|
|
23
|
+
}, X = ({
|
|
24
24
|
// Sidebar props
|
|
25
|
-
children:
|
|
25
|
+
children: g,
|
|
26
26
|
isButtonVisible: b = !1,
|
|
27
|
-
isUserOpen:
|
|
28
|
-
title:
|
|
29
|
-
steps:
|
|
30
|
-
info:
|
|
31
|
-
certifications:
|
|
32
|
-
user:
|
|
27
|
+
isUserOpen: r = !1,
|
|
28
|
+
title: N = "Ihre Übersicht",
|
|
29
|
+
steps: I = [],
|
|
30
|
+
info: u = [],
|
|
31
|
+
certifications: p,
|
|
32
|
+
user: n,
|
|
33
|
+
extras: s,
|
|
33
34
|
// Base props
|
|
34
|
-
...
|
|
35
|
+
..._
|
|
35
36
|
}) => {
|
|
36
|
-
const
|
|
37
|
+
const h = u.filter(([, e]) => e.trim() !== ""), a = h.length > 0;
|
|
37
38
|
return /* @__PURE__ */ t(
|
|
38
39
|
"div",
|
|
39
40
|
{
|
|
40
|
-
"data-testid":
|
|
41
|
-
className:
|
|
41
|
+
"data-testid": f(_, "data-testid", "sidebar"),
|
|
42
|
+
className: c(i.Sidebar, f(_, "className")),
|
|
42
43
|
children: /* @__PURE__ */ o("div", { className: i.Board, children: [
|
|
43
|
-
/* @__PURE__ */ t(
|
|
44
|
-
/* @__PURE__ */ t("div", { className: i.Steps, "data-testid": "sidebar-steps", children:
|
|
44
|
+
/* @__PURE__ */ t(m, { preset: "sidebar-title", className: i.SidebarTitle, children: N }),
|
|
45
|
+
/* @__PURE__ */ t("div", { className: i.Steps, "data-testid": "sidebar-steps", children: I.map(({ state: e, text: l }) => /* @__PURE__ */ o("div", { className: i.Step, "data-testid": "sidebar-step", children: [
|
|
45
46
|
/* @__PURE__ */ t(x, { state: e }),
|
|
46
|
-
/* @__PURE__ */ t(
|
|
47
|
-
] },
|
|
48
|
-
|
|
49
|
-
/* @__PURE__ */ t(
|
|
50
|
-
/* @__PURE__ */ t("div", { className: i.Info, "data-testid": "sidebar-info", children:
|
|
51
|
-
/* @__PURE__ */ t(
|
|
52
|
-
/* @__PURE__ */ t(
|
|
53
|
-
] }, `${e}-${
|
|
54
|
-
/* @__PURE__ */ t(
|
|
47
|
+
/* @__PURE__ */ t(m, { tag: "span", weight: "medium", size: "body-small", color: e === "idle" ? "grey-400" : "text-primary", children: l })
|
|
48
|
+
] }, l)) }),
|
|
49
|
+
a && /* @__PURE__ */ o(S, { children: [
|
|
50
|
+
/* @__PURE__ */ t(d, {}),
|
|
51
|
+
/* @__PURE__ */ t("div", { className: i.Info, "data-testid": "sidebar-info", children: h.map(([e, l], w) => /* @__PURE__ */ o("div", { className: i.InfoRow, "data-testid": "sidebar-info-row", children: [
|
|
52
|
+
/* @__PURE__ */ t(m, { tag: "span", size: "body-small", color: "text-secondary", children: e }),
|
|
53
|
+
/* @__PURE__ */ t(m, { tag: "span", size: "body-small", align: "right", children: l })
|
|
54
|
+
] }, `${e}-${w}`)) }),
|
|
55
|
+
/* @__PURE__ */ t(d, {})
|
|
55
56
|
] }),
|
|
56
|
-
/* @__PURE__ */ o(
|
|
57
|
-
!
|
|
58
|
-
/* @__PURE__ */ t(
|
|
59
|
-
/* @__PURE__ */ t(
|
|
57
|
+
/* @__PURE__ */ o(v, { name: "user", condition: r, children: [
|
|
58
|
+
!a && /* @__PURE__ */ t(d, {}),
|
|
59
|
+
/* @__PURE__ */ t(B, { title: n.title, button: n.button, data: n.data, onClick: n.onClick }),
|
|
60
|
+
/* @__PURE__ */ t(d, {})
|
|
60
61
|
] }),
|
|
61
|
-
/* @__PURE__ */ t(
|
|
62
|
+
/* @__PURE__ */ t(v, { name: "button", condition: b, children: /* @__PURE__ */ t(
|
|
62
63
|
"div",
|
|
63
64
|
{
|
|
64
|
-
className:
|
|
65
|
-
[i.NothingAbove]: !
|
|
65
|
+
className: c(i.SidebarButton, {
|
|
66
|
+
[i.NothingAbove]: !a && !r
|
|
66
67
|
}),
|
|
67
|
-
children:
|
|
68
|
+
children: g
|
|
68
69
|
}
|
|
69
70
|
) }),
|
|
70
|
-
/* @__PURE__ */
|
|
71
|
+
s != null && /* @__PURE__ */ o(S, { children: [
|
|
72
|
+
/* @__PURE__ */ t(
|
|
73
|
+
"div",
|
|
74
|
+
{
|
|
75
|
+
"data-testid": "sidebar-extras",
|
|
76
|
+
className: c(i.SidebarExtras, {
|
|
77
|
+
[i.NothingAbove]: !a && !r && !b
|
|
78
|
+
}),
|
|
79
|
+
children: s
|
|
80
|
+
}
|
|
81
|
+
),
|
|
82
|
+
/* @__PURE__ */ t(d, {})
|
|
83
|
+
] }),
|
|
84
|
+
/* @__PURE__ */ t(A, { icons: p.icons, tuvSrc: p.tuvSrc, align: p.align }),
|
|
71
85
|
/* @__PURE__ */ t(
|
|
72
86
|
"div",
|
|
73
87
|
{
|
|
74
|
-
className:
|
|
75
|
-
[i.NothingAbove]: !
|
|
88
|
+
className: c({
|
|
89
|
+
[i.NothingAbove]: !a && !r && !b && s == null
|
|
76
90
|
})
|
|
77
91
|
}
|
|
78
92
|
)
|
|
@@ -81,5 +95,5 @@ import '../../assets/sidebar-DyDlIXV0.css';const y = "_Sidebar_17t5d_1", A = "_B
|
|
|
81
95
|
);
|
|
82
96
|
};
|
|
83
97
|
export {
|
|
84
|
-
|
|
98
|
+
X as Sidebar
|
|
85
99
|
};
|
|
@@ -1,16 +1,15 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import { baseProps as
|
|
3
|
-
import
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
/* @__PURE__ */ s("
|
|
11
|
-
m.map((n, i) => /* @__PURE__ */ s("p", { "data-testid": `${t}-line-${i}`, className: e.Line, children: n }, i))
|
|
1
|
+
import { jsxs as r, jsx as s } from "react/jsx-runtime";
|
|
2
|
+
import { baseProps as i, clsx as c } from "../../utils/functions/functions.util.js";
|
|
3
|
+
import { Text as l } from "../text/text.component.js";
|
|
4
|
+
import '../../assets/timetable-CqiWwUNY.css';const n = "_Timetable_zg6h3_1", b = {
|
|
5
|
+
Timetable: n
|
|
6
|
+
}, h = ({ title: m, lines: o, ...e }) => {
|
|
7
|
+
const t = i(e, "data-testid", "timetable");
|
|
8
|
+
return /* @__PURE__ */ r("div", { "data-testid": t, className: c(b.Timetable, i(e, "className")), children: [
|
|
9
|
+
/* @__PURE__ */ s(l, { tag: "span", size: "body-small", color: "text-secondary", "data-testid": `${t}-title`, children: m }),
|
|
10
|
+
o.map((d, a) => /* @__PURE__ */ s(l, { tag: "span", size: "body-small", "data-testid": `${t}-line-${a}`, children: d }, a))
|
|
12
11
|
] });
|
|
13
12
|
};
|
|
14
13
|
export {
|
|
15
|
-
|
|
14
|
+
h as Timetable
|
|
16
15
|
};
|
package/package.json
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
._Timetable_1y4a7_1{display:flex;flex-direction:column;gap:var(--rm-ui-padding-xxs);padding:var(--rm-ui-padding-sm) var(--rm-ui-padding-md)}._Title_1y4a7_8{margin:0;font-weight:var(--rm-ui-font-weight-medium);font-size:var(--rm-ui-font-size-body-small);line-height:var(--rm-ui-line-height-body-small);color:var(--rm-ui-color-text-primary)}._Line_1y4a7_16{margin:0;font-weight:var(--rm-ui-font-weight-regular);font-size:var(--rm-ui-font-size-body-small);line-height:var(--rm-ui-line-height-body-small);color:var(--rm-ui-color-text-secondary)}
|