eai-frontend-components 2.0.5 → 2.0.6

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 (100) hide show
  1. package/package.json +3 -3
  2. package/src/components/ui/accordion.tsx +0 -48
  3. package/src/components/ui/alert-dialog.tsx +0 -138
  4. package/src/components/ui/alert.tsx +0 -36
  5. package/src/components/ui/avatar.tsx +0 -48
  6. package/src/components/ui/badge.tsx +0 -35
  7. package/src/components/ui/breadcrumb.tsx +0 -115
  8. package/src/components/ui/button.tsx +0 -43
  9. package/src/components/ui/calendar.tsx +0 -142
  10. package/src/components/ui/card.tsx +0 -35
  11. package/src/components/ui/carousel.tsx +0 -257
  12. package/src/components/ui/chart.tsx +0 -363
  13. package/src/components/ui/checkbox.tsx +0 -26
  14. package/src/components/ui/collapsible.tsx +0 -9
  15. package/src/components/ui/command.tsx +0 -145
  16. package/src/components/ui/context-menu.tsx +0 -198
  17. package/src/components/ui/custom/date-picker.tsx +0 -97
  18. package/src/components/ui/custom/form/checkbox.tsx +0 -53
  19. package/src/components/ui/custom/form/color.tsx +0 -140
  20. package/src/components/ui/custom/form/combobox.tsx +0 -259
  21. package/src/components/ui/custom/form/cpf-cnpj.tsx +0 -85
  22. package/src/components/ui/custom/form/currency.tsx +0 -51
  23. package/src/components/ui/custom/form/date-range.tsx +0 -110
  24. package/src/components/ui/custom/form/date.tsx +0 -109
  25. package/src/components/ui/custom/form/decimal.tsx +0 -50
  26. package/src/components/ui/custom/form/file.tsx +0 -65
  27. package/src/components/ui/custom/form/form-help-text.tsx +0 -20
  28. package/src/components/ui/custom/form/form-label.tsx +0 -24
  29. package/src/components/ui/custom/form/form-message.tsx +0 -10
  30. package/src/components/ui/custom/form/ghost.tsx +0 -28
  31. package/src/components/ui/custom/form/input.tsx +0 -69
  32. package/src/components/ui/custom/form/mask.tsx +0 -78
  33. package/src/components/ui/custom/form/multi-select.tsx +0 -209
  34. package/src/components/ui/custom/form/password.tsx +0 -70
  35. package/src/components/ui/custom/form/percent.tsx +0 -52
  36. package/src/components/ui/custom/form/phone.tsx +0 -79
  37. package/src/components/ui/custom/form/radio-group.tsx +0 -94
  38. package/src/components/ui/custom/form/select.tsx +0 -62
  39. package/src/components/ui/custom/form/step-new-form.tsx +0 -49
  40. package/src/components/ui/custom/form/switch.tsx +0 -51
  41. package/src/components/ui/custom/form/text.tsx +0 -71
  42. package/src/components/ui/custom/form/textarea.tsx +0 -71
  43. package/src/components/ui/custom/form/utils.ts +0 -100
  44. package/src/components/ui/custom/header.tsx +0 -128
  45. package/src/components/ui/custom/label.tsx +0 -79
  46. package/src/components/ui/custom/not-found.tsx +0 -30
  47. package/src/components/ui/custom/sidebar/module-switcher.tsx +0 -58
  48. package/src/components/ui/custom/sidebar/nav-footer.tsx +0 -35
  49. package/src/components/ui/custom/sidebar/nav-main.tsx +0 -64
  50. package/src/components/ui/custom/sidebar/nav-submenu-collapsible.tsx +0 -60
  51. package/src/components/ui/custom/sidebar/nav-submenu-dropdown.tsx +0 -56
  52. package/src/components/ui/custom/sidebar/nav-user.tsx +0 -77
  53. package/src/components/ui/custom/sidebar/sidebar-button.tsx +0 -30
  54. package/src/components/ui/custom/sidebar/sidebar-item-two-lines.tsx +0 -25
  55. package/src/components/ui/custom/sidebar/sidebar-item.tsx +0 -19
  56. package/src/components/ui/custom/sidebar/types/sidebar.ts +0 -31
  57. package/src/components/ui/custom/table/data-table-export.tsx +0 -126
  58. package/src/components/ui/custom/table/data-table-footer.tsx +0 -148
  59. package/src/components/ui/custom/table/data-table-header.tsx +0 -58
  60. package/src/components/ui/custom/table/data-table-rows.tsx +0 -94
  61. package/src/components/ui/custom/table/data-table.tsx +0 -285
  62. package/src/components/ui/custom/table/types/data-table.ts +0 -31
  63. package/src/components/ui/custom/theme-provider.tsx +0 -121
  64. package/src/components/ui/dateRangePicker.tsx +0 -63
  65. package/src/components/ui/dialog.tsx +0 -84
  66. package/src/components/ui/drawer.tsx +0 -116
  67. package/src/components/ui/dropdown-menu.tsx +0 -173
  68. package/src/components/ui/form.tsx +0 -114
  69. package/src/components/ui/hover-card.tsx +0 -27
  70. package/src/components/ui/input.tsx +0 -265
  71. package/src/components/ui/label.tsx +0 -15
  72. package/src/components/ui/masks.ts +0 -35
  73. package/src/components/ui/pagination.tsx +0 -78
  74. package/src/components/ui/popover.tsx +0 -32
  75. package/src/components/ui/progress.tsx +0 -22
  76. package/src/components/ui/radio-group.tsx +0 -36
  77. package/src/components/ui/scroll-area.tsx +0 -46
  78. package/src/components/ui/select.tsx +0 -130
  79. package/src/components/ui/separator.tsx +0 -29
  80. package/src/components/ui/sheet.tsx +0 -90
  81. package/src/components/ui/sidebar.tsx +0 -598
  82. package/src/components/ui/skeleton.tsx +0 -15
  83. package/src/components/ui/slider.tsx +0 -18
  84. package/src/components/ui/switch.tsx +0 -26
  85. package/src/components/ui/table.tsx +0 -53
  86. package/src/components/ui/tabs.tsx +0 -47
  87. package/src/components/ui/textarea.tsx +0 -27
  88. package/src/components/ui/toast.tsx +0 -88
  89. package/src/components/ui/toaster.tsx +0 -49
  90. package/src/components/ui/tooltip.tsx +0 -31
  91. package/src/components/ui/use-calendar.tsx +0 -61
  92. package/src/components/ui/use-toast.ts +0 -186
  93. package/src/hooks/use-mobile.tsx +0 -19
  94. package/src/index.ts +0 -299
  95. package/src/lib/help/date-utils.ts +0 -41
  96. package/src/lib/help/format.ts +0 -171
  97. package/src/lib/help/theme.ts +0 -346
  98. package/src/lib/help/uuid.ts +0 -4
  99. package/src/lib/utils.ts +0 -6
  100. package/src/styles/globals.css +0 -59
