@moontra/moonui-pro 2.18.6 → 2.20.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.
Files changed (49) hide show
  1. package/dist/index.d.ts +3251 -0
  2. package/dist/index.mjs +2704 -1479
  3. package/package.json +137 -136
  4. package/src/__tests__/use-local-storage.test.tsx +2 -2
  5. package/src/components/advanced-chart/index.tsx +6 -6
  6. package/src/components/animated-button/index.tsx +240 -53
  7. package/src/components/calendar/event-dialog.tsx +1 -1
  8. package/src/components/calendar/index.tsx +1 -1
  9. package/src/components/calendar-pro/index.tsx +2 -4
  10. package/src/components/dashboard/demo.tsx +2 -2
  11. package/src/components/dashboard/widgets/activity-feed.tsx +1 -1
  12. package/src/components/dashboard/widgets/metric-card.tsx +1 -1
  13. package/src/components/enhanced/button.tsx +13 -13
  14. package/src/components/file-upload/file-upload.test.tsx +20 -19
  15. package/src/components/form-wizard/form-wizard-progress.tsx +7 -7
  16. package/src/components/gesture-drawer/index.tsx +551 -0
  17. package/src/components/github-stars/hooks.ts +1 -1
  18. package/src/components/github-stars/index.tsx +1 -1
  19. package/src/components/github-stars/types.ts +1 -0
  20. package/src/components/health-check/index.tsx +2 -2
  21. package/src/components/hover-card-3d/index.tsx +437 -74
  22. package/src/components/index.ts +15 -2
  23. package/src/components/lazy-component/index.tsx +4 -2
  24. package/src/components/license-error/index.tsx +29 -0
  25. package/src/components/memory-efficient-data/index.tsx +1 -1
  26. package/src/components/pinch-zoom/index.tsx +438 -42
  27. package/src/components/rich-text-editor/index.tsx +12 -12
  28. package/src/components/timeline/index.tsx +2 -2
  29. package/src/components/ui/aspect-ratio.tsx +186 -22
  30. package/src/components/ui/button.tsx +47 -50
  31. package/src/components/ui/card.tsx +98 -30
  32. package/src/components/ui/gesture-drawer.tsx +11 -0
  33. package/src/components/ui/index.ts +18 -1
  34. package/src/components/ui/lightbox.tsx +606 -0
  35. package/src/components/ui/media-gallery.tsx +612 -0
  36. package/src/components/ui/select.tsx +134 -35
  37. package/src/components/ui/toggle.tsx +78 -15
  38. package/src/components/virtual-list/index.tsx +7 -7
  39. package/src/index.ts +4 -4
  40. package/src/lib/component-metadata.ts +18 -0
  41. package/src/lib/paddle.ts +17 -0
  42. package/src/patterns/login-form/index.tsx +1 -1
  43. package/src/patterns/login-form/types.ts +6 -6
  44. package/src/styles/index.css +14 -4
  45. package/src/types/next-auth.d.ts +21 -0
  46. package/src/use-local-storage.tsx +3 -3
  47. package/src/use-scroll-animation.ts +3 -5
  48. package/src/components/ui/animated-button.tsx +0 -185
  49. package/src/components/ui/hover-card-3d.tsx +0 -103
