@beweco/aurora-ui 0.0.2 → 0.0.3

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 (87) hide show
  1. package/README.md +8 -8
  2. package/dist/index.cjs.js +286 -0
  3. package/dist/index.esm.js +278 -0
  4. package/dist/{esm → types}/index.d.ts +2 -2
  5. package/package.json +13 -9
  6. package/dist/cjs/__rslib_css__/styles/globals.cjs +0 -1
  7. package/dist/cjs/components/button/Button.cjs +0 -1
  8. package/dist/cjs/components/button/index.cjs +0 -1
  9. package/dist/cjs/components/icon/Icon.cjs +0 -1
  10. package/dist/cjs/components/icon/index.cjs +0 -1
  11. package/dist/cjs/contexts/theme/index.cjs +0 -1
  12. package/dist/cjs/contexts/theme/theme-context.cjs +0 -1
  13. package/dist/cjs/contexts/theme/theme-context.type.cjs +0 -1
  14. package/dist/cjs/index.cjs +0 -1
  15. package/dist/cjs/index.d.ts +0 -6
  16. package/dist/cjs/providers/theme/index.cjs +0 -1
  17. package/dist/cjs/providers/theme/theme-provider.cjs +0 -1
  18. package/dist/cjs/styles/colors.default.cjs +0 -1
  19. package/dist/esm/__rslib_css__/styles/globals.js +0 -0
  20. package/dist/esm/components/button/Button.d.ts +0 -8
  21. package/dist/esm/components/button/Button.d.ts.map +0 -1
  22. package/dist/esm/components/button/Button.js +0 -23
  23. package/dist/esm/components/button/Button.types.d.ts +0 -23
  24. package/dist/esm/components/button/Button.types.d.ts.map +0 -1
  25. package/dist/esm/components/button/Button.types.js +0 -0
  26. package/dist/esm/components/button/index.d.ts +0 -3
  27. package/dist/esm/components/button/index.d.ts.map +0 -1
  28. package/dist/esm/components/button/index.js +0 -3
  29. package/dist/esm/components/icon/Icon.d.ts +0 -9
  30. package/dist/esm/components/icon/Icon.d.ts.map +0 -1
  31. package/dist/esm/components/icon/Icon.js +0 -22
  32. package/dist/esm/components/icon/Icon.types.d.ts +0 -13
  33. package/dist/esm/components/icon/Icon.types.d.ts.map +0 -1
  34. package/dist/esm/components/icon/Icon.types.js +0 -0
  35. package/dist/esm/components/icon/index.d.ts +0 -4
  36. package/dist/esm/components/icon/index.d.ts.map +0 -1
  37. package/dist/esm/components/icon/index.js +0 -4
  38. package/dist/esm/contexts/theme/index.d.ts +0 -3
  39. package/dist/esm/contexts/theme/index.d.ts.map +0 -1
  40. package/dist/esm/contexts/theme/index.js +0 -1
  41. package/dist/esm/contexts/theme/theme-context.d.ts +0 -4
  42. package/dist/esm/contexts/theme/theme-context.d.ts.map +0 -1
  43. package/dist/esm/contexts/theme/theme-context.js +0 -11
  44. package/dist/esm/contexts/theme/theme-context.type.d.ts +0 -6
  45. package/dist/esm/contexts/theme/theme-context.type.d.ts.map +0 -1
  46. package/dist/esm/contexts/theme/theme-context.type.js +0 -0
  47. package/dist/esm/index.d.ts.map +0 -1
  48. package/dist/esm/index.js +0 -7
  49. package/dist/esm/providers/theme/index.d.ts +0 -3
  50. package/dist/esm/providers/theme/index.d.ts.map +0 -1
  51. package/dist/esm/providers/theme/index.js +0 -2
  52. package/dist/esm/providers/theme/theme-provider.d.ts +0 -4
  53. package/dist/esm/providers/theme/theme-provider.d.ts.map +0 -1
  54. package/dist/esm/providers/theme/theme-provider.js +0 -17
  55. package/dist/esm/providers/theme/theme-provider.types.d.ts +0 -5
  56. package/dist/esm/providers/theme/theme-provider.types.d.ts.map +0 -1
  57. package/dist/esm/providers/theme/theme-provider.types.js +0 -0
  58. package/dist/esm/styles/colors.default.d.ts +0 -179
  59. package/dist/esm/styles/colors.default.d.ts.map +0 -1
  60. package/dist/esm/styles/colors.default.js +0 -179
  61. /package/dist/{cjs → types}/components/button/Button.d.ts +0 -0
  62. /package/dist/{cjs → types}/components/button/Button.d.ts.map +0 -0
  63. /package/dist/{cjs → types}/components/button/Button.types.d.ts +0 -0
  64. /package/dist/{cjs → types}/components/button/Button.types.d.ts.map +0 -0
  65. /package/dist/{cjs → types}/components/button/index.d.ts +0 -0
  66. /package/dist/{cjs → types}/components/button/index.d.ts.map +0 -0
  67. /package/dist/{cjs → types}/components/icon/Icon.d.ts +0 -0
  68. /package/dist/{cjs → types}/components/icon/Icon.d.ts.map +0 -0
  69. /package/dist/{cjs → types}/components/icon/Icon.types.d.ts +0 -0
  70. /package/dist/{cjs → types}/components/icon/Icon.types.d.ts.map +0 -0
  71. /package/dist/{cjs → types}/components/icon/index.d.ts +0 -0
  72. /package/dist/{cjs → types}/components/icon/index.d.ts.map +0 -0
  73. /package/dist/{cjs → types}/contexts/theme/index.d.ts +0 -0
  74. /package/dist/{cjs → types}/contexts/theme/index.d.ts.map +0 -0
  75. /package/dist/{cjs → types}/contexts/theme/theme-context.d.ts +0 -0
  76. /package/dist/{cjs → types}/contexts/theme/theme-context.d.ts.map +0 -0
  77. /package/dist/{cjs → types}/contexts/theme/theme-context.type.d.ts +0 -0
  78. /package/dist/{cjs → types}/contexts/theme/theme-context.type.d.ts.map +0 -0
  79. /package/dist/{cjs → types}/index.d.ts.map +0 -0
  80. /package/dist/{cjs → types}/providers/theme/index.d.ts +0 -0
  81. /package/dist/{cjs → types}/providers/theme/index.d.ts.map +0 -0
  82. /package/dist/{cjs → types}/providers/theme/theme-provider.d.ts +0 -0
  83. /package/dist/{cjs → types}/providers/theme/theme-provider.d.ts.map +0 -0
  84. /package/dist/{cjs → types}/providers/theme/theme-provider.types.d.ts +0 -0
  85. /package/dist/{cjs → types}/providers/theme/theme-provider.types.d.ts.map +0 -0
  86. /package/dist/{cjs → types}/styles/colors.default.d.ts +0 -0
  87. /package/dist/{cjs → types}/styles/colors.default.d.ts.map +0 -0
