@storm-ds/ui 0.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/LICENSE +21 -0
- package/README.md +33 -0
- package/dist/charts.d.mts +136 -0
- package/dist/charts.d.ts +136 -0
- package/dist/charts.js +406 -0
- package/dist/charts.js.map +1 -0
- package/dist/charts.mjs +410 -0
- package/dist/charts.mjs.map +1 -0
- package/dist/index.d.mts +927 -0
- package/dist/index.d.ts +927 -0
- package/dist/index.js +3987 -0
- package/dist/index.js.map +1 -0
- package/dist/index.mjs +3987 -0
- package/dist/index.mjs.map +1 -0
- package/dist/plugin.d.mts +8 -0
- package/dist/plugin.d.ts +8 -0
- package/dist/plugin.js +159 -0
- package/dist/plugin.js.map +1 -0
- package/dist/plugin.mjs +128 -0
- package/dist/plugin.mjs.map +1 -0
- package/package.json +72 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Samy H.
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# Storm UI
|
|
2
|
+
|
|
3
|
+
Lightning-fast component library optimized for Next.js.
|
|
4
|
+
|
|
5
|
+
## Installation
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm install storm-ui
|
|
9
|
+
# or
|
|
10
|
+
pnpm add storm-ui
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
## Usage
|
|
14
|
+
|
|
15
|
+
```tsx
|
|
16
|
+
import { Button } from '@storm-ds/ui'
|
|
17
|
+
|
|
18
|
+
export default function Home() {
|
|
19
|
+
return <Button>Click me</Button>
|
|
20
|
+
}
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
## Features
|
|
24
|
+
|
|
25
|
+
- 🚀 Optimized for Next.js (Server Components compatible)
|
|
26
|
+
- 💎 TypeScript with sensible defaults
|
|
27
|
+
- 🎨 Tailwind CSS (customizable via CSS variables)
|
|
28
|
+
- 📦 Zero external dependencies (except Tailwind utilities)
|
|
29
|
+
- 📋 Copy-paste friendly
|
|
30
|
+
|
|
31
|
+
## License
|
|
32
|
+
|
|
33
|
+
MIT
|
|
@@ -0,0 +1,136 @@
|
|
|
1
|
+
import * as react from 'react';
|
|
2
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
3
|
+
|
|
4
|
+
interface ChartContainerProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
5
|
+
height?: number;
|
|
6
|
+
}
|
|
7
|
+
declare const ChartContainer: react.ForwardRefExoticComponent<ChartContainerProps & react.RefAttributes<HTMLDivElement>>;
|
|
8
|
+
|
|
9
|
+
interface ChartTooltipContentProps {
|
|
10
|
+
active?: boolean;
|
|
11
|
+
payload?: Array<{
|
|
12
|
+
name: string;
|
|
13
|
+
value: number;
|
|
14
|
+
color?: string;
|
|
15
|
+
fill?: string;
|
|
16
|
+
dataKey?: string;
|
|
17
|
+
}>;
|
|
18
|
+
label?: string;
|
|
19
|
+
className?: string;
|
|
20
|
+
formatter?: (value: number, name: string) => string;
|
|
21
|
+
labelFormatter?: (label: string) => string;
|
|
22
|
+
hideLabel?: boolean;
|
|
23
|
+
}
|
|
24
|
+
declare function ChartTooltipContent({ active, payload, label, className, formatter, labelFormatter, hideLabel, }: ChartTooltipContentProps): react_jsx_runtime.JSX.Element | null;
|
|
25
|
+
declare namespace ChartTooltipContent {
|
|
26
|
+
var displayName: string;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
interface StormAreaChartProps {
|
|
30
|
+
data: Record<string, unknown>[];
|
|
31
|
+
categories: string[];
|
|
32
|
+
index: string;
|
|
33
|
+
colors?: string[];
|
|
34
|
+
height?: number;
|
|
35
|
+
stacked?: boolean;
|
|
36
|
+
gradient?: boolean;
|
|
37
|
+
curved?: boolean;
|
|
38
|
+
showGrid?: boolean;
|
|
39
|
+
showXAxis?: boolean;
|
|
40
|
+
showYAxis?: boolean;
|
|
41
|
+
className?: string;
|
|
42
|
+
}
|
|
43
|
+
declare function StormAreaChart({ data, categories, index, colors, height, stacked, gradient, curved, showGrid, showXAxis, showYAxis, className, }: StormAreaChartProps): react_jsx_runtime.JSX.Element;
|
|
44
|
+
declare namespace StormAreaChart {
|
|
45
|
+
var displayName: string;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
interface StormBarChartProps {
|
|
49
|
+
data: Record<string, unknown>[];
|
|
50
|
+
categories: string[];
|
|
51
|
+
index: string;
|
|
52
|
+
colors?: string[];
|
|
53
|
+
height?: number;
|
|
54
|
+
stacked?: boolean;
|
|
55
|
+
horizontal?: boolean;
|
|
56
|
+
showGrid?: boolean;
|
|
57
|
+
showXAxis?: boolean;
|
|
58
|
+
showYAxis?: boolean;
|
|
59
|
+
radius?: number;
|
|
60
|
+
className?: string;
|
|
61
|
+
}
|
|
62
|
+
declare function StormBarChart({ data, categories, index, colors, height, stacked, horizontal, showGrid, showXAxis, showYAxis, radius, className, }: StormBarChartProps): react_jsx_runtime.JSX.Element;
|
|
63
|
+
declare namespace StormBarChart {
|
|
64
|
+
var displayName: string;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
interface StormLineChartProps {
|
|
68
|
+
data: Record<string, unknown>[];
|
|
69
|
+
categories: string[];
|
|
70
|
+
index: string;
|
|
71
|
+
colors?: string[];
|
|
72
|
+
height?: number;
|
|
73
|
+
curved?: boolean;
|
|
74
|
+
showGrid?: boolean;
|
|
75
|
+
showXAxis?: boolean;
|
|
76
|
+
showYAxis?: boolean;
|
|
77
|
+
showDots?: boolean;
|
|
78
|
+
strokeWidth?: number;
|
|
79
|
+
className?: string;
|
|
80
|
+
}
|
|
81
|
+
declare function StormLineChart({ data, categories, index, colors, height, curved, showGrid, showXAxis, showYAxis, showDots, strokeWidth, className, }: StormLineChartProps): react_jsx_runtime.JSX.Element;
|
|
82
|
+
declare namespace StormLineChart {
|
|
83
|
+
var displayName: string;
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
interface StormPieChartProps {
|
|
87
|
+
data: Array<{
|
|
88
|
+
name: string;
|
|
89
|
+
value: number;
|
|
90
|
+
color?: string;
|
|
91
|
+
}>;
|
|
92
|
+
colors?: string[];
|
|
93
|
+
height?: number;
|
|
94
|
+
donut?: boolean;
|
|
95
|
+
showLabel?: boolean;
|
|
96
|
+
className?: string;
|
|
97
|
+
}
|
|
98
|
+
declare function StormPieChart({ data, colors, height, donut, showLabel, className, }: StormPieChartProps): react_jsx_runtime.JSX.Element;
|
|
99
|
+
declare namespace StormPieChart {
|
|
100
|
+
var displayName: string;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
interface StormRadarChartProps {
|
|
104
|
+
data: Record<string, unknown>[];
|
|
105
|
+
categories: string[];
|
|
106
|
+
index: string;
|
|
107
|
+
colors?: string[];
|
|
108
|
+
height?: number;
|
|
109
|
+
filled?: boolean;
|
|
110
|
+
className?: string;
|
|
111
|
+
}
|
|
112
|
+
declare function StormRadarChart({ data, categories, index, colors, height, filled, className, }: StormRadarChartProps): react_jsx_runtime.JSX.Element;
|
|
113
|
+
declare namespace StormRadarChart {
|
|
114
|
+
var displayName: string;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
interface StormRadialChartProps {
|
|
118
|
+
data: Array<{
|
|
119
|
+
name: string;
|
|
120
|
+
value: number;
|
|
121
|
+
fill?: string;
|
|
122
|
+
}>;
|
|
123
|
+
colors?: string[];
|
|
124
|
+
height?: number;
|
|
125
|
+
startAngle?: number;
|
|
126
|
+
endAngle?: number;
|
|
127
|
+
innerRadius?: string;
|
|
128
|
+
outerRadius?: string;
|
|
129
|
+
className?: string;
|
|
130
|
+
}
|
|
131
|
+
declare function StormRadialChart({ data, colors, height, startAngle, endAngle, innerRadius, outerRadius, className, }: StormRadialChartProps): react_jsx_runtime.JSX.Element;
|
|
132
|
+
declare namespace StormRadialChart {
|
|
133
|
+
var displayName: string;
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
export { ChartContainer, type ChartContainerProps, ChartTooltipContent, type ChartTooltipContentProps, StormAreaChart, type StormAreaChartProps, StormBarChart, type StormBarChartProps, StormLineChart, type StormLineChartProps, StormPieChart, type StormPieChartProps, StormRadarChart, type StormRadarChartProps, StormRadialChart, type StormRadialChartProps };
|
package/dist/charts.d.ts
ADDED
|
@@ -0,0 +1,136 @@
|
|
|
1
|
+
import * as react from 'react';
|
|
2
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
3
|
+
|
|
4
|
+
interface ChartContainerProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
5
|
+
height?: number;
|
|
6
|
+
}
|
|
7
|
+
declare const ChartContainer: react.ForwardRefExoticComponent<ChartContainerProps & react.RefAttributes<HTMLDivElement>>;
|
|
8
|
+
|
|
9
|
+
interface ChartTooltipContentProps {
|
|
10
|
+
active?: boolean;
|
|
11
|
+
payload?: Array<{
|
|
12
|
+
name: string;
|
|
13
|
+
value: number;
|
|
14
|
+
color?: string;
|
|
15
|
+
fill?: string;
|
|
16
|
+
dataKey?: string;
|
|
17
|
+
}>;
|
|
18
|
+
label?: string;
|
|
19
|
+
className?: string;
|
|
20
|
+
formatter?: (value: number, name: string) => string;
|
|
21
|
+
labelFormatter?: (label: string) => string;
|
|
22
|
+
hideLabel?: boolean;
|
|
23
|
+
}
|
|
24
|
+
declare function ChartTooltipContent({ active, payload, label, className, formatter, labelFormatter, hideLabel, }: ChartTooltipContentProps): react_jsx_runtime.JSX.Element | null;
|
|
25
|
+
declare namespace ChartTooltipContent {
|
|
26
|
+
var displayName: string;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
interface StormAreaChartProps {
|
|
30
|
+
data: Record<string, unknown>[];
|
|
31
|
+
categories: string[];
|
|
32
|
+
index: string;
|
|
33
|
+
colors?: string[];
|
|
34
|
+
height?: number;
|
|
35
|
+
stacked?: boolean;
|
|
36
|
+
gradient?: boolean;
|
|
37
|
+
curved?: boolean;
|
|
38
|
+
showGrid?: boolean;
|
|
39
|
+
showXAxis?: boolean;
|
|
40
|
+
showYAxis?: boolean;
|
|
41
|
+
className?: string;
|
|
42
|
+
}
|
|
43
|
+
declare function StormAreaChart({ data, categories, index, colors, height, stacked, gradient, curved, showGrid, showXAxis, showYAxis, className, }: StormAreaChartProps): react_jsx_runtime.JSX.Element;
|
|
44
|
+
declare namespace StormAreaChart {
|
|
45
|
+
var displayName: string;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
interface StormBarChartProps {
|
|
49
|
+
data: Record<string, unknown>[];
|
|
50
|
+
categories: string[];
|
|
51
|
+
index: string;
|
|
52
|
+
colors?: string[];
|
|
53
|
+
height?: number;
|
|
54
|
+
stacked?: boolean;
|
|
55
|
+
horizontal?: boolean;
|
|
56
|
+
showGrid?: boolean;
|
|
57
|
+
showXAxis?: boolean;
|
|
58
|
+
showYAxis?: boolean;
|
|
59
|
+
radius?: number;
|
|
60
|
+
className?: string;
|
|
61
|
+
}
|
|
62
|
+
declare function StormBarChart({ data, categories, index, colors, height, stacked, horizontal, showGrid, showXAxis, showYAxis, radius, className, }: StormBarChartProps): react_jsx_runtime.JSX.Element;
|
|
63
|
+
declare namespace StormBarChart {
|
|
64
|
+
var displayName: string;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
interface StormLineChartProps {
|
|
68
|
+
data: Record<string, unknown>[];
|
|
69
|
+
categories: string[];
|
|
70
|
+
index: string;
|
|
71
|
+
colors?: string[];
|
|
72
|
+
height?: number;
|
|
73
|
+
curved?: boolean;
|
|
74
|
+
showGrid?: boolean;
|
|
75
|
+
showXAxis?: boolean;
|
|
76
|
+
showYAxis?: boolean;
|
|
77
|
+
showDots?: boolean;
|
|
78
|
+
strokeWidth?: number;
|
|
79
|
+
className?: string;
|
|
80
|
+
}
|
|
81
|
+
declare function StormLineChart({ data, categories, index, colors, height, curved, showGrid, showXAxis, showYAxis, showDots, strokeWidth, className, }: StormLineChartProps): react_jsx_runtime.JSX.Element;
|
|
82
|
+
declare namespace StormLineChart {
|
|
83
|
+
var displayName: string;
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
interface StormPieChartProps {
|
|
87
|
+
data: Array<{
|
|
88
|
+
name: string;
|
|
89
|
+
value: number;
|
|
90
|
+
color?: string;
|
|
91
|
+
}>;
|
|
92
|
+
colors?: string[];
|
|
93
|
+
height?: number;
|
|
94
|
+
donut?: boolean;
|
|
95
|
+
showLabel?: boolean;
|
|
96
|
+
className?: string;
|
|
97
|
+
}
|
|
98
|
+
declare function StormPieChart({ data, colors, height, donut, showLabel, className, }: StormPieChartProps): react_jsx_runtime.JSX.Element;
|
|
99
|
+
declare namespace StormPieChart {
|
|
100
|
+
var displayName: string;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
interface StormRadarChartProps {
|
|
104
|
+
data: Record<string, unknown>[];
|
|
105
|
+
categories: string[];
|
|
106
|
+
index: string;
|
|
107
|
+
colors?: string[];
|
|
108
|
+
height?: number;
|
|
109
|
+
filled?: boolean;
|
|
110
|
+
className?: string;
|
|
111
|
+
}
|
|
112
|
+
declare function StormRadarChart({ data, categories, index, colors, height, filled, className, }: StormRadarChartProps): react_jsx_runtime.JSX.Element;
|
|
113
|
+
declare namespace StormRadarChart {
|
|
114
|
+
var displayName: string;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
interface StormRadialChartProps {
|
|
118
|
+
data: Array<{
|
|
119
|
+
name: string;
|
|
120
|
+
value: number;
|
|
121
|
+
fill?: string;
|
|
122
|
+
}>;
|
|
123
|
+
colors?: string[];
|
|
124
|
+
height?: number;
|
|
125
|
+
startAngle?: number;
|
|
126
|
+
endAngle?: number;
|
|
127
|
+
innerRadius?: string;
|
|
128
|
+
outerRadius?: string;
|
|
129
|
+
className?: string;
|
|
130
|
+
}
|
|
131
|
+
declare function StormRadialChart({ data, colors, height, startAngle, endAngle, innerRadius, outerRadius, className, }: StormRadialChartProps): react_jsx_runtime.JSX.Element;
|
|
132
|
+
declare namespace StormRadialChart {
|
|
133
|
+
var displayName: string;
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
export { ChartContainer, type ChartContainerProps, ChartTooltipContent, type ChartTooltipContentProps, StormAreaChart, type StormAreaChartProps, StormBarChart, type StormBarChartProps, StormLineChart, type StormLineChartProps, StormPieChart, type StormPieChartProps, StormRadarChart, type StormRadarChartProps, StormRadialChart, type StormRadialChartProps };
|