@moontra/moonui 2.0.11 → 2.1.0

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@moontra/moonui",
3
- "version": "2.0.11",
3
+ "version": "2.1.0",
4
4
  "description": "Premium React component library with modern design and customization",
5
5
  "author": "MoonUI",
6
6
  "license": "MIT",
@@ -4,12 +4,12 @@ import { cn } from "../../lib/utils";
4
4
  import { Loader2 } from "lucide-react";
5
5
 
6
6
  /**
7
- * Premium Button Component
7
+ * MoonUI Button Component
8
8
  *
9
9
  * A world-class, accessible, and versatile button component.
10
10
  * Pixel-perfect design with extensive variants and states.
11
11
  */
12
- const buttonVariants = cva(
12
+ const moonUIButtonVariants = cva(
13
13
  ["inline-flex items-center justify-center gap-2 whitespace-nowrap",
14
14
  "font-medium relative",
15
15
  "transition-all duration-200 ease-out",
@@ -156,10 +156,10 @@ const buttonVariants = cva(
156
156
  }
157
157
  );
158
158
 
159
- // Button component props
160
- export interface ButtonProps
159
+ // MoonUI Button component props
160
+ export interface MoonUIButtonProps
161
161
  extends React.ButtonHTMLAttributes<HTMLButtonElement>,
162
- VariantProps<typeof buttonVariants> {
162
+ VariantProps<typeof moonUIButtonVariants> {
163
163
  asChild?: boolean;
164
164
  loading?: boolean;
165
165
  leftIcon?: React.ReactNode;
@@ -167,9 +167,9 @@ export interface ButtonProps
167
167
  }
168
168
 
169
169
  /**
170
- * Premium Button Component
170
+ * MoonUI Button Component
171
171
  *
172
- * @param props - Button component properties
172
+ * @param props - MoonUI Button component properties
173
173
  * @param props.variant - Visual variant (primary, secondary, ghost, etc.)
174
174
  * @param props.size - Button size (xs, sm, md, lg, xl)
175
175
  * @param props.loading - Loading state display
@@ -179,7 +179,7 @@ export interface ButtonProps
179
179
  * @param props.rounded - Corner rounding style (default, full, none)
180
180
  * @param props.asChild - For Radix UI polymorphic component
181
181
  */
182
- const Button = React.forwardRef<HTMLButtonElement, ButtonProps>(
182
+ const MoonUIButton = React.forwardRef<HTMLButtonElement, MoonUIButtonProps>(
183
183
  ({
184
184
  className,
185
185
  variant,
@@ -199,7 +199,7 @@ const Button = React.forwardRef<HTMLButtonElement, ButtonProps>(
199
199
 
200
200
  return (
201
201
  <Comp
202
- className={cn(buttonVariants({ variant, size, rounded, fullWidth, className }))}
202
+ className={cn(moonUIButtonVariants({ variant, size, rounded, fullWidth, className }))}
203
203
  ref={ref}
204
204
  disabled={disabled || loading}
205
205
  data-loading={loading ? "" : undefined}
@@ -216,6 +216,10 @@ const Button = React.forwardRef<HTMLButtonElement, ButtonProps>(
216
216
  }
217
217
  );
218
218
 
219
- Button.displayName = "Button";
219
+ MoonUIButton.displayName = "MoonUIButton";
220
220
 
221
- export { Button, buttonVariants };
221
+ export { MoonUIButton, moonUIButtonVariants };
222
+
223
+ // Backward compatibility exports
224
+ export { MoonUIButton as Button, moonUIButtonVariants as buttonVariants };
225
+ export type { MoonUIButtonProps as ButtonProps };