package/README.md CHANGED
@@ -1,15 +1,15 @@
1
- # @beweco/aura-ui
1
+ # @beweco/aurora-ui
2
2
 
3
- Bewe Aura UI Component Library - A modern, lightweight, and customizable React component library.
3
+ Bewe Aurora UI Component Library - A modern, lightweight, and customizable React component library.
4
4
 
5
5
  ## Overview
6
6
 
7
- @beweco/aura-ui is a React component library designed to provide a consistent and beautiful user interface for Bewe applications. Built with TypeScript for type safety and modern development practices, it uses Storybook as its primary development and visualization environment.
7
+ @beweco/aurora-ui is a React component library designed to provide a consistent and beautiful user interface for Bewe applications. Built with TypeScript for type safety and modern development practices, it uses Storybook as its primary development and visualization environment.
8
8
 
9
9
  ## Installation
10
10
 
11
11
  ```bash
12
- bun install @beweco/aura-ui
12
+ bun install @beweco/aurora-ui
13
13
  ```
14
14
 
15
15
  ## Quick Start
@@ -17,14 +17,14 @@ bun install @beweco/aura-ui
17
17
  To use the components, you need to wrap your application with the `ThemeProvider` .
18
18
 
19
19
  ```tsx
20
- import { ThemeProvider } from '@beweco/aura-ui';
21
- import { Button } from '@beweco/aura-ui';
20
+ import { ThemeProvider } from '@beweco/aurora-ui';
21
+ import { Button } from '@beweco/aurora-ui';
22
22
 
23
23
  function App() {
24
24
  return (
25
25
  <ThemeProvider>
26
26
  <Button color="primary">
27
- Hello Aura UI!
27
+ Hello Aurora UI!
28
28
  </Button>
29
29
  </ThemeProvider>
30
30
  );
@@ -113,7 +113,7 @@ For testing purposes, you can publish a beta version:
113
113
 
114
114
  Users can then install the beta version using:
115
115
  ```bash
