oihana-next-ui 0.1.0 → 0.1.2
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 +86 -7
- package/package.json +5 -2
package/README.md
CHANGED
|
@@ -4,6 +4,22 @@
|
|
|
4
4
|
|
|
5
5
|
A modular Next.js UI component library built with React 19, Tailwind CSS v4 and DaisyUI v5.
|
|
6
6
|
|
|
7
|
+
[](https://www.npmjs.com/package/oihana-next-ui)
|
|
8
|
+
[](https://www.npmjs.com/package/oihana-next-ui)
|
|
9
|
+
[](LICENSE)
|
|
10
|
+
|
|
11
|
+
## Built with
|
|
12
|
+
|
|
13
|
+
- [Next.js](https://nextjs.org/) — React framework for production
|
|
14
|
+
- [React](https://fr.react.dev/) — UI library
|
|
15
|
+
- [Tailwind CSS](https://tailwindcss.com/) — Utility-first CSS framework
|
|
16
|
+
- [DaisyUI](https://daisyui.com/) — Component library for Tailwind CSS
|
|
17
|
+
- [React Icons](https://react-icons.github.io/react-icons/) — Popular icon packs as React components
|
|
18
|
+
- [Motion](https://motion.dev/) — Animation library
|
|
19
|
+
- [Maskito](https://maskito.dev/) — Input masking library
|
|
20
|
+
- [Day.js](https://day.js.org/) — Lightweight date library
|
|
21
|
+
- [Chroma.js](https://www.vis4.net/chromajs/) — Color manipulation library
|
|
22
|
+
|
|
7
23
|
## Features
|
|
8
24
|
|
|
9
25
|
- ⚛️ React 19 + Next.js 16
|
|
@@ -16,9 +32,9 @@ A modular Next.js UI component library built with React 19, Tailwind CSS v4 and
|
|
|
16
32
|
## Installation
|
|
17
33
|
|
|
18
34
|
```bash
|
|
19
|
-
bun add
|
|
35
|
+
bun add oihana-next-ui
|
|
20
36
|
# or
|
|
21
|
-
npm install
|
|
37
|
+
npm install oihana-next-ui
|
|
22
38
|
```
|
|
23
39
|
|
|
24
40
|
## Requirements
|
|
@@ -34,9 +50,40 @@ npm install @oihana/next-ui
|
|
|
34
50
|
## Usage
|
|
35
51
|
|
|
36
52
|
```jsx
|
|
37
|
-
import Picture
|
|
38
|
-
import Button
|
|
39
|
-
import useThemes from '
|
|
53
|
+
import Picture from 'oihana-next-ui/components/images/Picture'
|
|
54
|
+
import Button from 'oihana-next-ui/components/Button'
|
|
55
|
+
import useThemes from 'oihana-next-ui/contexts/themes/useThemes'
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
### CSS
|
|
59
|
+
|
|
60
|
+
Some components require their stylesheet to be imported explicitly :
|
|
61
|
+
|
|
62
|
+
```css
|
|
63
|
+
/* Spinner styles */
|
|
64
|
+
@import 'oihana-next-ui/components/spinners/styles/battery.css';
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
### Tailwind CSS v4 plugins
|
|
68
|
+
|
|
69
|
+
With Tailwind CSS v4, plugins are registered directly in your CSS file :
|
|
70
|
+
|
|
71
|
+
```css
|
|
72
|
+
/* globals.css */
|
|
73
|
+
@import 'tailwindcss' ;
|
|
74
|
+
|
|
75
|
+
/* Oihana background patterns plugin */
|
|
76
|
+
@plugin 'oihana-next-ui/themes/plugins/background-patterns/index' ;
|
|
77
|
+
|
|
78
|
+
/* Oihana pattern craft plugin */
|
|
79
|
+
@plugin 'oihana-next-ui/themes/plugins/pattern-craft/index' ;
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
### DaisyUI Catppuccin theme
|
|
83
|
+
|
|
84
|
+
```css
|
|
85
|
+
/* globals.css */
|
|
86
|
+
@import 'oihana-next-ui/themes/daisyui/catppuccin.css' ;
|
|
40
87
|
```
|
|
41
88
|
|
|
42
89
|
## Development
|
|
@@ -52,18 +99,50 @@ bun dev
|
|
|
52
99
|
|
|
53
100
|
Open [http://localhost:3666](http://localhost:3666) to browse the component demos.
|
|
54
101
|
|
|
55
|
-
Build the library
|
|
102
|
+
### Build the library
|
|
56
103
|
|
|
57
104
|
```bash
|
|
58
105
|
bun run build:lib
|
|
59
106
|
```
|
|
60
107
|
|
|
61
|
-
Watch mode
|
|
108
|
+
### Watch mode
|
|
62
109
|
|
|
63
110
|
```bash
|
|
64
111
|
bun run build:lib:watch
|
|
65
112
|
```
|
|
66
113
|
|
|
114
|
+
## Release
|
|
115
|
+
|
|
116
|
+
### Versioning
|
|
117
|
+
|
|
118
|
+
This project follows [Semantic Versioning](https://semver.org/) — `MAJOR.MINOR.PATCH` (e.g. `1.2.3`).
|
|
119
|
+
|
|
120
|
+
| Type | Command | Example | When to use |
|
|
121
|
+
|------|---------|---------|-------------|
|
|
122
|
+
| Patch | `bun run release:patch` | `0.1.0` → `0.1.1` | Bug fix, minor tweak |
|
|
123
|
+
| Minor | `bun run release:minor` | `0.1.0` → `0.2.0` | New component or feature, backward compatible |
|
|
124
|
+
| Major | `bun run release:major` | `0.1.0` → `1.0.0` | Breaking change |
|
|
125
|
+
|
|
126
|
+
Each script automatically bumps the version, builds the library, publishes to npm, and pushes the commit and tag to GitHub.
|
|
127
|
+
|
|
128
|
+
You can also set a specific version manually :
|
|
129
|
+
|
|
130
|
+
```bash
|
|
131
|
+
npm version 1.0.0
|
|
132
|
+
bun run release
|
|
133
|
+
```
|
|
134
|
+
|
|
135
|
+
Or a pre-release version :
|
|
136
|
+
|
|
137
|
+
```bash
|
|
138
|
+
npm version prerelease --preid=alpha # 0.1.0 → 0.1.1-alpha.0
|
|
139
|
+
npm version prerelease --preid=beta # 0.1.0 → 0.1.1-beta.0
|
|
140
|
+
npm version prerelease --preid=rc # 0.1.0 → 0.1.1-rc.0
|
|
141
|
+
bun run release
|
|
142
|
+
```
|
|
143
|
+
|
|
144
|
+
`npm version` automatically updates `package.json`, creates a Git commit and a Git tag.
|
|
145
|
+
|
|
67
146
|
## License
|
|
68
147
|
|
|
69
148
|
[Mozilla Public License 2.0](./LICENSE) — © Marc Alcaraz
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "oihana-next-ui",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.2",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "Oihana Next.js UI component library — reusable components, hooks and utilities built with React 19, Next.js, Tailwind CSS and DaisyUI",
|
|
6
6
|
"author": {
|
|
@@ -52,7 +52,10 @@
|
|
|
52
52
|
"build": "next build",
|
|
53
53
|
"build:lib": "tsup",
|
|
54
54
|
"build:lib:watch": "tsup --watch",
|
|
55
|
-
"release": "bun run build:lib && npm publish --access public",
|
|
55
|
+
"release": "bun run build:lib && npm publish --access public && git push origin-ssh && git push origin-ssh --tags",
|
|
56
|
+
"release:patch": "npm version patch && bun run release",
|
|
57
|
+
"release:minor": "npm version minor && bun run release",
|
|
58
|
+
"release:major": "npm version major && bun run release",
|
|
56
59
|
"start": "next start",
|
|
57
60
|
"lint": "biome check",
|
|
58
61
|
"format": "biome format --write",
|