@@ -1,346 +0,0 @@
1
- // Retorna todas as cores do Tailwind CSS das variações 50 a 950
2
- export function getTailwindColorShades() {
3
- // Paleta padrão do Tailwind v3.3.0
4
- // Fonte: https://github.com/tailwindlabs/tailwindcss/blob/master/src/public/colors.js
5
- return {
6
- slate: {
7
- 50: '#f8fafc',
8
- 100: '#f1f5f9',
9
- 200: '#e2e8f0',
10
- 300: '#cbd5e1',
11
- 400: '#94a3b8',
12
- 500: '#64748b',
13
- 600: '#475569',
14
- 700: '#334155',
15
- 800: '#1e293b',
16
- 900: '#0f172a',
17
- 950: '#020617',
18
- },
19
- gray: {
20
- 50: '#f9fafb',
21
- 100: '#f3f4f6',
22
- 200: '#e5e7eb',
23
- 300: '#d1d5db',
24
- 400: '#9ca3af',
25
- 500: '#6b7280',
26
- 600: '#4b5563',
27
- 700: '#374151',
28
- 800: '#1f2937',
29
- 900: '#111827',
30
- 950: '#030712',
31
- },
32
- zinc: {
33
- 50: '#fafafa',
34
- 100: '#f4f4f5',
35
- 200: '#e4e4e7',
36
- 300: '#d4d4d8',
37
- 400: '#a1a1aa',
38
- 500: '#71717a',
39
- 600: '#52525b',
40
- 700: '#3f3f46',
41
- 800: '#27272a',
42
- 900: '#18181b',
43
- 950: '#09090b',
44
- },
45
- neutral: {
46
- 50: '#fafafa',
47
- 100: '#f5f5f5',
48
- 200: '#e5e5e5',
49
- 300: '#d4d4d4',
50
- 400: '#a3a3a3',
51
- 500: '#737373',
52
- 600: '#525252',
53
- 700: '#404040',
54
- 800: '#262626',
55
- 900: '#171717',
56
- 950: '#0a0a0a',
57
- },
58
- stone: {
59
- 50: '#fafaf9',
60
- 100: '#f5f5f4',
61
- 200: '#e7e5e4',
62
- 300: '#d6d3d1',
63
- 400: '#a8a29e',
64
- 500: '#78716c',
65
- 600: '#57534e',
66
- 700: '#44403c',
67
- 800: '#292524',
68
- 900: '#1c1917',
69
- 950: '#0c0a09',
70
- },
71
- red: {
72
- 50: '#fef2f2',
73
- 100: '#fee2e2',
74
- 200: '#fecaca',
75
- 300: '#fca5a5',
76
- 400: '#f87171',
77
- 500: '#ef4444',
78
- 600: '#dc2626',
79
- 700: '#b91c1c',
80
- 800: '#991b1b',
81
- 900: '#7f1d1d',
82
- 950: '#450a0a',
83
- },
84
- orange: {
85
- 50: '#fff7ed',
86
- 100: '#ffedd5',
87
- 200: '#fed7aa',
88
- 300: '#fdba74',
89
- 400: '#fb923c',
90
- 500: '#f97316',
91
- 600: '#ea580c',
92
- 700: '#c2410c',
93
- 800: '#9a3412',
94
- 900: '#7c2d12',
95
- 950: '#431407',
96
- },
97
- amber: {
98
- 50: '#fffbeb',
99
- 100: '#fef3c7',
100
- 200: '#fde68a',
101
- 300: '#fcd34d',
102
- 400: '#fbbf24',
103
- 500: '#f59e42',
104
- 600: '#d97706',
105
- 700: '#b45309',
106
- 800: '#92400e',
107
- 900: '#78350f',
108
- 950: '#451a03',
109
- },
110
- yellow: {
111
- 50: '#fefce8',
112
- 100: '#fef9c3',
113
- 200: '#fef08a',
114
- 300: '#fde047',
115
- 400: '#facc15',
116
- 500: '#eab308',
117
- 600: '#ca8a04',
118
- 700: '#a16207',
119
- 800: '#854d0e',
120
- 900: '#713f12',
121
- 950: '#422006',
122
- },
123
- lime: {
124
- 50: '#f7fee7',
125
- 100: '#ecfccb',
126
- 200: '#d9f99d',
127
- 300: '#bef264',
128
- 400: '#a3e635',
129
- 500: '#84cc16',
130
- 600: '#65a30d',
131
- 700: '#4d7c0f',
132
- 800: '#3f6212',
133
- 900: '#365314',
134
- 950: '#1a2e05',
135
- },
136
- green: {
137
- 50: '#f0fdf4',
138
- 100: '#dcfce7',
139
- 200: '#bbf7d0',
140
- 300: '#86efac',
141
- 400: '#4ade80',
142
- 500: '#22c55e',
143
- 600: '#16a34a',
144
- 700: '#15803d',
145
- 800: '#166534',
146
- 900: '#14532d',
147
- 950: '#052e16',
148
- },
149
- emerald: {
150
- 50: '#ecfdf5',
151
- 100: '#d1fae5',
152
- 200: '#a7f3d0',
153
- 300: '#6ee7b7',
154
- 400: '#34d399',
155
- 500: '#10b981',
156
- 600: '#059669',
157
- 700: '#047857',
158
- 800: '#065f46',
159
- 900: '#064e3b',
160
- 950: '#022c22',
161
- },
162
- teal: {
163
- 50: '#f0fdfa',
164
- 100: '#ccfbf1',
165
- 200: '#99f6e4',
166
- 300: '#5eead4',
167
- 400: '#2dd4bf',
168
- 500: '#14b8a6',
169
- 600: '#0d9488',
170
- 700: '#0f766e',
171
- 800: '#115e59',
172
- 900: '#134e4a',
173
- 950: '#042f2e',
174
- },
175
- cyan: {
176
- 50: '#ecfeff',
177
- 100: '#cffafe',
178
- 200: '#a5f3fc',
179
- 300: '#67e8f9',
180
- 400: '#22d3ee',
181
- 500: '#06b6d4',
182
- 600: '#0891b2',
183
- 700: '#0e7490',
184
- 800: '#155e75',
185
- 900: '#164e63',
186
- 950: '#083344',
187
- },
188
- sky: {
189
- 50: '#f0f9ff',
190
- 100: '#e0f2fe',
191
- 200: '#bae6fd',
192
- 300: '#7dd3fc',
193
- 400: '#38bdf8',
194
- 500: '#0ea5e9',
195
- 600: '#0284c7',
196
- 700: '#0369a1',
197
- 800: '#075985',
198
- 900: '#0e3a5e',
199
- 950: '#082f49',
200
- },
201
- blue: {
202
- 50: '#eff6ff',
203
- 100: '#dbeafe',
204
- 200: '#bfdbfe',
205
- 300: '#93c5fd',
206
- 400: '#60a5fa',
207
- 500: '#3b82f6',
208
- 600: '#2563eb',
209
- 700: '#1d4ed8',
210
- 800: '#1e40af',
211
- 900: '#1e3a8a',
212
- 950: '#172554',
213
- },
214
- indigo: {
215
- 50: '#eef2ff',
216
- 100: '#e0e7ff',
217
- 200: '#c7d2fe',
218
- 300: '#a5b4fc',
219
- 400: '#818cf8',
220
- 500: '#6366f1',
221
- 600: '#4f46e5',
222
- 700: '#4338ca',
223
- 800: '#3730a3',
224
- 900: '#312e81',
225
- 950: '#1e1b4b',
226
- },
227
- violet: {
228
- 50: '#f5f3ff',
229
- 100: '#ede9fe',
230
- 200: '#ddd6fe',
231
- 300: '#c4b5fd',
232
- 400: '#a78bfa',
233
- 500: '#8b5cf6',
234
- 600: '#7c3aed',
235
- 700: '#6d28d9',
236
- 800: '#5b21b6',
237
- 900: '#4c1d95',
238
- 950: '#2e1065',
239
- },
240
- purple: {
241
- 50: '#faf5ff',
242
- 100: '#f3e8ff',
243
- 200: '#e9d5ff',
244
- 300: '#d8b4fe',
245
- 400: '#c084fc',
246
- 500: '#a855f7',
247
- 600: '#9333ea',
248
- 700: '#7e22ce',
249
- 800: '#6d19a8',
250
- 900: '#581c87',
251
- 950: '#3b0764',
252
- },
253
- fuchsia: {
254
- 50: '#fdf4ff',
255
- 100: '#fae8ff',
256
- 200: '#f5d0fe',
257
- 300: '#f0abfc',
258
- 400: '#e879f9',
259
- 500: '#d946ef',
260
- 600: '#c026d3',
261
- 700: '#a21caf',
262
- 800: '#86198f',
263
- 900: '#701a75',
264
- 950: '#4a044e',
265
- },
266
- pink: {
267
- 50: '#fdf2f8',
268
- 100: '#fce7f3',
269
- 200: '#fbcfe8',
270
- 300: '#f9a8d4',
271
- 400: '#f472b6',
272
- 500: '#ec4899',
273
- 600: '#db2777',
274
- 700: '#be185d',
275
- 800: '#9d174d',
276
- 900: '#831843',
277
- 950: '#500724',
278
- },
279
- rose: {
280
- 50: '#fff1f2',
281
- 100: '#ffe4e6',
282
- 200: '#fecdd3',
283
- 300: '#fda4af',
284
- 400: '#fb7185',
285
- 500: '#f43f5e',
286
- 600: '#e11d48',
287
- 700: '#be123c',
288
- 800: '#9f1239',
289
- 900: '#881337',
290
- 950: '#4c0519',
291
- },
292
- };
293
- }
294
-
295
- export type TailwindColorName = keyof ReturnType<typeof getTailwindColorShades>;
296
-
297
- export const replaceThemeTailwindColors = (theme: string, tailwindColor: string): HTMLStyleElement => {
298
- const colorShades = getTailwindColorShades();
299
- const isValidColor = (color: string): color is TailwindColorName => color in colorShades;
300
- const colorPallete = isValidColor(tailwindColor) ? colorShades[tailwindColor] : colorShades.violet;
301
-
302
- const el = document.createElement('style');
303
- el.id = 'theme-variables';
304
- el.setAttribute('type', 'text/css');
305
- el.textContent = ':root {';
306
-
307
- if (theme === 'light') {
308
- el.textContent += `--sidebar-background: ${colorPallete[50]};\n`;
309
- el.textContent += `--sidebar-accent: ${colorPallete[200]};\n`;
310
- el.textContent += `--sidebar-ring: ${colorPallete[300]};\n`;
311
- el.textContent += `--sidebar-border: ${colorPallete[100]};\n`;
312
- el.textContent += `--sidebar-scrollbar-thumb: ${colorPallete[200]};\n`;
313
- }
314
- if (theme === 'light' || theme === 'dark-side') {
315
- el.textContent += `--background-elevated: ${colorPallete[200]};\n`;
316
- el.textContent += `--background-primary-hover: ${colorPallete[100]};\n`;
317
- el.textContent += `--background-subtle: ${colorPallete[50]};\n`;
318
- el.textContent += `--accent: ${colorPallete[200]};\n`;
319
- el.textContent += `--datatable-background: ${colorPallete[50]};\n`;
320
- el.textContent += `--datatable-accent: ${colorPallete[50]};\n`;
321
- el.textContent += `--scrollbar-thumb: ${colorPallete[200]};\n`;
322
- }
323
- if (theme === 'dark-side' || theme === 'dark') {
324
- // Verificar essa propriedade
325
- el.textContent += `--sidebar-accent: ${colorPallete[950]};\n`;
326
- }
327
- el.textContent += `--background-primary: ${colorPallete[900]};\n`;
328
- el.textContent += `--background-primary-hover: ${colorPallete[950]};\n`;
329
- el.textContent += `--primary: ${colorPallete[900]};\n`;
330
- el.textContent += `--primary-950: ${colorPallete[950]};\n`;
331
- el.textContent += `--primary-900: ${colorPallete[900]};\n`;
332
- el.textContent += `--primary-800: ${colorPallete[800]};\n`;
333
- el.textContent += `--primary-700: ${colorPallete[700]};\n`;
334
- el.textContent += `--primary-600: ${colorPallete[600]};\n`;
335
- el.textContent += `--primary-500: ${colorPallete[500]};\n`;
336
- el.textContent += `--primary-400: ${colorPallete[400]};\n`;
337
- el.textContent += `--primary-300: ${colorPallete[300]};\n`;
338
- el.textContent += `--primary-200: ${colorPallete[200]};\n`;
339
- el.textContent += `--primary-100: ${colorPallete[100]};\n`;
340
- el.textContent += `--primary-50: ${colorPallete[50]};\n`;
341
- el.textContent += `--chart-primary: ${colorPallete[800]};\n`;
342
- el.textContent += `--chart-secondary: ${colorPallete[200]};\n`;
343
- el.textContent += '}';
344
-
345
- return el;
346
- };
@@ -1,4 +0,0 @@
1
- export function isUUIDv4(str: string): boolean {
2
- const uuidV4Regex = /^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i;
3
- return uuidV4Regex.test(str);
4
- }
package/src/lib/utils.ts DELETED
@@ -1,6 +0,0 @@
1
- import { type ClassValue, clsx } from 'clsx';
2
- import { twMerge } from 'tailwind-merge';
3
-
4
- export function cn(...inputs: ClassValue[]) {
5
- return twMerge(clsx(inputs));
6
- }
@@ -1,59 +0,0 @@
1
- @tailwind base;
2
- @tailwind components;
3
- @tailwind utilities;
4
-
5
- @layer base {
6
- :root {
7
- --background: 0 0% 100%;
8
- --foreground: 222.2 84% 4.9%;
9
- --card: 0 0% 100%;
10
- --card-foreground: 222.2 84% 4.9%;
11
- --popover: 0 0% 100%;
12
- --popover-foreground: 222.2 84% 4.9%;
13
- --primary: 222.2 47.4% 11.2%;
14
- --primary-foreground: 210 40% 98%;
15
- --secondary: 210 40% 96%;
16
- --secondary-foreground: 222.2 47.4% 11.2%;
17
- --muted: 210 40% 96%;
18
- --muted-foreground: 215.4 16.3% 46.9%;
19
- --accent: 210 40% 96%;
20
- --accent-foreground: 222.2 47.4% 11.2%;
21
- --destructive: 0 84.2% 60.2%;
22
- --destructive-foreground: 210 40% 98%;
23
- --border: 214.3 31.8% 91.4%;
24
- --input: 214.3 31.8% 91.4%;
25
- --ring: 222.2 84% 4.9%;
26
- --radius: 0.5rem;
27
- }
28
-
29
- .dark {
30
- --background: 222.2 84% 4.9%;
31
- --foreground: 210 40% 98%;
32
- --card: 222.2 84% 4.9%;
33
- --card-foreground: 210 40% 98%;
34
- --popover: 222.2 84% 4.9%;
35
- --popover-foreground: 210 40% 98%;
36
- --primary: 210 40% 98%;
37
- --primary-foreground: 222.2 47.4% 11.2%;
38
- --secondary: 217.2 32.6% 17.5%;
39
- --secondary-foreground: 210 40% 98%;
40
- --muted: 217.2 32.6% 17.5%;
41
- --muted-foreground: 215 20.2% 65.1%;
42
- --accent: 217.2 32.6% 17.5%;
43
- --accent-foreground: 210 40% 98%;
44
- --destructive: 0 62.8% 30.6%;
45
- --destructive-foreground: 210 40% 98%;
46
- --border: 217.2 32.6% 17.5%;
47
- --input: 217.2 32.6% 17.5%;
48
- --ring: 212.7 26.8% 83.9%;
49
- }
50
- }
51
-
52
- @layer base {
53
- * {
54
- @apply border-border;
55
- }
56
- body {
57
- @apply bg-background text-foreground;
58
- }
59
- }