@jlcpcb/mcp 0.1.1 → 0.3.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/CHANGELOG.md +72 -0
- package/README.md +19 -29
- package/dist/index.js +1271 -1199
- package/package.json +2 -3
- package/src/index.ts +6 -3
- package/src/schemas.ts +14 -0
- package/src/services.ts +34 -0
- package/src/tools/batch.ts +123 -0
- package/src/tools/index.ts +36 -63
- package/src/tools/library-fix.ts +1 -18
- package/src/tools/library-update.ts +8 -27
- package/src/tools/library.ts +108 -149
- package/src/tools/search.ts +68 -10
- package/dist/assets/search.html +0 -528
- package/scripts/build-search-page.ts +0 -68
- package/src/assets/search-built.html +0 -528
- package/src/assets/search.html +0 -458
- package/src/browser/index.ts +0 -381
- package/src/browser/kicad-renderer.ts +0 -646
- package/src/browser/sexpr-parser.ts +0 -321
- package/src/http/routes.ts +0 -253
- package/src/http/server.ts +0 -74
- package/src/tools/details.ts +0 -66
- package/src/tools/easyeda.ts +0 -582
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,77 @@
|
|
|
1
1
|
# @jlcpcb/mcp
|
|
2
2
|
|
|
3
|
+
## 0.3.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- 0.3.0
|
|
8
|
+
|
|
9
|
+
Minor Changes
|
|
10
|
+
|
|
11
|
+
CLI:
|
|
12
|
+
- Add component delete functionality with D shortcut in component view
|
|
13
|
+
- Add O shortcut to open datasheet (replaces D)
|
|
14
|
+
- Add library regenerate command to regenerate all installed components
|
|
15
|
+
- Add validation suite for footprint/symbol comparison (jlc validate)
|
|
16
|
+
- Enable 3D models by default during installation
|
|
17
|
+
- Remove non-functional S/F/M shortcuts from component view
|
|
18
|
+
|
|
19
|
+
Core:
|
|
20
|
+
- Add symbol text parsing and rendering for connector components
|
|
21
|
+
- Add arc interpolation for SOLIDREGION polygon paths (improves complex footprint accuracy)
|
|
22
|
+
- Add remove() method to library service for deleting components
|
|
23
|
+
|
|
24
|
+
Patch Changes
|
|
25
|
+
|
|
26
|
+
Core:
|
|
27
|
+
- Strip temperature prefix from component descriptions
|
|
28
|
+
- Improve hole detection and polygon pad handling in footprint converter
|
|
29
|
+
|
|
30
|
+
CLI:
|
|
31
|
+
- Fix async handling in renderApp exit
|
|
32
|
+
- Simplify loading indicators
|
|
33
|
+
|
|
34
|
+
MCP:
|
|
35
|
+
- Fix typecheck errors in batch and library tools
|
|
36
|
+
- Correct validationData property paths
|
|
37
|
+
- Fix InstalledComponent property access
|
|
38
|
+
|
|
39
|
+
Validator:
|
|
40
|
+
- Align SVG reference extraction with KiCad converter
|
|
41
|
+
|
|
42
|
+
### Patch Changes
|
|
43
|
+
|
|
44
|
+
- Updated dependencies []:
|
|
45
|
+
- @jlcpcb/core@0.3.0
|
|
46
|
+
|
|
47
|
+
## 0.2.0
|
|
48
|
+
|
|
49
|
+
### Minor Changes
|
|
50
|
+
|
|
51
|
+
- cd6df88: Packages to select: @jlcpcb/cli (minor), @jlcpcb/core (minor)
|
|
52
|
+
|
|
53
|
+
Summary to paste:
|
|
54
|
+
|
|
55
|
+
Add `jlc easyeda install [uuid]` command for EasyEDA community components
|
|
56
|
+
|
|
57
|
+
CLI changes:
|
|
58
|
+
- New `jlc easyeda install [uuid]` subcommand with -p/--project, --with-3d, -f/--force options
|
|
59
|
+
- Dedicated EasyEDAInfoScreen and EasyEDADetailView showing community-specific fields
|
|
60
|
+
- Installation status detection: shows "R Regenerate" if installed, "Enter Install" if not
|
|
61
|
+
- "✓ Installed" indicator next to component title when already in library
|
|
62
|
+
- `jlc install` now rejects non-LCSC IDs with helpful redirect to `jlc easyeda install`
|
|
63
|
+
|
|
64
|
+
Core changes:
|
|
65
|
+
- Add `isEasyEDAInstalled()` method to check if component exists in EasyEDA library
|
|
66
|
+
- Register EasyEDA library in global KiCad tables with portable ${KICAD9_3RD_PARTY} paths
|
|
67
|
+
- Support global installation for community components (no projectPath required)
|
|
68
|
+
- Separate library names (EasyEDA vs EasyEDA-local) to avoid global/local collision
|
|
69
|
+
|
|
70
|
+
### Patch Changes
|
|
71
|
+
|
|
72
|
+
- Updated dependencies [cd6df88]
|
|
73
|
+
- @jlcpcb/core@0.2.0
|
|
74
|
+
|
|
3
75
|
## 0.1.1
|
|
4
76
|
|
|
5
77
|
### Patch Changes
|
package/README.md
CHANGED
|
@@ -76,27 +76,17 @@ bun run build
|
|
|
76
76
|
|
|
77
77
|
| Tool | Description | Key Parameters |
|
|
78
78
|
|------|-------------|----------------|
|
|
79
|
-
| `component_search` | Search JLCPCB parts
|
|
80
|
-
| `component_get` | Get detailed component info by LCSC ID | `lcsc_id` (e.g., "C2040") |
|
|
79
|
+
| `component_search` | Search JLCPCB parts or EasyEDA community | `query`, `source`, `in_stock`, `basic_only`, `limit` |
|
|
81
80
|
|
|
82
81
|
### Library Management
|
|
83
82
|
|
|
84
83
|
| Tool | Description | Key Parameters |
|
|
85
84
|
|------|-------------|----------------|
|
|
86
|
-
| `
|
|
87
|
-
| `
|
|
88
|
-
| `
|
|
89
|
-
| `
|
|
90
|
-
| `
|
|
91
|
-
|
|
92
|
-
### EasyEDA Community Library
|
|
93
|
-
|
|
94
|
-
| Tool | Description | Key Parameters |
|
|
95
|
-
|------|-------------|----------------|
|
|
96
|
-
| `easyeda_search` | Search community-contributed components | `query`, `source`, `open_preview` |
|
|
97
|
-
| `easyeda_get` | Get community component details | `uuid` |
|
|
98
|
-
| `easyeda_fetch` | Fetch community component to project | `uuid`, `project_path`, `include_3d` |
|
|
99
|
-
| `easyeda_get_3d_model` | Download community 3D model | `uuid`, `format` |
|
|
85
|
+
| `library_install` | Install component to KiCad library | `id`, `project_path`?, `include_3d`?, `force`? |
|
|
86
|
+
| `library_batch_install` | Install up to 10 components at once | `ids`, `include_3d`?, `force`? |
|
|
87
|
+
| `library_get_component` | Get installed component metadata | `id` (LCSC ID) |
|
|
88
|
+
| `library_update` | Regenerate all components with latest data | `project_path`?, `dry_run`? |
|
|
89
|
+
| `library_fix` | Apply pin corrections to a component | `id`, `corrections` |
|
|
100
90
|
|
|
101
91
|
## Usage Examples
|
|
102
92
|
|
|
@@ -108,40 +98,40 @@ component_search(query="STM32F103", in_stock=true, basic_only=true)
|
|
|
108
98
|
|
|
109
99
|
Returns matching components with LCSC IDs, stock levels, and pricing.
|
|
110
100
|
|
|
111
|
-
###
|
|
101
|
+
### Install a component
|
|
112
102
|
|
|
113
103
|
```
|
|
114
|
-
|
|
104
|
+
library_install(id="C8734")
|
|
115
105
|
```
|
|
116
106
|
|
|
117
107
|
Downloads the component and returns:
|
|
118
108
|
- `symbol_ref`: Reference for schematic (e.g., `JLC-MCP-ICs:STM32F103C8T6`)
|
|
119
109
|
- `footprint_ref`: Reference for PCB (e.g., `Package_QFP:LQFP-48_7x7mm_P0.5mm`)
|
|
120
110
|
|
|
121
|
-
###
|
|
111
|
+
### Install to project-local library
|
|
122
112
|
|
|
123
113
|
```
|
|
124
|
-
|
|
114
|
+
library_install(id="C8734", project_path="/path/to/kicad/project", include_3d=true)
|
|
125
115
|
```
|
|
126
116
|
|
|
127
|
-
###
|
|
117
|
+
### Batch install components
|
|
128
118
|
|
|
129
119
|
```
|
|
130
|
-
|
|
120
|
+
library_batch_install(ids=["C2040", "C5446", "C14663"])
|
|
131
121
|
```
|
|
132
122
|
|
|
133
|
-
|
|
134
|
-
- Creates `JLC-MCP-Resistors.kicad_sym`, `JLC-MCP-Capacitors.kicad_sym`, etc.
|
|
135
|
-
- Creates `JLC-MCP.pretty/` footprint directory
|
|
136
|
-
- Creates `JLC-MCP.3dshapes/` 3D model directory
|
|
123
|
+
Install multiple components in parallel (up to 10 at once).
|
|
137
124
|
|
|
138
|
-
###
|
|
125
|
+
### Regenerate libraries
|
|
139
126
|
|
|
140
127
|
```
|
|
141
|
-
|
|
128
|
+
library_update()
|
|
142
129
|
```
|
|
143
130
|
|
|
144
|
-
|
|
131
|
+
Creates the category-based library structure if it doesn't exist:
|
|
132
|
+
- Creates `JLC-MCP-Resistors.kicad_sym`, `JLC-MCP-Capacitors.kicad_sym`, etc.
|
|
133
|
+
- Creates `JLC-MCP.pretty/` footprint directory
|
|
134
|
+
- Creates `JLC-MCP.3dshapes/` 3D model directory
|
|
145
135
|
|
|
146
136
|
## Library Organization
|
|
147
137
|
|