package/package.json CHANGED
@@ -1,139 +1,140 @@
1
1
  {
2
- "name": "@moontra/moonui-pro",
3
- "version": "2.18.6",
4
- "description": "Premium React components for MoonUI - Advanced UI library with 50+ pro components including performance, interactive, and gesture components",
5
- "type": "module",
6
- "main": "dist/index.mjs",
7
- "module": "dist/index.mjs",
8
- "types": "dist/index.d.ts",
9
- "files": [
10
- "dist",
11
- "src",
12
- "scripts",
13
- "README.md",
14
- "LICENSE"
15
- ],
16
- "sideEffects": [
17
- "**/*.css",
18
- "dist/**/*.css",
19
- "src/**/*.css"
20
- ],
21
- "exports": {
22
- ".": {
23
- "types": "./dist/index.d.ts",
24
- "import": "./dist/index.mjs",
25
- "require": "./dist/index.js",
26
- "style": "./dist/index.css"
2
+ "name": "@moontra/moonui-pro",
3
+ "version": "2.20.0",
4
+ "description": "Premium React components for MoonUI - Advanced UI library with 50+ pro components including performance, interactive, and gesture components",
5
+ "type": "module",
6
+ "main": "dist/index.mjs",
7
+ "module": "dist/index.mjs",
8
+ "types": "dist/index.d.ts",
9
+ "files": [
10
+ "dist",
11
+ "src",
12
+ "scripts",
13
+ "README.md",
14
+ "LICENSE"
15
+ ],
16
+ "sideEffects": [
17
+ "**/*.css",
18
+ "dist/**/*.css",
19
+ "src/**/*.css"
20
+ ],
21
+ "exports": {
22
+ ".": {
23
+ "types": "./dist/index.d.ts",
24
+ "require": "./dist/index.js",
25
+ "style": "./dist/index.css",
26
+ "import": "./dist/index.mjs"
27
+ },
28
+ "./styles.css": "./dist/index.css",
29
+ "./css": "./dist/index.css"
27
30
  },
28
- "./styles.css": "./dist/index.css",
29
- "./css": "./dist/index.css"
30
- },
31
- "scripts": {
32
- "postinstall": "node scripts/postinstall.js",
33
- "build": "tsup",
34
- "build:dts": "tsup --dts",
35
- "dev": "tsup --watch --sourcemap",
36
- "clean": "rm -rf dist",
37
- "lint": "eslint \"src/**/*.{ts,tsx}\"",
38
- "test": "jest",
39
- "test:watch": "jest --watch",
40
- "test:coverage": "jest --coverage",
41
- "prepublishOnly": "npm run clean && npm run build",
42
- "pub": "npm version patch && npm run build && npm publish",
43
- "pub:minor": "npm version minor && npm run build && npm publish",
44
- "pub:major": "npm version major && npm run build && npm publish"
45
- },
46
- "keywords": [
47
- "ui",
48
- "components",
49
- "react",
50
- "typescript",
51
- "moonui",
52
- "premium",
53
- "pro",
54
- "virtual-list",
55
- "performance",
56
- "memory-efficient",
57
- "animations",
58
- "gestures",
59
- "touch",
60
- "interactive",
61
- "3d-effects",
62
- "charts",
63
- "data-table",
64
- "advanced-components"
65
- ],
66
- "author": "MoonUI Team",
67
- "license": "Commercial",
68
- "repository": {
69
- "type": "git",
70
- "url": "git+https://github.com/moontra/moonui-pro.git"
71
- },
72
- "homepage": "https://moonui.dev",
73
- "peerDependencies": {
74
- "react": ">=18.0.0 || ^19.0.0",
75
- "react-dom": ">=18.0.0 || ^19.0.0"
76
- },
77
- "dependencies": {
78
- "@moontra/moonui": "^2.1.9",
79
- "@radix-ui/react-accordion": "^1.2.11",
80
- "@radix-ui/react-avatar": "^1.1.10",
81
- "@radix-ui/react-checkbox": "^1.3.2",
82
- "@radix-ui/react-dialog": "^1.1.14",
83
- "@radix-ui/react-dropdown-menu": "^2.1.15",
84
- "@radix-ui/react-label": "^2.1.7",
85
- "@radix-ui/react-popover": "^1.1.14",
86
- "@radix-ui/react-scroll-area": "^1.2.9",
87
- "@radix-ui/react-select": "^2.2.5",
88
- "@radix-ui/react-separator": "^1.1.7",
89
- "@radix-ui/react-slot": "^1.2.3",
90
- "@radix-ui/react-switch": "^1.2.5",
91
- "@radix-ui/react-tabs": "^1.1.12",
92
- "@radix-ui/react-toast": "^1.2.14",
93
- "@radix-ui/react-tooltip": "^1.2.7",
94
- "@tanstack/react-table": "^8.20.5",
95
- "canvas-confetti": "^1.9.3",
96
- "class-variance-authority": "^0.7.0",
97
- "clsx": "^2.1.1",
98
- "date-fns": "^3.6.0",
99
- "framer-motion": "^11.11.17",
100
- "lucide-react": "^0.525.0",
101
- "react-beautiful-dnd": "^13.1.1",
102
- "react-colorful": "^5.6.1",
103
- "react-day-picker": "^9.8.0",
104
- "react-dropzone": "^14.3.5",
105
- "react-grid-layout": "^1.5.2",
106
- "react-hook-form": "^7.53.2",
107
- "react-intersection-observer": "^9.13.1",
108
- "react-virtualized-auto-sizer": "^1.0.24",
109
- "react-window": "^1.8.8",
110
- "recharts": "^2.12.7",
111
- "tailwind-merge": "^2.5.4",
112
- "tailwindcss-animate": "^1.0.7"
113
- },
114
- "devDependencies": {
115
- "@testing-library/jest-dom": "^6.6.3",
116
- "@testing-library/react": "^16.3.0",
117
- "@testing-library/user-event": "^14.6.1",
118
- "@types/canvas-confetti": "^1.9.0",
119
- "@types/jest": "^30.0.0",
120
- "@types/node": "^18.16.0",
121
- "@types/react": "^19.0.0",
122
- "@types/react-beautiful-dnd": "^13.1.8",
123
- "@types/react-dom": "^19.0.0",
124
- "@types/react-window": "^1.8.8",
125
- "autoprefixer": "^10.4.21",
126
- "eslint": "^8.39.0",
127
- "jest": "^29.5.0",
128
- "jest-environment-jsdom": "^29.5.0",
129
- "postcss": "^8.5.6",
130
- "tailwindcss": "^3.4.17",
131
- "ts-jest": "^29.1.0",
132
- "tsup": "^6.7.0",
133
- "typescript": "^5.0.4"
134
- },
135
- "publishConfig": {
136
- "access": "public",
137
- "registry": "https://registry.npmjs.org/"
138
- }
31
+ "scripts": {
32
+ "postinstall": "node scripts/postinstall.js",
33
+ "build": "tsup",
34
+ "build:dts": "tsup --dts",
35
+ "dev": "tsup --watch --sourcemap",
36
+ "clean": "rm -rf dist",
37
+ "lint": "eslint \"src/**/*.{ts,tsx}\"",
38
+ "test": "jest",
39
+ "test:watch": "jest --watch",
40
+ "test:coverage": "jest --coverage",
41
+ "prepublishOnly": "npm run clean && npm run build",
42
+ "pub": "npm version patch && npm run build && npm publish",
43
+ "pub:minor": "npm version minor && npm run build && npm publish",
44
+ "pub:major": "npm version major && npm run build && npm publish"
45
+ },
46
+ "keywords": [
47
+ "ui",
48
+ "components",
49
+ "react",
50
+ "typescript",
51
+ "moonui",
52
+ "premium",
53
+ "pro",
54
+ "virtual-list",
55
+ "performance",
56
+ "memory-efficient",
57
+ "animations",
58
+ "gestures",
59
+ "touch",
60
+ "interactive",
61
+ "3d-effects",
62
+ "charts",
63
+ "data-table",
64
+ "advanced-components"
65
+ ],
66
+ "author": "MoonUI Team",
67
+ "license": "Commercial",
68
+ "repository": {
69
+ "type": "git",
70
+ "url": "git+https://github.com/moontra/moonui-pro.git"
71
+ },
72
+ "homepage": "https://moonui.dev",
73
+ "peerDependencies": {
74
+ "react": ">=18.0.0 || ^19.0.0",
75
+ "react-dom": ">=18.0.0 || ^19.0.0"
76
+ },
77
+ "dependencies": {
78
+ "@moontra/moonui": "^2.1.9",
79
+ "@radix-ui/react-accordion": "^1.2.11",
80
+ "@radix-ui/react-avatar": "^1.1.10",
81
+ "@radix-ui/react-checkbox": "^1.3.2",
82
+ "@radix-ui/react-dialog": "^1.1.14",
83
+ "@radix-ui/react-dropdown-menu": "^2.1.15",
84
+ "@radix-ui/react-label": "^2.1.7",
85
+ "@radix-ui/react-popover": "^1.1.14",
86
+ "@radix-ui/react-scroll-area": "^1.2.9",
87
+ "@radix-ui/react-select": "^2.2.5",
88
+ "@radix-ui/react-separator": "^1.1.7",
89
+ "@radix-ui/react-slot": "^1.2.3",
90
+ "@radix-ui/react-switch": "^1.2.5",
91
+ "@radix-ui/react-tabs": "^1.1.12",
92
+ "@radix-ui/react-toast": "^1.2.14",
93
+ "@radix-ui/react-tooltip": "^1.2.7",
94
+ "@tanstack/react-table": "^8.20.5",
95
+ "canvas-confetti": "^1.9.3",
96
+ "class-variance-authority": "^0.7.0",
97
+ "clsx": "^2.1.1",
98
+ "date-fns": "^3.6.0",
99
+ "framer-motion": "^11.11.17",
100
+ "lucide-react": "^0.525.0",
101
+ "react-beautiful-dnd": "^13.1.1",
102
+ "react-colorful": "^5.6.1",
103
+ "react-day-picker": "^9.8.0",
104
+ "react-dropzone": "^14.3.5",
105
+ "react-grid-layout": "^1.5.2",
106
+ "react-hook-form": "^7.53.2",
107
+ "react-intersection-observer": "^9.13.1",
108
+ "react-virtualized-auto-sizer": "^1.0.24",
109
+ "react-window": "^1.8.8",
110
+ "recharts": "^2.12.7",
111
+ "tailwind-merge": "^2.5.4",
112
+ "tailwindcss-animate": "^1.0.7"
113
+ },
114
+ "devDependencies": {
115
+ "@testing-library/jest-dom": "^6.6.3",
116
+ "@testing-library/react": "^16.3.0",
117
+ "@testing-library/user-event": "^14.6.1",
118
+ "@types/canvas-confetti": "^1.9.0",
119
+ "@types/jest": "^30.0.0",
120
+ "@types/node": "^18.16.0",
121
+ "@types/react": "^19.0.0",
122
+ "@types/react-beautiful-dnd": "^13.1.8",
123
+ "@types/react-dom": "^19.0.0",
124
+ "@types/react-grid-layout": "^1.3.5",
125
+ "@types/react-window": "^1.8.8",
126
+ "autoprefixer": "^10.4.21",
127
+ "eslint": "^8.39.0",
128
+ "jest": "^29.5.0",
129
+ "jest-environment-jsdom": "^29.5.0",
130
+ "postcss": "^8.5.6",
131
+ "tailwindcss": "^3.4.17",
132
+ "ts-jest": "^29.1.0",
133
+ "tsup": "^6.7.0",
134
+ "typescript": "^5.0.4"
135
+ },
136
+ "publishConfig": {
137
+ "access": "public",
138
+ "registry": "https://registry.npmjs.org/"
139
+ }
139
140
  }
@@ -63,7 +63,7 @@ describe('useLocalStorage', () => {
63
63
  const { result } = renderHook(() => useLocalStorage('test-key', 10))
64
64
 
65
65
  act(() => {
66
- result.current[1]((prev) => prev + 5)
66
+ result.current[1]((prev) => (prev ?? 0) + 5)
67
67
  })
68
68
 
69
69
  expect(result.current[0]).toBe(15)
@@ -143,7 +143,7 @@ describe('useLocalStorage', () => {
143
143
  })
144
144
 
145
145
  it('handles null values correctly', () => {
146
- const { result } = renderHook(() => useLocalStorage('null-key', null))
146
+ const { result } = renderHook(() => useLocalStorage<string | null>('null-key', null))
147
147
 
148
148
  act(() => {
149
149
  result.current[1]('not-null')
@@ -84,11 +84,11 @@ import {
84
84
 
85
85
  export type ChartType = 'line' | 'bar' | 'area' | 'pie' | 'scatter' | 'composed' | 'radar' | 'radialBar' | 'treemap' | 'funnel'
86
86
 
87
- interface ChartDataPoint {
87
+ export interface ChartDataPoint {
88
88
  [key: string]: string | number | null
89
89
  }
90
90
 
91
- interface ChartSeries {
91
+ export interface ChartSeries {
92
92
  dataKey: string
93
93
  name: string
94
94
  color: string
@@ -190,7 +190,7 @@ const CustomTooltip: React.FC<any> = ({ active, payload, label }) => {
190
190
  initial={{ opacity: 0, scale: 0.9 }}
191
191
  animate={{ opacity: 1, scale: 1 }}
192
192
  exit={{ opacity: 0, scale: 0.9 }}
193
- className="backdrop-blur-xl bg-background/80 dark:bg-gray-900/90 p-3 rounded-xl shadow-2xl border border-border/50 dark:border-gray-700/50"
193
+ className="backdrop-blur-xl bg-background/80 p-3 rounded-xl shadow-2xl border border-border/50"
194
194
  >
195
195
  <p className="text-sm font-medium mb-2">{label}</p>
196
196
  {payload.map((entry: any, index: number) => (
@@ -219,7 +219,7 @@ const CustomLegend: React.FC<any> = ({ payload, onItemClick }) => {
219
219
  onClick={() => onItemClick && onItemClick(entry)}
220
220
  className={cn(
221
221
  "flex items-center gap-2 px-3 py-1.5 rounded-lg transition-all",
222
- "hover:bg-accent/10 dark:hover:bg-gray-800/50",
222
+ "hover:bg-accent/10",
223
223
  entry.inactive && "opacity-50"
224
224
  )}
225
225
  >
@@ -971,13 +971,13 @@ export function AdvancedChart({
971
971
  <TrendingDown className="h-4 w-4 text-red-500 dark:text-red-400" />
972
972
  )}
973
973
  {trend.direction === 'neutral' && (
974
- <Minus className="h-4 w-4 text-gray-500 dark:text-gray-400" />
974
+ <Minus className="h-4 w-4 text-muted-foreground" />
975
975
  )}
976
976
  <span className={cn(
977
977
  "ml-1 text-sm font-semibold",
978
978
  trend.direction === 'up' && "text-green-500 dark:text-green-400",
979
979
  trend.direction === 'down' && "text-red-500 dark:text-red-400",
980
- trend.direction === 'neutral' && "text-gray-500 dark:text-gray-400"
980
+ trend.direction === 'neutral' && "text-muted-foreground"
981
981
  )}>
982
982
  {trend.percentage}%
983
983
  </span>