116
- bun install @beweco/aura-ui@beta
116
+ bun install @beweco/aurora-ui@beta
117
117
  ```
118
118
 
119
119
  ## Contributing
@@ -0,0 +1,286 @@
1
+ 'use strict';
2
+
3
+ var jsxRuntime = require('react/jsx-runtime');
4
+ var react$1 = require('@heroui/react');
5
+ var react = require('react');
6
+ var react$2 = require('@iconify/react');
7
+
8
+ /******************************************************************************
9
+ Copyright (c) Microsoft Corporation.
10
+
11
+ Permission to use, copy, modify, and/or distribute this software for any
12
+ purpose with or without fee is hereby granted.
13
+
14
+ THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
15
+ REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
16
+ AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
17
+ INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
18
+ LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
19
+ OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
20
+ PERFORMANCE OF THIS SOFTWARE.
21
+ ***************************************************************************** */
22
+ /* global Reflect, Promise, SuppressedError, Symbol, Iterator */
23
+
24
+
25
+ var __assign = function() {
26
+ __assign = Object.assign || function __assign(t) {
27
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
28
+ s = arguments[i];
29
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
30
+ }
31
+ return t;
32
+ };
33
+ return __assign.apply(this, arguments);
34
+ };
35
+
36
+ function __rest(s, e) {
37
+ var t = {};
38
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
39
+ t[p] = s[p];
40
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
41
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
42
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
43
+ t[p[i]] = s[p[i]];
44
+ }
45
+ return t;
46
+ }
47
+
48
+ typeof SuppressedError === "function" ? SuppressedError : function (error, suppressed, message) {
49
+ var e = new Error(message);
50
+ return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
51
+ };
52
+
53
+ /**
54
+ * Button component with HeroUI styling
55
+ * Provides a consistent interface for button interactions across the application
56
+ */
57
+ var ButtonPrueba = function (_a) {
58
+ var children = _a.children, startIcon = _a.startIcon, endIcon = _a.endIcon, _b = _a.loading, loading = _b === void 0 ? false : _b, disabled = _a.disabled, _c = _a.variant, variant = _c === void 0 ? "solid" : _c, _d = _a.color, color = _d === void 0 ? "primary" : _d, _e = _a.size, size = _e === void 0 ? "md" : _e, radius = _a.radius, _f = _a.fullWidth, fullWidth = _f === void 0 ? false : _f, _g = _a.className, className = _g === void 0 ? "" : _g, props = __rest(_a, ["children", "startIcon", "endIcon", "loading", "disabled", "variant", "color", "size", "radius", "fullWidth", "className"]);
59
+ react.useEffect(function () {
60
+ // biome-ignore lint/suspicious/noConsoleLog: <explanation>
61
+ console.log("estamos dentro del botnon");
62
+ }, []);
63
+ return (jsxRuntime.jsx(react$1.Button, __assign({ variant: variant, color: color, size: size, radius: radius, fullWidth: fullWidth, isLoading: loading, isDisabled: disabled, startContent: startIcon, endContent: endIcon, className: className }, props, { children: children })));
64
+ };
65
+
66
+ var sizeMap = {
67
+ sm: "16px",
68
+ md: "20px",
69
+ lg: "24px",
70
+ xl: "32px",
71
+ };
72
+ var IconComponent = function (_a) {
73
+ var icon = _a.icon, _b = _a.size, size = _b === void 0 ? "md" : _b, className = _a.className;
74
+ react.useEffect(function () {
75
+ // biome-ignore lint/suspicious/noConsoleLog: <explanation>
76
+ console.log("estamos dentro del icono");
77
+ }, []);
78
+ var iconSize = sizeMap[size];
79
+ return (jsxRuntime.jsx(react$2.Icon, { icon: icon, width: iconSize, height: iconSize, className: className }));
80
+ };
81
+
82
+ var themeColors = {
83
+ "purple-light": {
84
+ extend: "light",
85
+ colors: {
86
+ background: "#ffffff",
87
+ foreground: "#111827",
88
+ primary: {
89
+ 50: "#eee4f8",
90
+ 100: "#d7bfef",
91
+ 200: "#bf99e5",
92
+ 300: "#a773db",
93
+ 400: "#904ed2",
94
+ 500: "#7828c8",
95
+ 600: "#6321a5",
96
+ 700: "#4e1a82",
97
+ 800: "#39135f",
98
+ 900: "#240c3c",
99
+ DEFAULT: "#7828c8",
100
+ foreground: "#ffffff",
101
+ },
102
+ focus: "#904ed2",
103
+ },
104
+ },
105
+ "purple-dark": {
106
+ extend: "dark",
107
+ colors: {
108
+ background: "#1A1023",
109
+ foreground: "#ffffff",
110
+ primary: {
111
+ 50: "#2c193f",
112
+ 100: "#462764",
113
+ 200: "#603689",
114
+ 300: "#7944ae",
115
+ 400: "#9353d3",
116
+ 500: "#a671db",
117
+ 600: "#b98fe2",
118
+ 700: "#ccadee",
119
+ 800: "#dfcbf2",
120
+ 900: "#f2eafa",
121
+ DEFAULT: "#9353d3",
122
+ foreground: "#ffffff",
123
+ },
124
+ focus: "#a671db",
125
+ },
126
+ },
127
+ "green-light": {
128
+ extend: "light",
129
+ colors: {
130
+ background: "#ffffff",
131
+ foreground: "#111827",
132
+ primary: {
133
+ 50: "#ecf9f0",
134
+ 100: "#d1f0dc",
135
+ 200: "#b6e7c7",
136
+ 300: "#9cdeb3",
137
+ 400: "#81d59e",
138
+ 500: "#66cc8a",
139
+ 600: "#54a872",
140
+ 700: "#42855a",
141
+ 800: "#306142",
142
+ 900: "#1f3d29",
143
+ DEFAULT: "#66cc8a",
144
+ foreground: "#000000",
145
+ },
146
+ focus: "#81d59e",
147
+ },
148
+ },
149
+ "green-dark": {
150
+ extend: "dark",
151
+ colors: {
152
+ background: "#0F1D15",
153
+ foreground: "#ffffff",
154
+ primary: {
155
+ 50: "#1f3d29",
156
+ 100: "#306142",
157
+ 200: "#42855a",
158
+ 300: "#54a872",
159
+ 400: "#66cc8a",
160
+ 500: "#81d59e",
161
+ 600: "#9cdeb3",
162
+ 700: "#b6e7c7",
163
+ 800: "#d1f0dc",
164
+ 900: "#ecf9f0",
165
+ DEFAULT: "#66cc8a",
166
+ foreground: "#000000",
167
+ },
168
+ focus: "#81d59e",
169
+ },
170
+ },
171
+ "blue-light": {
172
+ extend: "light",
173
+ colors: {
174
+ background: "#ffffff",
175
+ foreground: "#111827",
176
+ primary: {
177
+ 50: "#eff6ff",
178
+ 100: "#dbeafe",
179
+ 200: "#bfdbfe",
180
+ 300: "#93c5fd",
181
+ 400: "#60a5fa",
182
+ 500: "#3b82f6",
183
+ 600: "#2563eb",
184
+ 700: "#1d4ed8",
185
+ 800: "#1e40af",
186
+ 900: "#1e3a8a",
187
+ DEFAULT: "#3b82f6",
188
+ foreground: "#ffffff",
189
+ },
190
+ focus: "#60a5fa",
191
+ },
192
+ },
193
+ "blue-dark": {
194
+ extend: "dark",
195
+ colors: {
196
+ background: "#101d3a",
197
+ foreground: "#ffffff",
198
+ primary: {
199
+ 50: "#1e3a8a",
200
+ 100: "#1e40af",
201
+ 200: "#1d4ed8",
202
+ 300: "#2563eb",
203
+ 400: "#3b82f6",
204
+ 500: "#60a5fa",
205
+ 600: "#93c5fd",
206
+ 700: "#bfdbfe",
207
+ 800: "#dbeafe",
208
+ 900: "#eff6ff",
209
+ DEFAULT: "#3b82f6",
210
+ foreground: "#ffffff",
211
+ },
212
+ focus: "#60a5fa",
213
+ },
214
+ },
215
+ "yellow-light": {
216
+ extend: "light",
217
+ colors: {
218
+ background: "#ffffff",
219
+ foreground: "#111827",
220
+ primary: {
221
+ 50: "#fefce8",
222
+ 100: "#fef9c3",
223
+ 200: "#fef08a",
224
+ 300: "#fde047",
225
+ 400: "#facc15",
226
+ 500: "#eab308",
227
+ 600: "#ca8a04",
228
+ 700: "#a16207",
229
+ 800: "#854d0e",
230
+ 900: "#713f12",
231
+ DEFAULT: "#eab308",
232
+ foreground: "#111827",
233
+ },
234
+ focus: "#facc15",
235
+ },
236
+ },
237
+ "yellow-dark": {
238
+ extend: "dark",
239
+ colors: {
240
+ background: "#18181b",
241
+ foreground: "#ffffff",
242
+ primary: {
243
+ 50: "#713f12",
244
+ 100: "#854d0e",
245
+ 200: "#a16207",
246
+ 300: "#ca8a04",
247
+ 400: "#eab308",
248
+ 500: "#facc15",
249
+ 600: "#fde047",
250
+ 700: "#fef08a",
251
+ 800: "#fef9c3",
252
+ 900: "#fefce8",
253
+ DEFAULT: "#facc15",
254
+ foreground: "#18181b",
255
+ },
256
+ focus: "#eab308",
257
+ },
258
+ },
259
+ };
260
+
261
+ var ThemeContext = react.createContext({
262
+ theme: "light",
263
+ // biome-ignore lint/suspicious/noEmptyBlockStatements: <explanation>
264
+ setTheme: function () { },
265
+ });
266
+ var useThemeContext = function () {
267
+ var context = react.useContext(ThemeContext);
268
+ if (!context) {
269
+ throw new Error("useThemeContext debe ser usado dentro de un ThemeProvider");
270
+ }
271
+ return context;
272
+ };
273
+
274
+ var ThemeProvider = function (_a) {
275
+ var children = _a.children;
276
+ var _b = useThemeContext(), theme = _b.theme, setTheme = _b.setTheme;
277
+ return (jsxRuntime.jsx(ThemeContext.Provider, { value: { theme: theme, setTheme: setTheme }, children: jsxRuntime.jsx("main", { className: "".concat(theme, " bg-background text-foreground "), children: children }) }));
278
+ };
279
+
280
+ exports.ButtonPrueba = ButtonPrueba;
281
+ exports.IconComponent = IconComponent;
282
+ exports.ThemeContext = ThemeContext;
283
+ exports.ThemeProvider = ThemeProvider;
284
+ exports.sizeMap = sizeMap;
285
+ exports.themeColors = themeColors;
286
+ exports.useThemeContext = useThemeContext;
@@ -0,0 +1,278 @@
1
+ import { jsx } from 'react/jsx-runtime';
2
+ import { Button } from '@heroui/react';
3
+ import { useEffect, createContext, useContext } from 'react';
4
+ import { Icon } from '@iconify/react';
5
+
6
+ /******************************************************************************
7
+ Copyright (c) Microsoft Corporation.
8
+
9
+ Permission to use, copy, modify, and/or distribute this software for any
10
+ purpose with or without fee is hereby granted.
11
+
12
+ THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
13
+ REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
14
+ AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
15
+ INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
16
+ LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
17
+ OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
18
+ PERFORMANCE OF THIS SOFTWARE.
19
+ ***************************************************************************** */
20
+ /* global Reflect, Promise, SuppressedError, Symbol, Iterator */
21
+
22
+
23
+ var __assign = function() {
24
+ __assign = Object.assign || function __assign(t) {
25
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
26
+ s = arguments[i];
27
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
28
+ }
29
+ return t;
30
+ };
31
+ return __assign.apply(this, arguments);
32
+ };
33
+
34
+ function __rest(s, e) {
35
+ var t = {};
36
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
37
+ t[p] = s[p];
38
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
39
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
40
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
41
+ t[p[i]] = s[p[i]];
42
+ }
43
+ return t;
44
+ }
45
+
46
+ typeof SuppressedError === "function" ? SuppressedError : function (error, suppressed, message) {
47
+ var e = new Error(message);
48
+ return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
49
+ };
50
+
51
+ /**
52
+ * Button component with HeroUI styling
53
+ * Provides a consistent interface for button interactions across the application
54
+ */
55
+ var ButtonPrueba = function (_a) {
56
+ var children = _a.children, startIcon = _a.startIcon, endIcon = _a.endIcon, _b = _a.loading, loading = _b === void 0 ? false : _b, disabled = _a.disabled, _c = _a.variant, variant = _c === void 0 ? "solid" : _c, _d = _a.color, color = _d === void 0 ? "primary" : _d, _e = _a.size, size = _e === void 0 ? "md" : _e, radius = _a.radius, _f = _a.fullWidth, fullWidth = _f === void 0 ? false : _f, _g = _a.className, className = _g === void 0 ? "" : _g, props = __rest(_a, ["children", "startIcon", "endIcon", "loading", "disabled", "variant", "color", "size", "radius", "fullWidth", "className"]);
57
+ useEffect(function () {
58
+ // biome-ignore lint/suspicious/noConsoleLog: <explanation>
59
+ console.log("estamos dentro del botnon");
60
+ }, []);
61
+ return (jsx(Button, __assign({ variant: variant, color: color, size: size, radius: radius, fullWidth: fullWidth, isLoading: loading, isDisabled: disabled, startContent: startIcon, endContent: endIcon, className: className }, props, { children: children })));
62
+ };
63
+
64
+ var sizeMap = {
65
+ sm: "16px",
66
+ md: "20px",
67
+ lg: "24px",
68
+ xl: "32px",
69
+ };
70
+ var IconComponent = function (_a) {
71
+ var icon = _a.icon, _b = _a.size, size = _b === void 0 ? "md" : _b, className = _a.className;
72
+ useEffect(function () {
73
+ // biome-ignore lint/suspicious/noConsoleLog: <explanation>
74
+ console.log("estamos dentro del icono");
75
+ }, []);
76
+ var iconSize = sizeMap[size];
77
+ return (jsx(Icon, { icon: icon, width: iconSize, height: iconSize, className: className }));
78
+ };
79
+
80
+ var themeColors = {
81
+ "purple-light": {
82
+ extend: "light",
83
+ colors: {
84
+ background: "#ffffff",
85
+ foreground: "#111827",
86
+ primary: {
87
+ 50: "#eee4f8",
88
+ 100: "#d7bfef",
89
+ 200: "#bf99e5",
90
+ 300: "#a773db",
91
+ 400: "#904ed2",
92
+ 500: "#7828c8",
93
+ 600: "#6321a5",
94
+ 700: "#4e1a82",
95
+ 800: "#39135f",
96
+ 900: "#240c3c",
97
+ DEFAULT: "#7828c8",
98
+ foreground: "#ffffff",
99
+ },
100
+ focus: "#904ed2",
101
+ },
102
+ },
103
+ "purple-dark": {
104
+ extend: "dark",
105
+ colors: {
106
+ background: "#1A1023",
107
+ foreground: "#ffffff",
108
+ primary: {
109
+ 50: "#2c193f",
110
+ 100: "#462764",
111
+ 200: "#603689",
112
+ 300: "#7944ae",
113
+ 400: "#9353d3",
114
+ 500: "#a671db",
115
+ 600: "#b98fe2",
116
+ 700: "#ccadee",
117
+ 800: "#dfcbf2",
118
+ 900: "#f2eafa",
119
+ DEFAULT: "#9353d3",
120
+ foreground: "#ffffff",
121
+ },
122
+ focus: "#a671db",
123
+ },
124
+ },
125
+ "green-light": {
126
+ extend: "light",
127
+ colors: {
128
+ background: "#ffffff",
129
+ foreground: "#111827",
130
+ primary: {
131
+ 50: "#ecf9f0",
132
+ 100: "#d1f0dc",
133
+ 200: "#b6e7c7",
134
+ 300: "#9cdeb3",
135
+ 400: "#81d59e",
136
+ 500: "#66cc8a",
137
+ 600: "#54a872",
138
+ 700: "#42855a",
139
+ 800: "#306142",
140
+ 900: "#1f3d29",
141
+ DEFAULT: "#66cc8a",
142
+ foreground: "#000000",
143
+ },
144
+ focus: "#81d59e",
145
+ },
146
+ },
147
+ "green-dark": {
148
+ extend: "dark",
149
+ colors: {
150
+ background: "#0F1D15",
151
+ foreground: "#ffffff",
152
+ primary: {
153
+ 50: "#1f3d29",
154
+ 100: "#306142",
155
+ 200: "#42855a",
156
+ 300: "#54a872",
157
+ 400: "#66cc8a",
158
+ 500: "#81d59e",
159
+ 600: "#9cdeb3",
160
+ 700: "#b6e7c7",
161
+ 800: "#d1f0dc",
162
+ 900: "#ecf9f0",
163
+ DEFAULT: "#66cc8a",
164
+ foreground: "#000000",
165
+ },
166
+ focus: "#81d59e",
167
+ },
168
+ },
169
+ "blue-light": {
170
+ extend: "light",
171
+ colors: {
172
+ background: "#ffffff",
173
+ foreground: "#111827",
174
+ primary: {
175
+ 50: "#eff6ff",
176
+ 100: "#dbeafe",
177
+ 200: "#bfdbfe",
178
+ 300: "#93c5fd",
179
+ 400: "#60a5fa",
180
+ 500: "#3b82f6",
181
+ 600: "#2563eb",
182
+ 700: "#1d4ed8",
183
+ 800: "#1e40af",
184
+ 900: "#1e3a8a",
185
+ DEFAULT: "#3b82f6",
186
+ foreground: "#ffffff",
187
+ },
188
+ focus: "#60a5fa",
189
+ },
190
+ },
191
+ "blue-dark": {
192
+ extend: "dark",
193
+ colors: {
194
+ background: "#101d3a",
195
+ foreground: "#ffffff",
196
+ primary: {
197
+ 50: "#1e3a8a",
198
+ 100: "#1e40af",
199
+ 200: "#1d4ed8",
200
+ 300: "#2563eb",
201
+ 400: "#3b82f6",
202
+ 500: "#60a5fa",
203
+ 600: "#93c5fd",
204
+ 700: "#bfdbfe",
205
+ 800: "#dbeafe",
206
+ 900: "#eff6ff",
207
+ DEFAULT: "#3b82f6",
208
+ foreground: "#ffffff",
209
+ },
210
+ focus: "#60a5fa",
211
+ },
212
+ },
213
+ "yellow-light": {
214
+ extend: "light",
215
+ colors: {
216
+ background: "#ffffff",
217
+ foreground: "#111827",
218
+ primary: {
219
+ 50: "#fefce8",
220
+ 100: "#fef9c3",
221
+ 200: "#fef08a",
222
+ 300: "#fde047",
223
+ 400: "#facc15",
224
+ 500: "#eab308",
225
+ 600: "#ca8a04",
226
+ 700: "#a16207",
227
+ 800: "#854d0e",
228
+ 900: "#713f12",
229
+ DEFAULT: "#eab308",
230
+ foreground: "#111827",
231
+ },
232
+ focus: "#facc15",
233
+ },
234
+ },
235
+ "yellow-dark": {
236
+ extend: "dark",
237
+ colors: {
238
+ background: "#18181b",
239
+ foreground: "#ffffff",
240
+ primary: {
241
+ 50: "#713f12",
242
+ 100: "#854d0e",
243
+ 200: "#a16207",
244
+ 300: "#ca8a04",
245
+ 400: "#eab308",
246
+ 500: "#facc15",
247
+ 600: "#fde047",
248
+ 700: "#fef08a",
249
+ 800: "#fef9c3",
250
+ 900: "#fefce8",
251
+ DEFAULT: "#facc15",
252
+ foreground: "#18181b",
253
+ },
254
+ focus: "#eab308",
255
+ },
256
+ },
257
+ };
258
+
259
+ var ThemeContext = createContext({
260
+ theme: "light",
261
+ // biome-ignore lint/suspicious/noEmptyBlockStatements: <explanation>
262
+ setTheme: function () { },
263
+ });
264
+ var useThemeContext = function () {
265
+ var context = useContext(ThemeContext);
266
+ if (!context) {
267
+ throw new Error("useThemeContext debe ser usado dentro de un ThemeProvider");
268
+ }
269
+ return context;
270
+ };
271
+
272
+ var ThemeProvider = function (_a) {
273
+ var children = _a.children;
274
+ var _b = useThemeContext(), theme = _b.theme, setTheme = _b.setTheme;
275
+ return (jsx(ThemeContext.Provider, { value: { theme: theme, setTheme: setTheme }, children: jsx("main", { className: "".concat(theme, " bg-background text-foreground "), children: children }) }));
276
+ };
277
+
278
+ export { ButtonPrueba, IconComponent, ThemeContext, ThemeProvider, sizeMap, themeColors, useThemeContext };
@@ -1,5 +1,5 @@
1
- export * from "@/components/button";
2
- export * from "@/components/icon";
1
+ export * from "./components/button";
2
+ export * from "./components/icon";
3
3
  export { themeColors } from "@/styles/colors.default";
4
4
  export * from "@/providers/theme";
5
5
  export * from "./contexts/theme";
package/package.json CHANGED
@@ -1,8 +1,7 @@
1
1
  {
2
2
  "name": "@beweco/aurora-ui",
3
- "version": "0.0.2",
3
+ "version": "0.0.3",
4
4
  "description": "Bewe Aurora UI Component Library",
5
- "keywords": ["ui", "components", "react", "bewe", "aura"],
6
5
  "sideEffects": false,
7
6
  "type": "module",
8
7
  "publishConfig": {
@@ -10,19 +9,19 @@
10
9
  },
11
10
  "exports": {
12
11
  ".": {
13
- "types": "./dist/esm/index.d.ts",
14
- "import": "./dist/esm/index.js",
15
- "require": "./dist/cjs/index.cjs"
12
+ "types": "./dist/types/index.d.ts",
13
+ "import": "./dist/index.esm.js",
14
+ "require": "./dist/index.cjs.js"
16
15
  }
17
16
  },
18
- "main": "./dist/cjs/index.cjs",
19
- "module": "./dist/esm/index.js",
20
- "types": "./dist/esm/index.d.ts",
17
+ "main": "./dist/index.cjs.js",
18
+ "module": "./dist/index.esm.js",
19
+ "types": "./dist/types/index.d.ts",
21
20
  "files": ["dist"],
22
21
  "author": "Bewe",
23
22
  "license": "MIT",
24
23
  "scripts": {
25
- "build": "rslib build",
24
+ "build": "rollup -c",
26
25
  "build:storybook": "storybook build",
27
26
  "check": "biome check --write",
28
27
  "dev": "rslib build --watch",
@@ -44,6 +43,9 @@
44
43
  },
45
44
  "devDependencies": {
46
45
  "@biomejs/biome": "^1.9.4",
46
+ "@rollup/plugin-commonjs": "^28.0.6",
47
+ "@rollup/plugin-node-resolve": "^16.0.1",
48
+ "@rollup/plugin-typescript": "^12.1.4",
47
49
  "@rsbuild/core": "^1.3.22",
48
50
  "@rsbuild/plugin-react": "^1.3.2",
49
51
  "@rsbuild/plugin-sass": "^1.3.1",
@@ -64,6 +66,8 @@
64
66
  "husky": "^9.1.7",
65
67
  "postcss": "^8.5.5",
66
68
  "postcss-loader": "^8.1.1",
69
+ "rollup": "^4.44.1",
70
+ "rollup-plugin-peer-deps-external": "^2.2.4",
67
71
  "storybook": "^8.0.0",
68
72
  "typescript": "^5.8.3"
69
73
  }
@@ -1 +0,0 @@
1
- let __rslib_import_meta_url__="undefined"==typeof document?new(require("url".replace("",""))).URL("file:"+__filename).href:document.currentScript&&document.currentScript.src||new URL("main.js",document.baseURI).href;var __webpack_exports__={},__webpack_export_target__=exports;for(var __webpack_i__ in __webpack_exports__)__webpack_export_target__[__webpack_i__]=__webpack_exports__[__webpack_i__];__webpack_exports__.__esModule&&Object.defineProperty(__webpack_export_target__,"__esModule",{value:!0});
@@ -1 +0,0 @@
1
- "use strict";let __rslib_import_meta_url__="undefined"==typeof document?new(require("url".replace("",""))).URL("file:"+__filename).href:document.currentScript&&document.currentScript.src||new URL("main.js",document.baseURI).href;var __webpack_require__={};__webpack_require__.d=(e,_)=>{for(var r in _)__webpack_require__.o(_,r)&&!__webpack_require__.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:_[r]})},__webpack_require__.o=(e,_)=>Object.prototype.hasOwnProperty.call(e,_),__webpack_require__.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var __webpack_exports__={};__webpack_require__.r(__webpack_exports__),__webpack_require__.d(__webpack_exports__,{ButtonPrueba:()=>ButtonPrueba});let jsx_runtime_namespaceObject=require("react/jsx-runtime"),index_cjs_namespaceObject=require("../../../node_modules/@heroui/react/dist/index.cjs"),external_react_namespaceObject=require("react"),ButtonPrueba=({children:e,startIcon:_,endIcon:r,loading:t=!1,disabled:a,variant:c="solid",color:o="primary",size:n="md",radius:i,fullWidth:p=!1,className:u="",...s})=>((0,external_react_namespaceObject.useEffect)(()=>{console.log("estamos dentro del botnon")},[]),(0,jsx_runtime_namespaceObject.jsx)(index_cjs_namespaceObject.Button,{variant:c,color:o,size:n,radius:i,fullWidth:p,isLoading:t,isDisabled:a,startContent:_,endContent:r,className:u,...s,children:e}));var __webpack_export_target__=exports;for(var __webpack_i__ in __webpack_exports__)__webpack_export_target__[__webpack_i__]=__webpack_exports__[__webpack_i__];__webpack_exports__.__esModule&&Object.defineProperty(__webpack_export_target__,"__esModule",{value:!0});