virtual-ui-lib 1.0.11 → 1.0.13

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.
Files changed (3) hide show
  1. package/dist/index.js +42 -355
  2. package/dist/index.mjs +43 -347
  3. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -29,369 +29,56 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
29
29
  // src/index.js
30
30
  var index_exports = {};
31
31
  __export(index_exports, {
32
- Alert: () => Alert,
33
- AnimatedButton: () => AnimatedButton,
34
- Avatar: () => Avatar,
35
- Badge: () => Badge,
36
- Button: () => Button,
37
- Card: () => Card,
38
- Input: () => Input,
39
- Modal: () => Modal,
40
- ProgressBar: () => ProgressBar,
41
- Spinner: () => Spinner
32
+ AlertBanner: () => AlertBanner
42
33
  });
43
34
  module.exports = __toCommonJS(index_exports);
44
35
 
45
- // src/components/Button/Button.jsx
36
+ // src/components/AlertBanner/AlertBanner.jsx
46
37
  var import_react = __toESM(require("react"));
47
- var Button = ({
48
- text = "Button",
49
- bg = "#2563eb",
50
- color = "white",
51
- size = "md",
52
- width = "auto",
53
- radius = "6px",
54
- border = "none",
55
- weight = "500",
56
- shadow = "none",
57
- disabled = false,
58
- loading = false,
59
- icon = null,
60
- onClick
38
+ var AlertBanner = ({
39
+ message = "This is an alert message.",
40
+ type = "info",
41
+ onDismiss
61
42
  }) => {
62
- const sizes = {
63
- sm: "6px 12px",
64
- md: "8px 16px",
65
- lg: "12px 20px"
43
+ const [visible, setVisible] = (0, import_react.useState)(true);
44
+ const [fade, setFade] = (0, import_react.useState)(false);
45
+ const colors = {
46
+ success: { background: "#059669", color: "white" },
47
+ error: { background: "#dc2626", color: "white" },
48
+ warning: { background: "#f59e0b", color: "black" },
49
+ info: { background: "#2563eb", color: "white" }
66
50
  };
67
- return /* @__PURE__ */ import_react.default.createElement(
68
- "button",
69
- {
70
- onClick,
71
- disabled: disabled || loading,
72
- style: {
73
- background: bg,
74
- color,
75
- padding: sizes[size],
76
- width,
77
- border,
78
- borderRadius: radius,
79
- cursor: disabled ? "not-allowed" : "pointer",
80
- fontWeight: weight,
81
- boxShadow: shadow,
82
- opacity: disabled ? 0.6 : 1,
83
- display: "flex",
84
- alignItems: "center",
85
- gap: "6px",
86
- justifyContent: "center"
87
- }
88
- },
89
- loading ? "Loading..." : /* @__PURE__ */ import_react.default.createElement(import_react.default.Fragment, null, icon, text)
90
- );
91
- };
92
-
93
- // src/components/Card/Card.jsx
94
- var import_react2 = __toESM(require("react"));
95
- var Card = ({
96
- title = "Card Title",
97
- text = "Card description",
98
- width = "250px",
99
- bg = "white",
100
- border = "1px solid #eee",
101
- radius = "8px",
102
- padding = "16px",
103
- shadow = "0 2px 6px rgba(0,0,0,0.05)",
104
- titleSize = "18px",
105
- textSize = "14px",
106
- align = "left",
107
- children
108
- }) => {
109
- return /* @__PURE__ */ import_react2.default.createElement(
110
- "div",
111
- {
112
- style: {
113
- width,
114
- background: bg,
115
- border,
116
- borderRadius: radius,
117
- padding,
118
- boxShadow: shadow,
119
- textAlign: align
120
- }
121
- },
122
- /* @__PURE__ */ import_react2.default.createElement("h3", { style: { fontSize: titleSize, marginBottom: "8px" } }, title),
123
- /* @__PURE__ */ import_react2.default.createElement("p", { style: { fontSize: textSize, marginBottom: "10px" } }, text),
124
- children
125
- );
126
- };
127
-
128
- // src/components/Input/Input.jsx
129
- var import_react3 = __toESM(require("react"));
130
- var Input = ({
131
- placeholder = "Enter text",
132
- type = "text",
133
- width = "200px",
134
- bg = "white",
135
- color = "#111",
136
- border = "1px solid #ccc",
137
- radius = "6px",
138
- shadow = "none",
139
- size = "md",
140
- disabled = false,
141
- value,
142
- onChange
143
- }) => {
144
- const sizes = {
145
- sm: "6px",
146
- md: "8px",
147
- lg: "12px"
148
- };
149
- return /* @__PURE__ */ import_react3.default.createElement(
150
- "input",
151
- {
152
- type,
153
- placeholder,
154
- value,
155
- onChange,
156
- disabled,
157
- style: {
158
- width,
159
- padding: sizes[size],
160
- background: bg,
161
- color,
162
- border,
163
- borderRadius: radius,
164
- boxShadow: shadow,
165
- outline: "none",
166
- opacity: disabled ? 0.6 : 1
167
- }
168
- }
169
- );
170
- };
171
-
172
- // src/components/Badge/Badge.jsx
173
- var import_react4 = __toESM(require("react"));
174
- var Badge = ({
175
- text = "NEW",
176
- color = "#ffffff",
177
- bgColor = "#2563eb",
178
- radius = "12px"
179
- }) => {
180
- return /* @__PURE__ */ import_react4.default.createElement("div", { style: {
181
- background: bgColor,
182
- color,
183
- borderRadius: radius,
184
- padding: "8px 12px",
185
- fontSize: "14px",
186
- fontWeight: "600",
187
- display: "inline-block",
188
- boxShadow: "0 4px 10px rgba(0,0,0,0.2)",
189
- fontFamily: "system-ui, sans-serif"
190
- } }, text);
191
- };
192
-
193
- // src/components/Alert/Alert.jsx
194
- var import_react5 = __toESM(require("react"));
195
- var Alert = ({
196
- text = "Alert message",
197
- bg = "#facc15",
198
- color = "#111",
199
- radius = "6px",
200
- padding = "10px",
201
- width = "auto"
202
- }) => {
203
- return /* @__PURE__ */ import_react5.default.createElement(
204
- "div",
205
- {
206
- style: {
207
- background: bg,
208
- color,
209
- padding,
210
- borderRadius: radius,
211
- width
212
- }
213
- },
214
- text
215
- );
216
- };
217
-
218
- // src/components/Avatar/Avatar.jsx
219
- var import_react6 = __toESM(require("react"));
220
- var Avatar = ({
221
- src = "\u{1F464}",
222
- size = "40px",
223
- radius = "50%"
224
- }) => {
225
- return /* @__PURE__ */ import_react6.default.createElement(
226
- "img",
227
- {
228
- src,
229
- alt: "avatar",
230
- style: {
231
- width: size,
232
- height: size,
233
- borderRadius: radius,
234
- objectFit: "cover"
235
- }
236
- }
237
- );
238
- };
239
-
240
- // src/components/Spinner/Spinner.jsx
241
- var import_react7 = __toESM(require("react"));
242
- var Spinner = ({
243
- size = "30px",
244
- color = "#2563eb",
245
- border = "3px"
246
- }) => {
247
- return /* @__PURE__ */ import_react7.default.createElement(import_react7.default.Fragment, null, /* @__PURE__ */ import_react7.default.createElement("style", null, `
248
- @keyframes vui-spin {
249
- to {
250
- transform: rotate(360deg);
251
- }
252
- }
253
- `), /* @__PURE__ */ import_react7.default.createElement(
254
- "div",
255
- {
256
- style: {
257
- width: size,
258
- height: size,
259
- border: `${border} solid #eee`,
260
- borderTop: `${border} solid ${color}`,
261
- borderRadius: "50%",
262
- animation: "vui-spin 1s linear infinite"
263
- }
51
+ (0, import_react.useEffect)(() => {
52
+ if (!visible) {
53
+ setFade(true);
54
+ const timeout = setTimeout(() => onDismiss && onDismiss(), 300);
55
+ return () => clearTimeout(timeout);
264
56
  }
265
- ));
266
- };
267
-
268
- // src/components/Modal/Modal.jsx
269
- var import_react8 = __toESM(require("react"));
270
- var Modal = ({
271
- open = false,
272
- title = "Modal Title",
273
- children,
274
- width = "300px",
275
- bg = "white",
276
- radius = "8px",
277
- onClose
278
- }) => {
279
- if (!open) return null;
280
- return /* @__PURE__ */ import_react8.default.createElement(
281
- "div",
282
- {
283
- style: {
284
- position: "fixed",
285
- top: 0,
286
- left: 0,
287
- width: "100%",
288
- height: "100%",
289
- background: "rgba(0,0,0,0.3)",
290
- display: "flex",
291
- alignItems: "center",
292
- justifyContent: "center"
293
- }
294
- },
295
- /* @__PURE__ */ import_react8.default.createElement(
296
- "div",
297
- {
298
- style: {
299
- width,
300
- background: bg,
301
- borderRadius: radius,
302
- padding: "20px"
303
- }
304
- },
305
- /* @__PURE__ */ import_react8.default.createElement("h3", null, title),
306
- children,
307
- /* @__PURE__ */ import_react8.default.createElement("button", { onClick: onClose }, "Close")
308
- )
309
- );
310
- };
311
-
312
- // src/components/ProgressBar/ProgressBar.jsx
313
- var import_react9 = __toESM(require("react"));
314
- var ProgressBar = ({
315
- progress = 50,
316
- height = "20px",
317
- bgColor = "#2563eb",
318
- trackColor = "#d1d5db",
319
- radius = "10px",
320
- label = "Progress",
321
- textColor = "#ffffff"
322
- }) => {
323
- return /* @__PURE__ */ import_react9.default.createElement("div", { style: { width: "100%", background: trackColor, borderRadius: radius, overflow: "hidden" } }, /* @__PURE__ */ import_react9.default.createElement("div", { style: {
324
- width: progress + "%",
325
- height,
326
- background: bgColor,
327
- borderRadius: radius,
328
- display: "flex",
329
- alignItems: "center",
330
- justifyContent: "center",
331
- position: "relative"
332
- } }, /* @__PURE__ */ import_react9.default.createElement("span", { style: { color: textColor, fontWeight: "600", fontSize: "14px" } }, label, ": ", progress, "%")));
333
- };
334
-
335
- // src/components/AnimatedButton/AnimatedButton.jsx
336
- var import_react10 = __toESM(require("react"));
337
- var AnimatedButton = ({
338
- text = "Click Me",
339
- gradient = "linear-gradient(45deg, #2563eb, #7c3aed)",
340
- color = "white",
341
- size = "md",
342
- width = "auto",
343
- radius = "12px",
344
- shadow = "0 4px 14px rgba(0, 0, 0, 0.2)",
345
- loading = false,
346
- onClick
347
- }) => {
348
- const sizes = { sm: "8px 16px", md: "12px 24px", lg: "16px 32px" };
349
- const handleMouseEnter = (e) => {
350
- e.target.style.transform = "scale(1.05)";
351
- };
352
- const handleMouseLeave = (e) => {
353
- e.target.style.transform = "scale(1)";
354
- };
355
- return /* @__PURE__ */ import_react10.default.createElement(
356
- "button",
357
- {
358
- onClick,
359
- onMouseEnter: handleMouseEnter,
360
- onMouseLeave: handleMouseLeave,
361
- disabled: loading,
362
- style: {
363
- background: gradient,
364
- color,
365
- padding: sizes[size],
366
- width,
367
- border: "none",
368
- borderRadius: radius,
369
- boxShadow: shadow,
370
- cursor: loading ? "not-allowed" : "pointer",
371
- fontWeight: "600",
372
- fontSize: "15px",
373
- transition: "transform 0.3s, box-shadow 0.3s",
374
- fontFamily: "system-ui, sans-serif",
375
- opacity: loading ? 0.6 : 1,
376
- display: "flex",
377
- alignItems: "center",
378
- justifyContent: "center",
379
- gap: "8px"
380
- }
381
- },
382
- loading ? "Loading..." : text
383
- );
57
+ }, [visible, onDismiss]);
58
+ return /* @__PURE__ */ import_react.default.createElement("div", { style: {
59
+ position: "relative",
60
+ width: "100%",
61
+ background: colors[type].background,
62
+ color: colors[type].color,
63
+ padding: "16px 24px",
64
+ borderRadius: "8px",
65
+ boxShadow: "0 2px 10px rgba(0,0,0,0.2)",
66
+ transition: "opacity 0.3s ease, transform 0.3s ease",
67
+ transform: `translateY(${visible ? "0" : "-20px"})`,
68
+ opacity: fade ? 0 : 1,
69
+ zIndex: 1e3
70
+ }, className: visible ? "slide-down" : "fade-out" }, message, /* @__PURE__ */ import_react.default.createElement("button", { onClick: () => setVisible(false), style: {
71
+ position: "absolute",
72
+ top: "10px",
73
+ right: "10px",
74
+ background: "transparent",
75
+ color: "inherit",
76
+ border: "none",
77
+ cursor: "pointer",
78
+ fontSize: "16px"
79
+ } }, "\u2715"));
384
80
  };
385
81
  // Annotate the CommonJS export names for ESM import in node:
386
82
  0 && (module.exports = {
387
- Alert,
388
- AnimatedButton,
389
- Avatar,
390
- Badge,
391
- Button,
392
- Card,
393
- Input,
394
- Modal,
395
- ProgressBar,
396
- Spinner
83
+ AlertBanner
397
84
  });
package/dist/index.mjs CHANGED
@@ -1,352 +1,48 @@
1
- // src/components/Button/Button.jsx
2
- import React from "react";
3
- var Button = ({
4
- text = "Button",
5
- bg = "#2563eb",
6
- color = "white",
7
- size = "md",
8
- width = "auto",
9
- radius = "6px",
10
- border = "none",
11
- weight = "500",
12
- shadow = "none",
13
- disabled = false,
14
- loading = false,
15
- icon = null,
16
- onClick
17
- }) => {
18
- const sizes = {
19
- sm: "6px 12px",
20
- md: "8px 16px",
21
- lg: "12px 20px"
22
- };
23
- return /* @__PURE__ */ React.createElement(
24
- "button",
25
- {
26
- onClick,
27
- disabled: disabled || loading,
28
- style: {
29
- background: bg,
30
- color,
31
- padding: sizes[size],
32
- width,
33
- border,
34
- borderRadius: radius,
35
- cursor: disabled ? "not-allowed" : "pointer",
36
- fontWeight: weight,
37
- boxShadow: shadow,
38
- opacity: disabled ? 0.6 : 1,
39
- display: "flex",
40
- alignItems: "center",
41
- gap: "6px",
42
- justifyContent: "center"
43
- }
44
- },
45
- loading ? "Loading..." : /* @__PURE__ */ React.createElement(React.Fragment, null, icon, text)
46
- );
47
- };
48
-
49
- // src/components/Card/Card.jsx
50
- import React2 from "react";
51
- var Card = ({
52
- title = "Card Title",
53
- text = "Card description",
54
- width = "250px",
55
- bg = "white",
56
- border = "1px solid #eee",
57
- radius = "8px",
58
- padding = "16px",
59
- shadow = "0 2px 6px rgba(0,0,0,0.05)",
60
- titleSize = "18px",
61
- textSize = "14px",
62
- align = "left",
63
- children
64
- }) => {
65
- return /* @__PURE__ */ React2.createElement(
66
- "div",
67
- {
68
- style: {
69
- width,
70
- background: bg,
71
- border,
72
- borderRadius: radius,
73
- padding,
74
- boxShadow: shadow,
75
- textAlign: align
76
- }
77
- },
78
- /* @__PURE__ */ React2.createElement("h3", { style: { fontSize: titleSize, marginBottom: "8px" } }, title),
79
- /* @__PURE__ */ React2.createElement("p", { style: { fontSize: textSize, marginBottom: "10px" } }, text),
80
- children
81
- );
82
- };
83
-
84
- // src/components/Input/Input.jsx
85
- import React3 from "react";
86
- var Input = ({
87
- placeholder = "Enter text",
88
- type = "text",
89
- width = "200px",
90
- bg = "white",
91
- color = "#111",
92
- border = "1px solid #ccc",
93
- radius = "6px",
94
- shadow = "none",
95
- size = "md",
96
- disabled = false,
97
- value,
98
- onChange
99
- }) => {
100
- const sizes = {
101
- sm: "6px",
102
- md: "8px",
103
- lg: "12px"
1
+ // src/components/AlertBanner/AlertBanner.jsx
2
+ import React, { useState, useEffect } from "react";
3
+ var AlertBanner = ({
4
+ message = "This is an alert message.",
5
+ type = "info",
6
+ onDismiss
7
+ }) => {
8
+ const [visible, setVisible] = useState(true);
9
+ const [fade, setFade] = useState(false);
10
+ const colors = {
11
+ success: { background: "#059669", color: "white" },
12
+ error: { background: "#dc2626", color: "white" },
13
+ warning: { background: "#f59e0b", color: "black" },
14
+ info: { background: "#2563eb", color: "white" }
104
15
  };
105
- return /* @__PURE__ */ React3.createElement(
106
- "input",
107
- {
108
- type,
109
- placeholder,
110
- value,
111
- onChange,
112
- disabled,
113
- style: {
114
- width,
115
- padding: sizes[size],
116
- background: bg,
117
- color,
118
- border,
119
- borderRadius: radius,
120
- boxShadow: shadow,
121
- outline: "none",
122
- opacity: disabled ? 0.6 : 1
123
- }
124
- }
125
- );
126
- };
127
-
128
- // src/components/Badge/Badge.jsx
129
- import React4 from "react";
130
- var Badge = ({
131
- text = "NEW",
132
- color = "#ffffff",
133
- bgColor = "#2563eb",
134
- radius = "12px"
135
- }) => {
136
- return /* @__PURE__ */ React4.createElement("div", { style: {
137
- background: bgColor,
138
- color,
139
- borderRadius: radius,
140
- padding: "8px 12px",
141
- fontSize: "14px",
142
- fontWeight: "600",
143
- display: "inline-block",
144
- boxShadow: "0 4px 10px rgba(0,0,0,0.2)",
145
- fontFamily: "system-ui, sans-serif"
146
- } }, text);
147
- };
148
-
149
- // src/components/Alert/Alert.jsx
150
- import React5 from "react";
151
- var Alert = ({
152
- text = "Alert message",
153
- bg = "#facc15",
154
- color = "#111",
155
- radius = "6px",
156
- padding = "10px",
157
- width = "auto"
158
- }) => {
159
- return /* @__PURE__ */ React5.createElement(
160
- "div",
161
- {
162
- style: {
163
- background: bg,
164
- color,
165
- padding,
166
- borderRadius: radius,
167
- width
168
- }
169
- },
170
- text
171
- );
172
- };
173
-
174
- // src/components/Avatar/Avatar.jsx
175
- import React6 from "react";
176
- var Avatar = ({
177
- src = "\u{1F464}",
178
- size = "40px",
179
- radius = "50%"
180
- }) => {
181
- return /* @__PURE__ */ React6.createElement(
182
- "img",
183
- {
184
- src,
185
- alt: "avatar",
186
- style: {
187
- width: size,
188
- height: size,
189
- borderRadius: radius,
190
- objectFit: "cover"
191
- }
192
- }
193
- );
194
- };
195
-
196
- // src/components/Spinner/Spinner.jsx
197
- import React7 from "react";
198
- var Spinner = ({
199
- size = "30px",
200
- color = "#2563eb",
201
- border = "3px"
202
- }) => {
203
- return /* @__PURE__ */ React7.createElement(React7.Fragment, null, /* @__PURE__ */ React7.createElement("style", null, `
204
- @keyframes vui-spin {
205
- to {
206
- transform: rotate(360deg);
207
- }
208
- }
209
- `), /* @__PURE__ */ React7.createElement(
210
- "div",
211
- {
212
- style: {
213
- width: size,
214
- height: size,
215
- border: `${border} solid #eee`,
216
- borderTop: `${border} solid ${color}`,
217
- borderRadius: "50%",
218
- animation: "vui-spin 1s linear infinite"
219
- }
16
+ useEffect(() => {
17
+ if (!visible) {
18
+ setFade(true);
19
+ const timeout = setTimeout(() => onDismiss && onDismiss(), 300);
20
+ return () => clearTimeout(timeout);
220
21
  }
221
- ));
222
- };
223
-
224
- // src/components/Modal/Modal.jsx
225
- import React8 from "react";
226
- var Modal = ({
227
- open = false,
228
- title = "Modal Title",
229
- children,
230
- width = "300px",
231
- bg = "white",
232
- radius = "8px",
233
- onClose
234
- }) => {
235
- if (!open) return null;
236
- return /* @__PURE__ */ React8.createElement(
237
- "div",
238
- {
239
- style: {
240
- position: "fixed",
241
- top: 0,
242
- left: 0,
243
- width: "100%",
244
- height: "100%",
245
- background: "rgba(0,0,0,0.3)",
246
- display: "flex",
247
- alignItems: "center",
248
- justifyContent: "center"
249
- }
250
- },
251
- /* @__PURE__ */ React8.createElement(
252
- "div",
253
- {
254
- style: {
255
- width,
256
- background: bg,
257
- borderRadius: radius,
258
- padding: "20px"
259
- }
260
- },
261
- /* @__PURE__ */ React8.createElement("h3", null, title),
262
- children,
263
- /* @__PURE__ */ React8.createElement("button", { onClick: onClose }, "Close")
264
- )
265
- );
266
- };
267
-
268
- // src/components/ProgressBar/ProgressBar.jsx
269
- import React9 from "react";
270
- var ProgressBar = ({
271
- progress = 50,
272
- height = "20px",
273
- bgColor = "#2563eb",
274
- trackColor = "#d1d5db",
275
- radius = "10px",
276
- label = "Progress",
277
- textColor = "#ffffff"
278
- }) => {
279
- return /* @__PURE__ */ React9.createElement("div", { style: { width: "100%", background: trackColor, borderRadius: radius, overflow: "hidden" } }, /* @__PURE__ */ React9.createElement("div", { style: {
280
- width: progress + "%",
281
- height,
282
- background: bgColor,
283
- borderRadius: radius,
284
- display: "flex",
285
- alignItems: "center",
286
- justifyContent: "center",
287
- position: "relative"
288
- } }, /* @__PURE__ */ React9.createElement("span", { style: { color: textColor, fontWeight: "600", fontSize: "14px" } }, label, ": ", progress, "%")));
289
- };
290
-
291
- // src/components/AnimatedButton/AnimatedButton.jsx
292
- import React10 from "react";
293
- var AnimatedButton = ({
294
- text = "Click Me",
295
- gradient = "linear-gradient(45deg, #2563eb, #7c3aed)",
296
- color = "white",
297
- size = "md",
298
- width = "auto",
299
- radius = "12px",
300
- shadow = "0 4px 14px rgba(0, 0, 0, 0.2)",
301
- loading = false,
302
- onClick
303
- }) => {
304
- const sizes = { sm: "8px 16px", md: "12px 24px", lg: "16px 32px" };
305
- const handleMouseEnter = (e) => {
306
- e.target.style.transform = "scale(1.05)";
307
- };
308
- const handleMouseLeave = (e) => {
309
- e.target.style.transform = "scale(1)";
310
- };
311
- return /* @__PURE__ */ React10.createElement(
312
- "button",
313
- {
314
- onClick,
315
- onMouseEnter: handleMouseEnter,
316
- onMouseLeave: handleMouseLeave,
317
- disabled: loading,
318
- style: {
319
- background: gradient,
320
- color,
321
- padding: sizes[size],
322
- width,
323
- border: "none",
324
- borderRadius: radius,
325
- boxShadow: shadow,
326
- cursor: loading ? "not-allowed" : "pointer",
327
- fontWeight: "600",
328
- fontSize: "15px",
329
- transition: "transform 0.3s, box-shadow 0.3s",
330
- fontFamily: "system-ui, sans-serif",
331
- opacity: loading ? 0.6 : 1,
332
- display: "flex",
333
- alignItems: "center",
334
- justifyContent: "center",
335
- gap: "8px"
336
- }
337
- },
338
- loading ? "Loading..." : text
339
- );
22
+ }, [visible, onDismiss]);
23
+ return /* @__PURE__ */ React.createElement("div", { style: {
24
+ position: "relative",
25
+ width: "100%",
26
+ background: colors[type].background,
27
+ color: colors[type].color,
28
+ padding: "16px 24px",
29
+ borderRadius: "8px",
30
+ boxShadow: "0 2px 10px rgba(0,0,0,0.2)",
31
+ transition: "opacity 0.3s ease, transform 0.3s ease",
32
+ transform: `translateY(${visible ? "0" : "-20px"})`,
33
+ opacity: fade ? 0 : 1,
34
+ zIndex: 1e3
35
+ }, className: visible ? "slide-down" : "fade-out" }, message, /* @__PURE__ */ React.createElement("button", { onClick: () => setVisible(false), style: {
36
+ position: "absolute",
37
+ top: "10px",
38
+ right: "10px",
39
+ background: "transparent",
40
+ color: "inherit",
41
+ border: "none",
42
+ cursor: "pointer",
43
+ fontSize: "16px"
44
+ } }, "\u2715"));
340
45
  };
341
46
  export {
342
- Alert,
343
- AnimatedButton,
344
- Avatar,
345
- Badge,
346
- Button,
347
- Card,
348
- Input,
349
- Modal,
350
- ProgressBar,
351
- Spinner
47
+ AlertBanner
352
48
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "virtual-ui-lib",
3
- "version": "1.0.11",
3
+ "version": "1.0.13",
4
4
  "description": "Virtual UI React Component Library",
5
5
  "author": "Ankush",
6
6
  "license": "ISC",