welcome-ui 10.0.0-alpha.11 → 10.0.0-alpha.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/Alert.css +1 -1
- package/dist/Alert.js +62 -62
- package/dist/Icon.js +212 -211
- package/dist/Select.js +350 -332
- package/dist/Swiper.js +201 -191
- package/dist/Tabs.css +1 -1
- package/dist/Tabs.js +320 -319
- package/dist/types/components/Icon/icons.d.ts +2 -2
- package/dist/types/components/Select/types.d.ts +1 -0
- package/dist/types/components/Tabs/Tab.d.ts +2 -0
- package/dist/types/components/Tabs/{components/TabPanel/index.d.ts → TabPanel.d.ts} +1 -1
- package/dist/types/components/Tabs/index.d.ts +6 -5
- package/dist/types/components/Tabs/types.d.ts +6 -12
- package/dist/types/components/Tabs/utils.d.ts +4 -7
- package/package.json +1 -1
- package/dist/types/components/Tabs/components/ActiveBar/index.d.ts +0 -5
- package/dist/types/components/Tabs/components/TabList/index.d.ts +0 -3
- package/dist/use-viewport-CgrficYB.js +0 -17
- package/dist/useForkRef-D807AV7D.js +0 -22
package/dist/Alert.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
@layer components{.
|
|
1
|
+
@layer components{._root_8fyu4_2{position:relative;display:flex;align-items:flex-start;width:100%;gap:var(--gap, var(--components-dimensions-alert-gap-content-md));border-radius:var(--components-dimensions-alert-border-radius);border-width:var(--border-width-sm);border-style:solid;padding:var(--padding);max-width:var(--maxWidth, max-content);background-color:var(--backgroundColor, var(--components-colors-alert-color-background-brand));border-color:var(--borderColor, var(--components-colors-alert-color-background-brand));color:var(--color, var(--components-colors-alert-color-text-brand-body))}._size-md_8fyu4_18{--padding: var(--components-dimensions-alert-padding-inline-md)}._size-md_8fyu4_18 ._content-actions_8fyu4_21{--gap: var(--components-dimensions-alert-gap-actions-md)}._size-md_8fyu4_18 ._without-title_8fyu4_24 ._icon-wrapper_8fyu4_24{margin-top:-2px}._size-lg_8fyu4_27{--padding: var(--components-dimensions-alert-padding-inline-lg);--gap: var(--components-dimensions-alert-gap-content-lg)}._size-lg_8fyu4_27 ._content-actions_8fyu4_21{--gap: var(--components-dimensions-alert-gap-actions-lg)}._variant-ai_8fyu4_34{--backgroundColor: var(--components-colors-alert-color-background-ai);--borderColor: transparent;background:linear-gradient(var(--components-colors-alert-color-background-ai) 0 0) padding-box,linear-gradient(90deg,var(--color-green-30) 0%,var(--color-teal-40) 20%,var(--color-blue-40) 40%,var(--color-violet-40) 60%,var(--color-pink-40) 80%,var(--color-red-orange-40) 100%) border-box}._variant-danger_8fyu4_39{--backgroundColor: var(--components-colors-alert-color-background-danger);--borderColor: var(--components-colors-alert-color-background-danger);--color: var(--color-icon-danger-primary)}._variant-info_8fyu4_44{--backgroundColor: var(--components-colors-alert-color-background-information);--borderColor: var(--components-colors-alert-color-background-information);--color: var(--color-icon-accent-blue-primary)}._variant-success_8fyu4_49{--backgroundColor: var(--components-colors-alert-color-background-success);--borderColor: var(--components-colors-alert-color-background-success);--color: var(--color-icon-accent-green-primary)}._variant-warning_8fyu4_54{--backgroundColor: var(--components-colors-alert-color-background-warning);--borderColor: var(--components-colors-alert-color-background-warning);--color: var(--color-icon-warning-primary)}._full-width_8fyu4_59{--maxWidth: 100%}._content_8fyu4_21{overflow:hidden;display:flex;flex-direction:column;justify-content:space-between;align-items:flex-start;gap:var(--gap, var(--components-dimensions-alert-gap-content-md))}._content-text_8fyu4_71{display:flex;flex-direction:column;gap:var(--gap, var(--components-dimensions-alert-gap-content-md))}._content-text_8fyu4_71._without-title_8fyu4_24{flex-direction:row}._content-text_8fyu4_71._without-title_8fyu4_24 ._icon-wrapper_8fyu4_24{align-self:flex-start}._content-actions_8fyu4_21{display:flex;align-items:center;gap:var(--gap)}._title-close-button_8fyu4_88{margin-right:var(--spacing-xl)}._title-with-icon_8fyu4_91{display:flex;align-items:center;gap:var(--spacing-sm)}._close-button_8fyu4_97{position:absolute;right:var(--spacing-sm);top:var(--spacing-sm)}._icon-wrapper_8fyu4_24{display:flex;flex-shrink:0;padding:var(--components-dimensions-alert-icon-padding-block);border-radius:var(--components-dimensions-alert-icon-border-radius);background-color:var(--iconWrapperBackgroundColor, var(--components-colors-alert-icon-color-background-brand));color:var(--iconWrapperColor, var(--components-colors-alert-icon-color-icon-brand))}._icon-wrapper-success_8fyu4_111{--iconWrapperBackgroundColor: var(--components-colors-alert-icon-color-background-success);--iconWrapperColor: var(--components-colors-alert-icon-color-icon-success)}._icon-wrapper-danger_8fyu4_115{--iconWrapperBackgroundColor: var(--components-colors-alert-icon-color-background-danger);--iconWrapperColor: var(--components-colors-alert-icon-color-icon-danger)}._icon-wrapper-info_8fyu4_119{--iconWrapperBackgroundColor: var( --components-colors-alert-icon-color-background-information );--iconWrapperColor: var(--components-colors-alert-icon-color-icon-information)}._icon-wrapper-warning_8fyu4_125{--iconWrapperBackgroundColor: var(--components-colors-alert-icon-color-background-warning);--iconWrapperColor: var(--components-colors-alert-icon-color-icon-warning)}._icon-wrapper-ai_8fyu4_129{background:conic-gradient(from 30deg at 50% 50%,var(--color-green-30) 0deg,var(--color-blue-40) 25.96deg,var(--color-violet-40) 51.92deg,var(--color-pink-40) 76.15deg,var(--color-red-orange-40) 110.77deg,var(--color-pink-40) 162.69deg,var(--color-violet-40) 209.42deg,var(--color-blue-40) 254.42deg,var(--color-teal-40) 306.35deg,var(--color-green-30) 360deg);--iconWrapperColor: var(--components-colors-alert-icon-color-icon-ai)}}
|
package/dist/Alert.js
CHANGED
|
@@ -1,105 +1,105 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import './Alert.css';
|
|
3
|
-
import { jsx as i, jsxs as
|
|
4
|
-
import p, { forwardRef as
|
|
3
|
+
import { jsx as i, jsxs as l } from "react/jsx-runtime";
|
|
4
|
+
import p, { forwardRef as y, Children as f, cloneElement as m } from "react";
|
|
5
5
|
import { CloseButton as E } from "./CloseButton.js";
|
|
6
6
|
import { Icon as V } from "./Icon.js";
|
|
7
|
-
import { Text as
|
|
8
|
-
import { c as
|
|
9
|
-
import { Button as
|
|
10
|
-
const I = "
|
|
7
|
+
import { Text as b } from "./Text.js";
|
|
8
|
+
import { c as x } from "./index-PAaZGbyz.js";
|
|
9
|
+
import { Button as h } from "./Button.js";
|
|
10
|
+
const I = "_root_8fyu4_2", O = "_content_8fyu4_21", B = {
|
|
11
11
|
root: I,
|
|
12
|
-
"size-md": "_size-
|
|
13
|
-
"content-actions": "_content-
|
|
14
|
-
"without-title": "_without-
|
|
15
|
-
"icon-wrapper": "_icon-
|
|
16
|
-
"size-lg": "_size-
|
|
17
|
-
"variant-ai": "_variant-
|
|
18
|
-
"variant-danger": "_variant-
|
|
19
|
-
"variant-info": "_variant-
|
|
20
|
-
"variant-success": "_variant-
|
|
21
|
-
"variant-warning": "_variant-
|
|
22
|
-
"full-width": "_full-
|
|
12
|
+
"size-md": "_size-md_8fyu4_18",
|
|
13
|
+
"content-actions": "_content-actions_8fyu4_21",
|
|
14
|
+
"without-title": "_without-title_8fyu4_24",
|
|
15
|
+
"icon-wrapper": "_icon-wrapper_8fyu4_24",
|
|
16
|
+
"size-lg": "_size-lg_8fyu4_27",
|
|
17
|
+
"variant-ai": "_variant-ai_8fyu4_34",
|
|
18
|
+
"variant-danger": "_variant-danger_8fyu4_39",
|
|
19
|
+
"variant-info": "_variant-info_8fyu4_44",
|
|
20
|
+
"variant-success": "_variant-success_8fyu4_49",
|
|
21
|
+
"variant-warning": "_variant-warning_8fyu4_54",
|
|
22
|
+
"full-width": "_full-width_8fyu4_59",
|
|
23
23
|
content: O,
|
|
24
|
-
"content-text": "_content-
|
|
25
|
-
"title-close-button": "_title-close-
|
|
26
|
-
"title-with-icon": "_title-with-
|
|
27
|
-
"close-button": "_close-
|
|
28
|
-
"icon-wrapper-success": "_icon-wrapper-
|
|
29
|
-
"icon-wrapper-danger": "_icon-wrapper-
|
|
30
|
-
"icon-wrapper-info": "_icon-wrapper-
|
|
31
|
-
"icon-wrapper-warning": "_icon-wrapper-
|
|
32
|
-
"icon-wrapper-ai": "_icon-wrapper-
|
|
33
|
-
},
|
|
34
|
-
({ variant: t = "primary", ...o }, n) => /* @__PURE__ */ i(
|
|
24
|
+
"content-text": "_content-text_8fyu4_71",
|
|
25
|
+
"title-close-button": "_title-close-button_8fyu4_88",
|
|
26
|
+
"title-with-icon": "_title-with-icon_8fyu4_91",
|
|
27
|
+
"close-button": "_close-button_8fyu4_97",
|
|
28
|
+
"icon-wrapper-success": "_icon-wrapper-success_8fyu4_111",
|
|
29
|
+
"icon-wrapper-danger": "_icon-wrapper-danger_8fyu4_115",
|
|
30
|
+
"icon-wrapper-info": "_icon-wrapper-info_8fyu4_119",
|
|
31
|
+
"icon-wrapper-warning": "_icon-wrapper-warning_8fyu4_125",
|
|
32
|
+
"icon-wrapper-ai": "_icon-wrapper-ai_8fyu4_129"
|
|
33
|
+
}, w = y(
|
|
34
|
+
({ variant: t = "primary", ...o }, n) => /* @__PURE__ */ i(h, { className: "shrink-0 w-fit", ref: n, variant: t, ...o })
|
|
35
35
|
);
|
|
36
|
-
|
|
37
|
-
const
|
|
38
|
-
({ variant: t = "secondary", ...o }, n) => /* @__PURE__ */ i(
|
|
36
|
+
w.displayName = "Alert.Button";
|
|
37
|
+
const d = y(
|
|
38
|
+
({ variant: t = "secondary", ...o }, n) => /* @__PURE__ */ i(h, { className: "shrink-0 w-fit", ref: n, variant: t, ...o })
|
|
39
39
|
);
|
|
40
|
-
|
|
41
|
-
const R =
|
|
42
|
-
|
|
43
|
-
const a =
|
|
40
|
+
d.displayName = "Alert.SecondaryButton";
|
|
41
|
+
const R = x(B), _ = ({ children: t, hasCloseButton: o, ...n }) => /* @__PURE__ */ i(b, { as: "span", className: R(o && "title-close-button"), ...n, children: t });
|
|
42
|
+
_.displayName = "Alert.Title";
|
|
43
|
+
const a = x(B), z = {
|
|
44
44
|
ai: "sparkles",
|
|
45
45
|
brand: "lightbulb-alt",
|
|
46
46
|
danger: "exclamation-octagon",
|
|
47
47
|
info: "info-circle",
|
|
48
48
|
success: "check-circle",
|
|
49
49
|
warning: "exclamation-triangle"
|
|
50
|
-
},
|
|
51
|
-
({ children: t, className: o, cta: n, handleClose:
|
|
52
|
-
const
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
hasCloseButton: !!
|
|
50
|
+
}, $ = y(
|
|
51
|
+
({ children: t, className: o, cta: n, handleClose: u, isFullWidth: k, size: c = "md", variant: s = "brand", ...T }, C) => {
|
|
52
|
+
const S = s === "ai", g = f.toArray(t).some((e) => p.isValidElement(e) ? e.type === _ : !1), v = /* @__PURE__ */ i("div", { className: a("icon-wrapper", `icon-wrapper-${s}`), children: /* @__PURE__ */ i(V, { name: z[s] }) }), j = f.toArray(t).map((e) => e.type === _ ? /* @__PURE__ */ l("div", { className: a("title-with-icon"), children: [
|
|
53
|
+
v,
|
|
54
|
+
m(e, {
|
|
55
|
+
hasCloseButton: !!u,
|
|
56
56
|
variant: `body-${c}-strong`
|
|
57
57
|
})
|
|
58
|
-
] }) : e),
|
|
58
|
+
] }) : e), N = (e) => f.toArray(e).flatMap((r) => p.isValidElement(r) && r.type === p.Fragment ? N(r.props.children) : r.type === w ? m(r, {
|
|
59
59
|
size: c,
|
|
60
|
-
variant:
|
|
61
|
-
}) : r.type ===
|
|
60
|
+
variant: S ? "primary-ai" : void 0
|
|
61
|
+
}) : r.type === d ? m(r, {
|
|
62
62
|
size: c
|
|
63
|
-
}) : r),
|
|
64
|
-
return /* @__PURE__ */
|
|
63
|
+
}) : r), A = !!n && N(n);
|
|
64
|
+
return /* @__PURE__ */ l(
|
|
65
65
|
"div",
|
|
66
66
|
{
|
|
67
67
|
className: a(
|
|
68
68
|
"root",
|
|
69
|
-
|
|
69
|
+
k && "full-width",
|
|
70
70
|
`size-${c}`,
|
|
71
71
|
s && `variant-${s}`,
|
|
72
72
|
o
|
|
73
73
|
),
|
|
74
|
-
ref:
|
|
75
|
-
...
|
|
74
|
+
ref: C,
|
|
75
|
+
...T,
|
|
76
76
|
children: [
|
|
77
|
-
!!
|
|
78
|
-
/* @__PURE__ */
|
|
79
|
-
/* @__PURE__ */
|
|
80
|
-
|
|
77
|
+
!!u && /* @__PURE__ */ i(E, { className: a("close-button"), onClick: u }),
|
|
78
|
+
/* @__PURE__ */ l("div", { className: a("content"), children: [
|
|
79
|
+
/* @__PURE__ */ l(
|
|
80
|
+
b,
|
|
81
81
|
{
|
|
82
82
|
as: "div",
|
|
83
|
-
className: a("content-text", !
|
|
83
|
+
className: a("content-text", !g && "without-title"),
|
|
84
84
|
variant: `body-${c}`,
|
|
85
85
|
children: [
|
|
86
|
-
!
|
|
87
|
-
|
|
86
|
+
!g && v,
|
|
87
|
+
j
|
|
88
88
|
]
|
|
89
89
|
}
|
|
90
90
|
),
|
|
91
|
-
!!
|
|
91
|
+
!!A && /* @__PURE__ */ i("div", { className: a("content-actions"), children: A })
|
|
92
92
|
] })
|
|
93
93
|
]
|
|
94
94
|
}
|
|
95
95
|
);
|
|
96
96
|
}
|
|
97
97
|
);
|
|
98
|
-
|
|
99
|
-
const K = Object.assign(
|
|
100
|
-
Button:
|
|
101
|
-
SecondaryButton:
|
|
102
|
-
Title:
|
|
98
|
+
$.displayName = "Alert";
|
|
99
|
+
const K = Object.assign($, {
|
|
100
|
+
Button: w,
|
|
101
|
+
SecondaryButton: d,
|
|
102
|
+
Title: _
|
|
103
103
|
});
|
|
104
104
|
export {
|
|
105
105
|
K as Alert,
|