luna-components-library 1.1.34 → 1.1.37

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.
@@ -0,0 +1,259 @@
1
+ import { default as React } from 'react';
2
+ import { Size, AnchorVariant, CardPadding, CardShadow, InputSize, InputVariant, ModalSize, PopconfirmPosition, ProgressBarVariant, ToastSeverity, ToastPosition, CornerPosition } from './types';
3
+ export declare const colors: {
4
+ readonly white: "#ffffff";
5
+ readonly border: "#e5e7eb";
6
+ readonly borderInput: "#d1d5db";
7
+ readonly borderLight: "#f3f4f6";
8
+ readonly text: "#374151";
9
+ readonly textSecondary: "#4b5563";
10
+ readonly textMuted: "#6b7280";
11
+ readonly textDisabled: "#9ca3af";
12
+ readonly bgHeader: "#f9fafb";
13
+ readonly bgHover: "#f3f4f6";
14
+ readonly bgSelected: "#eff6ff";
15
+ readonly bgSkeleton: "#f3f4f6";
16
+ readonly primary: "#2563eb";
17
+ readonly dark: "#111827";
18
+ };
19
+ export declare const radii: {
20
+ readonly sm: "0.375rem";
21
+ readonly md: "0.5rem";
22
+ readonly lg: "0.75rem";
23
+ readonly full: "50%";
24
+ readonly pill: "9999px";
25
+ };
26
+ export declare const fontSizes: {
27
+ readonly xs: "0.75rem";
28
+ readonly sm: "0.875rem";
29
+ readonly base: "1rem";
30
+ readonly lg: "1.125rem";
31
+ readonly xl: "1.25rem";
32
+ };
33
+ export declare const fontWeights: {
34
+ readonly medium: 500;
35
+ readonly semibold: 600;
36
+ readonly bold: 700;
37
+ };
38
+ export declare const transitions: {
39
+ readonly fast: "all 150ms ease-in-out";
40
+ readonly bg: "background-color 150ms";
41
+ readonly bgSlow: "background-color 200ms";
42
+ readonly transform: "transform 200ms";
43
+ readonly normal: "all 300ms ease-in-out";
44
+ };
45
+ export declare const shadows: {
46
+ readonly panel: "0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05)";
47
+ readonly menu: "0 4px 6px -1px rgba(0, 0, 0, 0.1)";
48
+ };
49
+ export declare const zIndices: {
50
+ readonly panel: 1000;
51
+ readonly menu: 100;
52
+ };
53
+ export declare const sizeStyles: Record<Size, React.CSSProperties>;
54
+ export declare const sizeClasses: Record<Size, string>;
55
+ export declare const commonStyles: {
56
+ container: React.CSSProperties;
57
+ panel: React.CSSProperties;
58
+ trigger: React.CSSProperties;
59
+ header: React.CSSProperties;
60
+ chevron: React.CSSProperties;
61
+ list: React.CSSProperties;
62
+ item: (isSelected: boolean, isDisabled: boolean) => React.CSSProperties;
63
+ chip: React.CSSProperties;
64
+ icon: React.CSSProperties;
65
+ checkbox: React.CSSProperties;
66
+ filterMenu: React.CSSProperties;
67
+ filterOption: (active: boolean) => React.CSSProperties;
68
+ pagination: React.CSSProperties;
69
+ buttonBase: React.CSSProperties;
70
+ inputWrapper: React.CSSProperties;
71
+ inputLabel: React.CSSProperties;
72
+ inputField: React.CSSProperties;
73
+ popover: React.CSSProperties;
74
+ floatingButton: React.CSSProperties;
75
+ card: React.CSSProperties;
76
+ };
77
+ export declare const cardPaddingValues: Record<CardPadding, string>;
78
+ export declare const cardShadowValues: Record<CardShadow, string>;
79
+ export declare const cardStyles: (padding: CardPadding, shadow: CardShadow, styles?: Record<string, React.CSSProperties>) => {
80
+ container: React.CSSProperties;
81
+ titleContainer: React.CSSProperties;
82
+ title: React.CSSProperties;
83
+ content: React.CSSProperties;
84
+ };
85
+ export declare const dataTableStyles: (styles?: Record<string, React.CSSProperties>) => {
86
+ container: React.CSSProperties;
87
+ searchContainer: React.CSSProperties;
88
+ table: React.CSSProperties;
89
+ thead: React.CSSProperties;
90
+ th: React.CSSProperties;
91
+ td: React.CSSProperties;
92
+ tr: (clickable: boolean) => React.CSSProperties;
93
+ pagination: React.CSSProperties;
94
+ icon: React.CSSProperties;
95
+ filterMenu: React.CSSProperties;
96
+ filterOption: (active: boolean) => React.CSSProperties;
97
+ };
98
+ export declare const dropDownStyles: (styles?: Record<string, React.CSSProperties>, disabled?: boolean, isOpen?: boolean, hoverIndex?: number | null, value?: any) => {
99
+ container: React.CSSProperties;
100
+ trigger: React.CSSProperties;
101
+ panel: React.CSSProperties;
102
+ option: (index: number) => React.CSSProperties;
103
+ arrow: React.CSSProperties;
104
+ };
105
+ export declare const variantStyles: {
106
+ readonly primary: {
107
+ readonly backgroundColor: "#2563eb";
108
+ readonly color: "#ffffff";
109
+ };
110
+ readonly secondary: {
111
+ readonly backgroundColor: "#4b5563";
112
+ readonly color: "#ffffff";
113
+ };
114
+ readonly outline: {
115
+ readonly backgroundColor: "transparent";
116
+ readonly color: "#374151";
117
+ readonly borderColor: "#d1d5db";
118
+ };
119
+ readonly success: {
120
+ readonly backgroundColor: "#16a34a";
121
+ readonly color: "#ffffff";
122
+ };
123
+ readonly danger: {
124
+ readonly backgroundColor: "#dc2626";
125
+ readonly color: "#ffffff";
126
+ };
127
+ readonly warning: {
128
+ readonly backgroundColor: "#eab308";
129
+ readonly color: "#ffffff";
130
+ };
131
+ readonly info: {
132
+ readonly backgroundColor: "#0891b2";
133
+ readonly color: "#ffffff";
134
+ };
135
+ readonly dark: {
136
+ readonly backgroundColor: "#111827";
137
+ readonly color: "#ffffff";
138
+ };
139
+ readonly light: {
140
+ readonly backgroundColor: "#f3f4f6";
141
+ readonly color: "#111827";
142
+ };
143
+ readonly link: {
144
+ readonly backgroundColor: "transparent";
145
+ readonly color: "#2563eb";
146
+ readonly border: "none";
147
+ readonly padding: 0;
148
+ readonly textDecoration: "underline";
149
+ };
150
+ };
151
+ export declare const variantClasses: {
152
+ readonly primary: "bg-blue-600 text-white hover:bg-blue-700";
153
+ readonly secondary: "bg-gray-600 text-white hover:bg-gray-700";
154
+ readonly outline: "border border-gray-300 text-gray-700 hover:bg-gray-50";
155
+ readonly success: "bg-green-600 text-white hover:bg-green-700";
156
+ readonly danger: "bg-red-600 text-white hover:bg-red-700";
157
+ readonly warning: "bg-yellow-500 text-white hover:bg-yellow-600";
158
+ readonly info: "bg-cyan-600 text-white hover:bg-cyan-700";
159
+ readonly dark: "bg-gray-900 text-white hover:bg-gray-800";
160
+ readonly light: "bg-gray-100 text-gray-900 hover:bg-gray-200";
161
+ readonly link: "text-blue-600 hover:text-blue-800 hover:underline";
162
+ };
163
+ export declare const inputStyles: (styles?: Record<string, React.CSSProperties>, extraStyle?: React.CSSProperties, inputSize?: InputSize, readOnly?: boolean, disabled?: boolean) => {
164
+ container: React.CSSProperties;
165
+ label: React.CSSProperties;
166
+ input: React.CSSProperties;
167
+ variants: Record<InputVariant, React.CSSProperties>;
168
+ };
169
+ export declare const multiSelectStyles: (styles?: Record<string, React.CSSProperties>, disabled?: boolean, isOpen?: boolean) => {
170
+ container: React.CSSProperties;
171
+ trigger: React.CSSProperties;
172
+ chevron: React.CSSProperties;
173
+ panel: React.CSSProperties;
174
+ header: React.CSSProperties;
175
+ selectAllWrapper: React.CSSProperties;
176
+ list: React.CSSProperties;
177
+ item: (isSelected: boolean, isDisabled: boolean) => React.CSSProperties;
178
+ checkbox: React.CSSProperties;
179
+ chip: React.CSSProperties;
180
+ chipIcon: React.CSSProperties;
181
+ };
182
+ export declare const popconfirmPositionStyles: (pos: PopconfirmPosition) => React.CSSProperties;
183
+ export declare const popconfirmStyles: (styles?: Record<string, React.CSSProperties>, show?: boolean, position?: PopconfirmPosition) => {
184
+ container: React.CSSProperties;
185
+ popover: React.CSSProperties;
186
+ titleWrapper: React.CSSProperties;
187
+ icon: React.CSSProperties;
188
+ title: React.CSSProperties;
189
+ description: React.CSSProperties;
190
+ actions: React.CSSProperties;
191
+ };
192
+ export declare const preloaderStyles: (zIndex: number, backgroundColor: string, size: number, borderWidth: number, styles?: Record<string, React.CSSProperties>) => {
193
+ overlay: React.CSSProperties;
194
+ spinner: React.CSSProperties;
195
+ };
196
+ export declare const progressBarVariantColors: Record<ProgressBarVariant, {
197
+ bg: string;
198
+ text: string;
199
+ track: string;
200
+ }>;
201
+ export declare const progressBarStyles: (styles?: Record<string, React.CSSProperties>, percentage?: number, variant?: ProgressBarVariant) => {
202
+ container: React.CSSProperties;
203
+ bar: React.CSSProperties;
204
+ text: React.CSSProperties;
205
+ };
206
+ export declare const qrCodeStyles: (styles?: Record<string, React.CSSProperties>, bordered?: boolean, cleanBgColor?: string, size?: number, isLoading?: boolean) => {
207
+ container: React.CSSProperties;
208
+ image: React.CSSProperties;
209
+ skeleton: React.CSSProperties;
210
+ };
211
+ export declare const spinnerAnimationStyles = "\n @keyframes luna-spin { to { transform: rotate(360deg); } }\n @keyframes luna-bounce { 0%, 100% { transform: translateY(-25%); animation-timing-function: cubic-bezier(0.8,0,1,1); } 50% { transform: translateY(0); animation-timing-function: cubic-bezier(0,0,0.2,1); } }\n @keyframes luna-pulse { 50% { opacity: .5; } }\n";
212
+ export declare const spinnerSizeValues: Record<Size, string>;
213
+ export declare const spinnerDotSizeValues: Record<Size, string>;
214
+ export declare const spinnerBarSizeValues: Record<Size, {
215
+ w: string;
216
+ h: string;
217
+ }>;
218
+ export declare const toastSeverityConfig: Record<ToastSeverity, {
219
+ bg: string;
220
+ border: string;
221
+ text: string;
222
+ secondaryText: string;
223
+ icon: string;
224
+ }>;
225
+ export declare const toastPositionStyles: (pos: ToastPosition) => React.CSSProperties;
226
+ export declare const toastStyles: (styles?: Record<string, React.CSSProperties>, severity?: ToastSeverity, position?: ToastPosition, isExiting?: boolean, visible?: boolean) => {
227
+ container: React.CSSProperties;
228
+ iconWrapper: React.CSSProperties;
229
+ content: React.CSSProperties;
230
+ summary: React.CSSProperties;
231
+ detail: React.CSSProperties;
232
+ closeButton: React.CSSProperties;
233
+ };
234
+ export declare const typedStyles: (style?: React.CSSProperties, cursorStyle?: React.CSSProperties, cursorOpacity?: number) => {
235
+ container: React.CSSProperties;
236
+ cursor: React.CSSProperties;
237
+ };
238
+ export declare const whatsAppSizes: Record<Size, {
239
+ button: number;
240
+ icon: number;
241
+ }>;
242
+ export declare const cornerPositionStyles: (position: CornerPosition) => React.CSSProperties;
243
+ export declare const whatsAppStyles: (styles?: Record<string, React.CSSProperties>, position?: CornerPosition, size?: Size, isHovered?: boolean, zIndex?: number) => {
244
+ button: React.CSSProperties;
245
+ tooltip: React.CSSProperties;
246
+ };
247
+ export declare const scrollTopStyles: (styles?: React.CSSProperties, position?: CornerPosition, size?: number, isVisible?: boolean) => React.CSSProperties;
248
+ export declare const modalSizeClasses: Record<ModalSize, string>;
249
+ export declare const modalOverlayClasses: (show: boolean, animation: boolean, className: string) => string;
250
+ export declare const modalDialogClasses: (size: ModalSize, centered: boolean, dialogClassName: string) => string;
251
+ export declare const anchorBaseStyles: (variant: AnchorVariant, isHovered: boolean, size: Size) => React.CSSProperties;
252
+ export declare const accordionStyles: (isActive: boolean, styles?: Record<string, React.CSSProperties>) => {
253
+ container: React.CSSProperties;
254
+ header: React.CSSProperties;
255
+ content: React.CSSProperties;
256
+ innerContent: React.CSSProperties;
257
+ arrow: React.CSSProperties;
258
+ };
259
+ export declare const anchorVariantStyles: (isHovered: boolean) => Record<AnchorVariant, React.CSSProperties>;
@@ -0,0 +1,23 @@
1
+ import { default as React } from 'react';
2
+ export type ClassNames<T extends string> = {
3
+ [K in T]?: string;
4
+ };
5
+ export type Styles<T extends string> = {
6
+ [K in T]?: React.CSSProperties;
7
+ };
8
+ export type Size = 'sm' | 'md' | 'lg';
9
+ export type ExtendedSize = Size | 'xl';
10
+ export type OptionalSize = Size | 'none';
11
+ export type ButtonVariant = 'primary' | 'secondary' | 'outline' | 'success' | 'danger' | 'warning' | 'info' | 'dark' | 'light' | 'link';
12
+ export type ButtonSize = Size;
13
+ export type AnchorVariant = 'none' | 'primary' | 'secondary' | 'outline';
14
+ export type InputVariant = 'none' | 'primary' | 'secondary' | 'outline' | 'danger' | 'success';
15
+ export type ProgressBarVariant = 'primary' | 'success' | 'warning' | 'danger' | 'dark' | 'light';
16
+ export type InputSize = ExtendedSize;
17
+ export type ModalSize = ExtendedSize;
18
+ export type CardPadding = OptionalSize;
19
+ export type CardShadow = OptionalSize;
20
+ export type PopconfirmPosition = 'top' | 'bottom' | 'left' | 'right';
21
+ export type ToastSeverity = 'success' | 'info' | 'warn' | 'error';
22
+ export type ToastPosition = 'top-right' | 'top-left' | 'bottom-right' | 'bottom-left' | 'top-center' | 'bottom-center';
23
+ export type CornerPosition = 'bottom-right' | 'bottom-left' | 'top-right' | 'top-left';
@@ -1,3 +1,6 @@
1
+ /**
2
+ * Utility for logging messages with different levels.
3
+ */
1
4
  export declare const logger: {
2
5
  info: (message: string, ...data: any[]) => void;
3
6
  warn: (message: string, ...data: any[]) => void;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "luna-components-library",
3
- "version": "1.1.34",
3
+ "version": "1.1.37",
4
4
  "description": "A React component library with TypeScript support",
5
5
  "main": "dist/luna-components-library.js",
6
6
  "module": "dist/luna-components-library.js",