@leanspec/ui 0.2.19-dev.21382316476 → 0.2.19-dev.21387450109
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 +19 -2
- package/package.json +12 -5
package/README.md
CHANGED
|
@@ -99,14 +99,31 @@ pnpm preview
|
|
|
99
99
|
|
|
100
100
|
## Configuration
|
|
101
101
|
|
|
102
|
-
|
|
102
|
+
By default the UI uses same-origin API calls (relative `/api/...`).
|
|
103
|
+
|
|
104
|
+
### Dev (recommended, “single origin” in the browser)
|
|
105
|
+
|
|
106
|
+
Run the Rust HTTP server (API) on a port (default `3000`), run Vite on `5173`, and let Vite proxy `/api`.
|
|
107
|
+
|
|
108
|
+
If you need to change where the dev proxy points, use a server-only env var:
|
|
109
|
+
|
|
110
|
+
```bash
|
|
111
|
+
# .env.local (used by Vite dev server only)
|
|
112
|
+
LEANSPEC_API_URL=http://localhost:3000
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
With this setup the browser still talks to a single origin (the Vite origin) because all API calls are made to `/api`.
|
|
116
|
+
|
|
117
|
+
### Deploy UI separately (cross-origin)
|
|
118
|
+
|
|
119
|
+
If you are serving the UI from a different origin than the Rust server, you can set an explicit API base URL:
|
|
103
120
|
|
|
104
121
|
```bash
|
|
105
122
|
# .env.local
|
|
106
123
|
VITE_API_URL=http://localhost:3000
|
|
107
124
|
```
|
|
108
125
|
|
|
109
|
-
|
|
126
|
+
If you want the Rust HTTP server to serve both UI + API on a single port, leave `VITE_API_URL` unset.
|
|
110
127
|
|
|
111
128
|
## Build Output
|
|
112
129
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@leanspec/ui",
|
|
3
|
-
"version": "0.2.19-dev.
|
|
3
|
+
"version": "0.2.19-dev.21387450109",
|
|
4
4
|
"description": "LeanSpec web UI launcher for visual spec management (Vite SPA)",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -24,9 +24,8 @@
|
|
|
24
24
|
"dependencies": {
|
|
25
25
|
"@ai-sdk/react": "^3.0.41",
|
|
26
26
|
"@dagrejs/dagre": "^1.1.8",
|
|
27
|
-
"@leanspec/ai-worker": "^0.2.19-dev.
|
|
28
|
-
"@leanspec/
|
|
29
|
-
"@leanspec/ui-components": "^0.2.19-dev.21382316476",
|
|
27
|
+
"@leanspec/ai-worker": "^0.2.19-dev.21387450109",
|
|
28
|
+
"@leanspec/ui-components": "^0.2.19-dev.21387450109",
|
|
30
29
|
"@radix-ui/react-accordion": "^1.2.12",
|
|
31
30
|
"@radix-ui/react-avatar": "^1.1.11",
|
|
32
31
|
"@radix-ui/react-collapsible": "^1.1.12",
|
|
@@ -88,7 +87,15 @@
|
|
|
88
87
|
"use-stick-to-bottom": "^1.1.2"
|
|
89
88
|
},
|
|
90
89
|
"optionalDependencies": {
|
|
91
|
-
"@leanspec/chat-server": "^0.2.19-dev.
|
|
90
|
+
"@leanspec/chat-server": "^0.2.19-dev.21387450109"
|
|
91
|
+
},
|
|
92
|
+
"peerDependencies": {
|
|
93
|
+
"@leanspec/http-server": "^0.2.19-dev.21387450109"
|
|
94
|
+
},
|
|
95
|
+
"peerDependenciesMeta": {
|
|
96
|
+
"@leanspec/http-server": {
|
|
97
|
+
"optional": true
|
|
98
|
+
}
|
|
92
99
|
},
|
|
93
100
|
"devDependencies": {
|
|
94
101
|
"@eslint/js": "^9.39.2",
|