@birbalkr/buildui 1.0.5 → 1.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.
- package/README.md +47 -0
- package/package.json +10 -1
package/README.md
ADDED
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
# BuildUI
|
|
2
|
+
|
|
3
|
+
A collection of reusable React + TypeScript + Tailwind CSS UI components.
|
|
4
|
+
|
|
5
|
+
## Installation
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm install @birbalkr/buildui react react-dom
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Usage
|
|
12
|
+
|
|
13
|
+
```tsx
|
|
14
|
+
import { Button } from '@birbalkr/buildui';
|
|
15
|
+
|
|
16
|
+
function App() {
|
|
17
|
+
return (
|
|
18
|
+
<div>
|
|
19
|
+
<Button text="Click me" size="md" theme="primary" onClick={() => console.log("clicked")} />
|
|
20
|
+
</div>
|
|
21
|
+
);
|
|
22
|
+
}
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
No separate CSS import is needed — styles are bundled automatically.
|
|
26
|
+
|
|
27
|
+
## Components
|
|
28
|
+
|
|
29
|
+
### Button
|
|
30
|
+
|
|
31
|
+
| Prop | Type | Default | Description |
|
|
32
|
+
|----------|-----------------------------------------|-------------|---------------------------------------|
|
|
33
|
+
| `text` | `string` | — | Button label (ignored if `children` passed) |
|
|
34
|
+
| `size` | `"sm" \| "md" \| "lg"` | `"md"` | Button size |
|
|
35
|
+
| `theme` | `"primary" \| "secondary" \| "tertiary"`| `"primary"` | Color theme |
|
|
36
|
+
| `children` | `ReactNode` | — | Overrides `text` if provided |
|
|
37
|
+
| ...rest | native `<button>` attributes | — | `onClick`, `disabled`, `className`, etc. |
|
|
38
|
+
|
|
39
|
+
```tsx
|
|
40
|
+
<Button text="Small" size="sm" />
|
|
41
|
+
<Button theme="secondary">Click me</Button>
|
|
42
|
+
<Button theme="tertiary" size="lg" onClick={() => alert("hi")} />
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
## License
|
|
46
|
+
|
|
47
|
+
MIT
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@birbalkr/buildui",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.6",
|
|
4
4
|
"description": "BuildUI is a collection of reusable React + TypeScript + Tailwind CSS UI components, animations, layouts, and interaction patterns.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -10,6 +10,15 @@
|
|
|
10
10
|
"sideEffects": [
|
|
11
11
|
"**/*.css"
|
|
12
12
|
],
|
|
13
|
+
"keywords": [
|
|
14
|
+
"react",
|
|
15
|
+
"typescript",
|
|
16
|
+
"tailwindcss",
|
|
17
|
+
"ui",
|
|
18
|
+
"components",
|
|
19
|
+
"button",
|
|
20
|
+
"component-library"
|
|
21
|
+
],
|
|
13
22
|
"exports": {
|
|
14
23
|
".": {
|
|
15
24
|
"types": "./dist/index.d.ts",
|