fermmap-shared 0.1.1 → 0.1.3
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 +1 -1
- package/README.md +0 -66
- package/dist/main.cjs.map +1 -1
- package/dist/module.mjs.map +1 -1
- package/dist/types.d.ts.map +1 -1
- package/package.json +15 -2
package/LICENSE
CHANGED
package/README.md
CHANGED
|
@@ -6,72 +6,6 @@
|
|
|
6
6
|
|
|
7
7
|
This package contains a collection of accessible, themeable React components designed for the FermMap application. All components are built on top of React Aria Components for accessibility and use React Spectrum S2 style-macros for consistent, type-safe styling.
|
|
8
8
|
|
|
9
|
-
## Publishing to npm
|
|
10
|
-
|
|
11
|
-
### Prerequisites
|
|
12
|
-
- npm account with publishing rights
|
|
13
|
-
- Logged in via `npm login`
|
|
14
|
-
- **Granular Access Token**: For automated publishing, you'll need a granular access token with publish permissions
|
|
15
|
-
|
|
16
|
-
### Before Publishing
|
|
17
|
-
|
|
18
|
-
1. **Update version** in `package.json`:
|
|
19
|
-
```json
|
|
20
|
-
{
|
|
21
|
-
"version": "0.2.0" // Increment appropriately
|
|
22
|
-
}
|
|
23
|
-
```
|
|
24
|
-
|
|
25
|
-
2. **Set package to public** (if first time publishing):
|
|
26
|
-
```json
|
|
27
|
-
{
|
|
28
|
-
"private": false // Change from true
|
|
29
|
-
}
|
|
30
|
-
```
|
|
31
|
-
|
|
32
|
-
3. **Update repository URL** in `package.json`:
|
|
33
|
-
```json
|
|
34
|
-
{
|
|
35
|
-
"repository": {
|
|
36
|
-
"type": "git",
|
|
37
|
-
"url": "https://github.com/your-actual-username/fermmap.git",
|
|
38
|
-
"directory": "packages/shared"
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
```
|
|
42
|
-
|
|
43
|
-
### Publishing
|
|
44
|
-
|
|
45
|
-
The package uses **Parcel** to build optimized CommonJS and ESM bundles with CSS extracted from style macros.
|
|
46
|
-
|
|
47
|
-
To publish:
|
|
48
|
-
|
|
49
|
-
```bash
|
|
50
|
-
# Build and publish (prepublishOnly script runs automatically)
|
|
51
|
-
npm publish
|
|
52
|
-
|
|
53
|
-
# Or manually:
|
|
54
|
-
yarn build
|
|
55
|
-
npm publish
|
|
56
|
-
```
|
|
57
|
-
|
|
58
|
-
The `prepublishOnly` script automatically cleans and builds before publishing.
|
|
59
|
-
|
|
60
|
-
### Important Notes
|
|
61
|
-
|
|
62
|
-
- **Build Process**: Uses Parcel to compile TypeScript and extract/optimize CSS from S2 style-macros
|
|
63
|
-
- **Output**: CommonJS (`dist/main.cjs`), ESM (`dist/module.mjs`), TypeScript types (`dist/types.d.ts`), and optimized CSS
|
|
64
|
-
- **CSS Files**: Style macro CSS is automatically extracted and optimized during build
|
|
65
|
-
- **Granular Token**: For CI/CD, create a granular access token at https://www.npmjs.com/settings/YOUR-USERNAME/tokens
|
|
66
|
-
- **Peer Dependencies**: Consuming apps must install:
|
|
67
|
-
- `react` ^18.2.0
|
|
68
|
-
- `react-dom` ^18.2.0
|
|
69
|
-
- `react-aria-components` ^1.13.0
|
|
70
|
-
- `@react-spectrum/s2` ^0.12.0
|
|
71
|
-
- `react-intl` ^6.0.0
|
|
72
|
-
- `next` ^14.0.0 (optional, only for SegmentedControl)
|
|
73
|
-
- `@axe-core/react` ^4.0.0 (optional, only for dev tools)
|
|
74
|
-
|
|
75
9
|
## Installation
|
|
76
10
|
|
|
77
11
|
```bash
|