welcome-ui 10.3.0 → 10.3.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/Window.js
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import './Window.css';
|
|
3
|
-
import { jsx as r, jsxs as
|
|
3
|
+
import { jsx as r, jsxs as b } from "react/jsx-runtime";
|
|
4
4
|
import { c as d } from "./index-PAaZGbyz.js";
|
|
5
|
-
import { f as
|
|
5
|
+
import { f as u } from "./forwardRefWithAs-8eP3ZN15.js";
|
|
6
6
|
import { forwardRef as l, useState as B } from "react";
|
|
7
|
-
import { T as
|
|
8
|
-
import { b as
|
|
9
|
-
import { Badge as
|
|
7
|
+
import { T as I, a as g, b as j } from "./tab-panel-BFzjhpJq.js";
|
|
8
|
+
import { b as A } from "./Q5W46E73-ClIlNE6g.js";
|
|
9
|
+
import { Badge as S } from "./Badge.js";
|
|
10
10
|
import { Icon as m } from "./Icon.js";
|
|
11
|
-
import { Text as
|
|
12
|
-
const
|
|
13
|
-
root:
|
|
11
|
+
import { Text as h } from "./Text.js";
|
|
12
|
+
const H = "_root_1r7a4_2", P = "_header_1r7a4_11", R = "_media_1r7a4_125", c = {
|
|
13
|
+
root: H,
|
|
14
14
|
header: P,
|
|
15
15
|
"header-title": "_header-title_1r7a4_25",
|
|
16
16
|
"header-tabs": "_header-tabs_1r7a4_31",
|
|
@@ -26,120 +26,120 @@ const I = "_root_1r7a4_2", P = "_header_1r7a4_11", R = "_media_1r7a4_125", c = {
|
|
|
26
26
|
"size-md": "_size-md_1r7a4_149",
|
|
27
27
|
"size-sm": "_size-sm_1r7a4_153",
|
|
28
28
|
"size-xs": "_size-xs_1r7a4_157"
|
|
29
|
-
}, k = d(c),
|
|
30
|
-
({ children: t, className:
|
|
29
|
+
}, k = d(c), p = l(
|
|
30
|
+
({ children: t, className: a, size: e = "md", ...s }, o) => /* @__PURE__ */ r("div", { className: k("body", `size-${e}`, a), ref: o, ...s, children: t })
|
|
31
31
|
);
|
|
32
|
-
|
|
33
|
-
const L = d(c),
|
|
34
|
-
({ children: t, className:
|
|
32
|
+
p.displayName = "Window.Body";
|
|
33
|
+
const L = d(c), x = l(
|
|
34
|
+
({ children: t, className: a, ...e }, s) => /* @__PURE__ */ r("div", { className: L("box-text", a), ref: s, ...e, children: t })
|
|
35
35
|
);
|
|
36
|
-
|
|
37
|
-
const n = d(c),
|
|
36
|
+
x.displayName = "Window.BoxText";
|
|
37
|
+
const n = d(c), w = ({
|
|
38
38
|
"aria-label": t,
|
|
39
|
-
className:
|
|
40
|
-
icon:
|
|
39
|
+
className: a,
|
|
40
|
+
icon: e,
|
|
41
41
|
onClick: s,
|
|
42
42
|
...o
|
|
43
43
|
}) => /* @__PURE__ */ r(
|
|
44
44
|
"button",
|
|
45
45
|
{
|
|
46
46
|
"aria-label": t,
|
|
47
|
-
className: n("header-action-button",
|
|
47
|
+
className: n("header-action-button", a),
|
|
48
48
|
onClick: s,
|
|
49
49
|
type: "button",
|
|
50
50
|
...o,
|
|
51
|
-
children: /* @__PURE__ */ r(m, { name:
|
|
51
|
+
children: /* @__PURE__ */ r(m, { name: e })
|
|
52
52
|
}
|
|
53
|
-
),
|
|
53
|
+
), N = ({
|
|
54
54
|
as: t,
|
|
55
|
-
className:
|
|
56
|
-
onClick:
|
|
55
|
+
className: a,
|
|
56
|
+
onClick: e
|
|
57
57
|
}) => /* @__PURE__ */ r(
|
|
58
|
-
|
|
58
|
+
w,
|
|
59
59
|
{
|
|
60
60
|
"aria-label": "Close window",
|
|
61
61
|
as: t,
|
|
62
|
-
className: n("header-close-button",
|
|
62
|
+
className: n("header-close-button", a),
|
|
63
63
|
icon: "times",
|
|
64
|
-
onClick:
|
|
64
|
+
onClick: e
|
|
65
65
|
}
|
|
66
|
-
), M = ({ children: t, store: e }) => /* @__PURE__ */ r(
|
|
67
|
-
({ as: t, badge:
|
|
68
|
-
const
|
|
69
|
-
return /* @__PURE__ */
|
|
70
|
-
|
|
66
|
+
), M = ({ children: t, className: a, store: e, ...s }) => /* @__PURE__ */ r(g, { className: n("header-tabs", a), store: e, ...s, children: t }), O = u(
|
|
67
|
+
({ as: t, badge: a, children: e, className: s, icon: o, id: i, store: _, ...v }, W) => {
|
|
68
|
+
const $ = A(_, "selectedId") === i;
|
|
69
|
+
return /* @__PURE__ */ b(
|
|
70
|
+
I,
|
|
71
71
|
{
|
|
72
|
-
className: n("header-tab-item"),
|
|
73
|
-
id:
|
|
74
|
-
ref:
|
|
72
|
+
className: n("header-tab-item", s),
|
|
73
|
+
id: i,
|
|
74
|
+
ref: W,
|
|
75
75
|
render: t ? /* @__PURE__ */ r(t, {}) : void 0,
|
|
76
|
-
store:
|
|
77
|
-
...
|
|
76
|
+
store: _,
|
|
77
|
+
...v,
|
|
78
78
|
children: [
|
|
79
|
-
|
|
80
|
-
/* @__PURE__ */ r(
|
|
81
|
-
|
|
79
|
+
o ? /* @__PURE__ */ r(m, { name: o }) : null,
|
|
80
|
+
/* @__PURE__ */ r(h, { variant: "label-sm", children: e }),
|
|
81
|
+
a ? /* @__PURE__ */ r(S, { variant: $ ? "neutral" : "warm", children: a }) : null
|
|
82
82
|
]
|
|
83
83
|
},
|
|
84
|
-
|
|
84
|
+
i
|
|
85
85
|
);
|
|
86
86
|
}
|
|
87
|
-
), E = ({ children: t, isClosable:
|
|
87
|
+
), E = ({ children: t, isClosable: a = !1, onClose: e }) => {
|
|
88
88
|
const s = () => {
|
|
89
|
-
|
|
89
|
+
e == null || e();
|
|
90
90
|
};
|
|
91
|
-
return /* @__PURE__ */
|
|
91
|
+
return /* @__PURE__ */ b("div", { className: n("header-actions"), children: [
|
|
92
92
|
t,
|
|
93
|
-
|
|
93
|
+
a ? /* @__PURE__ */ r(N, { onClick: s }) : null
|
|
94
94
|
] });
|
|
95
|
-
}, q = ({ isExpandable: t = !1, onExpandChange:
|
|
96
|
-
const [
|
|
97
|
-
const i = !
|
|
98
|
-
s(i),
|
|
95
|
+
}, q = ({ isExpandable: t = !1, onExpandChange: a }) => {
|
|
96
|
+
const [e, s] = B(!1), o = () => {
|
|
97
|
+
const i = !e;
|
|
98
|
+
s(i), a == null || a(i);
|
|
99
99
|
};
|
|
100
100
|
return /* @__PURE__ */ r("div", { className: n("header-actions"), children: t ? /* @__PURE__ */ r(
|
|
101
101
|
"button",
|
|
102
102
|
{
|
|
103
|
-
"aria-expanded":
|
|
104
|
-
"aria-label":
|
|
103
|
+
"aria-expanded": e,
|
|
104
|
+
"aria-label": e ? "Collapse window" : "Expand window",
|
|
105
105
|
className: n("header-action-button"),
|
|
106
106
|
onClick: o,
|
|
107
107
|
type: "button",
|
|
108
|
-
children: /* @__PURE__ */ r(m, { name:
|
|
108
|
+
children: /* @__PURE__ */ r(m, { name: e ? "compress-alt" : "arrow-resize-diagonal" })
|
|
109
109
|
}
|
|
110
110
|
) : null });
|
|
111
|
-
}, C = ({ as: t, className:
|
|
112
|
-
({ children: t, className:
|
|
111
|
+
}, C = ({ as: t, className: a, title: e }) => /* @__PURE__ */ r(h, { as: t, className: n("header-title", a), variant: "body-md-strong", children: e }), f = l(
|
|
112
|
+
({ children: t, className: a, ...e }, s) => /* @__PURE__ */ r("header", { className: n("header", a), ref: s, ...e, children: t })
|
|
113
113
|
);
|
|
114
|
-
|
|
115
|
-
const D = Object.assign(
|
|
116
|
-
Button:
|
|
117
|
-
CloseButton:
|
|
114
|
+
f.displayName = "Window.Header";
|
|
115
|
+
const D = Object.assign(f, {
|
|
116
|
+
Button: w,
|
|
117
|
+
CloseButton: N,
|
|
118
118
|
LeftActions: q,
|
|
119
119
|
RightActions: E,
|
|
120
120
|
Tab: O,
|
|
121
121
|
Tabs: M,
|
|
122
122
|
Title: C
|
|
123
|
-
}), F = d(c),
|
|
124
|
-
({ children: t, className:
|
|
123
|
+
}), F = d(c), y = l(
|
|
124
|
+
({ children: t, className: a, ...e }, s) => /* @__PURE__ */ r("div", { className: F("media", a), ref: s, ...e, children: t })
|
|
125
125
|
);
|
|
126
|
-
|
|
127
|
-
const G = d(c),
|
|
128
|
-
({ children: t, store:
|
|
126
|
+
y.displayName = "Window.Media";
|
|
127
|
+
const G = d(c), z = l(
|
|
128
|
+
({ children: t, store: a, tabId: e, ...s }, o) => /* @__PURE__ */ r(j, { className: G("tab-panel"), ref: o, store: a, tabId: e, ...s, children: t })
|
|
129
129
|
);
|
|
130
|
-
|
|
131
|
-
const J = d(c),
|
|
132
|
-
({ as: t = "div", children:
|
|
130
|
+
z.displayName = "Window.TabPanel";
|
|
131
|
+
const J = d(c), T = u(
|
|
132
|
+
({ as: t = "div", children: a, className: e, role: s = "region", ...o }, i) => /* @__PURE__ */ r(t, { className: J("root", e), ref: i, role: s, ...o, children: a })
|
|
133
133
|
);
|
|
134
|
-
|
|
135
|
-
const
|
|
136
|
-
Body:
|
|
137
|
-
BoxText:
|
|
134
|
+
T.displayName = "Window";
|
|
135
|
+
const se = Object.assign(T, {
|
|
136
|
+
Body: p,
|
|
137
|
+
BoxText: x,
|
|
138
138
|
Header: D,
|
|
139
|
-
Media:
|
|
140
|
-
TabPanel:
|
|
139
|
+
Media: y,
|
|
140
|
+
TabPanel: z
|
|
141
141
|
});
|
|
142
142
|
export {
|
|
143
|
-
|
|
143
|
+
se as Window,
|
|
144
144
|
c as windowClasses
|
|
145
145
|
};
|
|
@@ -23,7 +23,7 @@ export declare const Drawer: import('react').ForwardRefExoticComponent<Omit<Draw
|
|
|
23
23
|
LeftActions: ({ isExpandable, onExpandChange }: import('../Window/types').HeaderLeftActionsProps) => import("react/jsx-runtime").JSX.Element;
|
|
24
24
|
RightActions: ({ children, isClosable, onClose }: import('../Window/types').HeaderRightActionsProps) => import("react/jsx-runtime").JSX.Element;
|
|
25
25
|
Tab: import('../../utils').FunctionComponentWithAs<"button", import('../Window/types').HeaderTabItem>;
|
|
26
|
-
Tabs: ({ children, store }: import('../Window/types').HeaderTabsProps) => import("react/jsx-runtime").JSX.Element;
|
|
26
|
+
Tabs: ({ children, className, store, ...rest }: import('../Window/types').HeaderTabsProps) => import("react/jsx-runtime").JSX.Element;
|
|
27
27
|
Title: ({ as, className, title }: import('../Window/types').HeaderTitleProps) => import("react/jsx-runtime").JSX.Element;
|
|
28
28
|
};
|
|
29
29
|
Media: import('react').ForwardRefExoticComponent<import('react').HTMLAttributes<HTMLDivElement> & import('react').RefAttributes<HTMLDivElement>>;
|
|
@@ -38,7 +38,7 @@ export declare const Modal: import('../../utils').FunctionComponentWithAs<"div",
|
|
|
38
38
|
LeftActions: ({ isExpandable, onExpandChange }: import('../Window/types').HeaderLeftActionsProps) => import("react/jsx-runtime").JSX.Element;
|
|
39
39
|
RightActions: ({ children, isClosable, onClose }: import('../Window/types').HeaderRightActionsProps) => import("react/jsx-runtime").JSX.Element;
|
|
40
40
|
Tab: import('../../utils').FunctionComponentWithAs<"button", import('../Window/types').HeaderTabItem>;
|
|
41
|
-
Tabs: ({ children, store }: import('../Window/types').HeaderTabsProps) => import("react/jsx-runtime").JSX.Element;
|
|
41
|
+
Tabs: ({ children, className, store, ...rest }: import('../Window/types').HeaderTabsProps) => import("react/jsx-runtime").JSX.Element;
|
|
42
42
|
Title: ({ as, className, title }: import('../Window/types').HeaderTitleProps) => import("react/jsx-runtime").JSX.Element;
|
|
43
43
|
};
|
|
44
44
|
WindowMedia: import('react').ForwardRefExoticComponent<import('react').HTMLAttributes<HTMLDivElement> & {
|
|
@@ -11,6 +11,6 @@ export declare const Header: import('react').ForwardRefExoticComponent<import('r
|
|
|
11
11
|
LeftActions: ({ isExpandable, onExpandChange }: HeaderLeftActionsProps) => import("react/jsx-runtime").JSX.Element;
|
|
12
12
|
RightActions: ({ children, isClosable, onClose }: HeaderRightActionsProps) => import("react/jsx-runtime").JSX.Element;
|
|
13
13
|
Tab: import('../../../utils').FunctionComponentWithAs<"button", HeaderTabItem>;
|
|
14
|
-
Tabs: ({ children, store }: HeaderTabsProps) => import("react/jsx-runtime").JSX.Element;
|
|
14
|
+
Tabs: ({ children, className, store, ...rest }: HeaderTabsProps) => import("react/jsx-runtime").JSX.Element;
|
|
15
15
|
Title: ({ as, className, title }: HeaderTitleProps) => import("react/jsx-runtime").JSX.Element;
|
|
16
16
|
};
|
|
@@ -16,7 +16,7 @@ export declare const Window: import('../../utils').FunctionComponentWithAs<"div"
|
|
|
16
16
|
LeftActions: ({ isExpandable, onExpandChange }: import('./types').HeaderLeftActionsProps) => import("react/jsx-runtime").JSX.Element;
|
|
17
17
|
RightActions: ({ children, isClosable, onClose }: import('./types').HeaderRightActionsProps) => import("react/jsx-runtime").JSX.Element;
|
|
18
18
|
Tab: import('../../utils').FunctionComponentWithAs<"button", import('./types').HeaderTabItem>;
|
|
19
|
-
Tabs: ({ children, store }: import('./types').HeaderTabsProps) => import("react/jsx-runtime").JSX.Element;
|
|
19
|
+
Tabs: ({ children, className, store, ...rest }: import('./types').HeaderTabsProps) => import("react/jsx-runtime").JSX.Element;
|
|
20
20
|
Title: ({ as, className, title }: import('./types').HeaderTitleProps) => import("react/jsx-runtime").JSX.Element;
|
|
21
21
|
};
|
|
22
22
|
Media: import('react').ForwardRefExoticComponent<import('react').HTMLAttributes<HTMLDivElement> & {
|