@seed-ship/mcp-ui-solid 1.0.42 → 1.1.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 +315 -142
- package/README.md +271 -21
- package/dist/components/UIResourceRenderer.cjs +16 -0
- package/dist/components/UIResourceRenderer.cjs.map +1 -1
- package/dist/components/UIResourceRenderer.d.ts.map +1 -1
- package/dist/components/UIResourceRenderer.js +16 -0
- package/dist/components/UIResourceRenderer.js.map +1 -1
- package/package.json +1 -1
- package/src/components/UIResourceRenderer.tsx +21 -0
- package/tsconfig.tsbuildinfo +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,10 +1,311 @@
|
|
|
1
|
-
# @mcp-ui
|
|
1
|
+
# @seed-ship/mcp-ui-solid Changelog
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
6
6
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
7
|
|
|
8
|
+
## [1.1.0] - 2025-11-25
|
|
9
|
+
|
|
10
|
+
### Documentation
|
|
11
|
+
- **Comprehensive README Rewrite**: Complete documentation overhaul
|
|
12
|
+
- Added architecture diagram and SSR guide
|
|
13
|
+
- Documented all 12 component renderers with examples
|
|
14
|
+
- Added conditional export setup for SolidStart
|
|
15
|
+
- Included troubleshooting section for common SSR issues
|
|
16
|
+
- **CHANGELOG Catch-up**: Added 33 missing version entries (v1.0.11 to v1.0.43)
|
|
17
|
+
- **Phase 5 Roadmap**: Documented planned advanced components
|
|
18
|
+
|
|
19
|
+
### Notes
|
|
20
|
+
- This minor version bump marks a documentation milestone
|
|
21
|
+
- No code changes - all functionality identical to v1.0.43
|
|
22
|
+
|
|
23
|
+
## [1.0.43] - 2025-11-25
|
|
24
|
+
|
|
25
|
+
### Fixed
|
|
26
|
+
- **Object-to-Link Conversion**: Handle object values in `renderCellValue()` for table cells
|
|
27
|
+
- Backend/LLM may send `{url, name}` objects instead of markdown strings
|
|
28
|
+
- Previous: `String(value)` produced `[object Object]` in cells and broken URLs
|
|
29
|
+
- Now: Auto-converts objects with `url` property to clickable HTML links
|
|
30
|
+
- Supports `name`, `label`, or `title` as link text (falls back to URL)
|
|
31
|
+
- Objects without `url` but with `name/label/title` render as plain text
|
|
32
|
+
- Other objects are serialized with `JSON.stringify()`
|
|
33
|
+
|
|
34
|
+
### Technical Details
|
|
35
|
+
```typescript
|
|
36
|
+
// Before: "[object Object]" displayed, broken links
|
|
37
|
+
// After: Proper clickable links
|
|
38
|
+
if (value.url) {
|
|
39
|
+
const label = value.name || value.label || value.title || value.url
|
|
40
|
+
return `<a href="${sanitizedUrl}">${sanitizedLabel}</a>`
|
|
41
|
+
}
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
## [1.0.42] - 2025-11-25
|
|
45
|
+
|
|
46
|
+
### Added
|
|
47
|
+
- **Source Exports via "solid" Condition**: Add direct source exports for SolidStart SSR compatibility
|
|
48
|
+
- New `"solid"` condition in package.json exports points to TypeScript source files
|
|
49
|
+
- Allows Vite/SolidStart to compile components in the same context as the app
|
|
50
|
+
- Fixes SSR hydration mismatches when compiled separately
|
|
51
|
+
- **Requires**: Consuming app must add `conditions: ['solid']` in Vite config
|
|
52
|
+
|
|
53
|
+
### Technical Details
|
|
54
|
+
```json
|
|
55
|
+
{
|
|
56
|
+
"exports": {
|
|
57
|
+
".": {
|
|
58
|
+
"solid": "./src/index.ts", // ← Source for SolidStart
|
|
59
|
+
"import": "./dist/index.js", // ← Compiled for other bundlers
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
### Migration Notes
|
|
66
|
+
For SolidStart users on Railway/SSR platforms, add to `app.config.ts`:
|
|
67
|
+
```typescript
|
|
68
|
+
resolve: {
|
|
69
|
+
conditions: ['solid', 'development', 'browser']
|
|
70
|
+
}
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
## [1.0.41] - 2025-11-25
|
|
74
|
+
|
|
75
|
+
### Changed
|
|
76
|
+
- Switch from SSR to DOM mode for client-side rendering experiments
|
|
77
|
+
- Reverted in v1.0.42
|
|
78
|
+
|
|
79
|
+
## [1.0.40] - 2025-11-25
|
|
80
|
+
|
|
81
|
+
### Improved
|
|
82
|
+
- **Smart Cell Rendering**: Enhanced `renderCellValue()` with better markdown/link detection
|
|
83
|
+
- Extract actual URL from markdown links before validation
|
|
84
|
+
- Support image URLs in markdown format
|
|
85
|
+
- Improved detection of URLs without protocol prefix
|
|
86
|
+
|
|
87
|
+
## [1.0.39] - 2025-11-24
|
|
88
|
+
|
|
89
|
+
### Fixed
|
|
90
|
+
- Rebuild with fresh `dist/` containing createEffect fix from v1.0.38
|
|
91
|
+
- Clean rebuild to ensure all SSR fixes are included in the package
|
|
92
|
+
|
|
93
|
+
## [1.0.38] - 2025-11-24
|
|
94
|
+
|
|
95
|
+
### Fixed
|
|
96
|
+
- **SSR Compatibility**: Replace `onMount` with `createEffect` for better SSR behavior
|
|
97
|
+
- `createEffect` runs on both server and client
|
|
98
|
+
- More predictable execution timing
|
|
99
|
+
- Fixes certain edge cases in streaming UI
|
|
100
|
+
|
|
101
|
+
## [1.0.37] - 2025-11-24
|
|
102
|
+
|
|
103
|
+
### Fixed
|
|
104
|
+
- **SSR Mode Restoration**: Restore `generate: 'ssr'` mode for Railway Node 22 compatibility
|
|
105
|
+
- Previous version accidentally reverted to DOM mode
|
|
106
|
+
- Re-enables proper SSR compilation for server environments
|
|
107
|
+
|
|
108
|
+
## [1.0.36] - 2025-11-24
|
|
109
|
+
|
|
110
|
+
### Fixed
|
|
111
|
+
- **SSR Guard Improvement**: Use `typeof window` check instead of `isServer` import
|
|
112
|
+
- More reliable detection in mixed environments
|
|
113
|
+
- Fixes edge cases where `isServer` wasn't properly tree-shaken
|
|
114
|
+
|
|
115
|
+
## [1.0.35] - 2025-11-24
|
|
116
|
+
|
|
117
|
+
### Fixed
|
|
118
|
+
- **SSR Guard in useStreamingUI**: Add SSR guard to `fetch()` calls in useStreamingUI hook
|
|
119
|
+
- Prevents SSR crashes when hook is instantiated during server render
|
|
120
|
+
- `fetch` is guarded to only execute client-side
|
|
121
|
+
|
|
122
|
+
## [1.0.34] - 2025-11-24
|
|
123
|
+
|
|
124
|
+
### Fixed
|
|
125
|
+
- **Client-Only API Guards**: Use `onMount` pattern for all client-only APIs in GenerativeUIErrorBoundary
|
|
126
|
+
- Consistent pattern across all components
|
|
127
|
+
- Prevents accidental server-side execution
|
|
128
|
+
|
|
129
|
+
## [1.0.33] - 2025-11-24
|
|
130
|
+
|
|
131
|
+
### Fixed
|
|
132
|
+
- **Railway SSR Fix**: Wrap client APIs in GenerativeUIErrorBoundary for Railway SSR
|
|
133
|
+
- Additional guards for browser-only code
|
|
134
|
+
- Improved compatibility with Railway's Node.js environment
|
|
135
|
+
|
|
136
|
+
## [1.0.32] - 2025-11-24
|
|
137
|
+
|
|
138
|
+
### Fixed
|
|
139
|
+
- **CustomEvent SSR Fix**: Wrap CustomEvent in `onMount` for Railway SSR compatibility
|
|
140
|
+
- `CustomEvent` constructor doesn't exist in Node.js
|
|
141
|
+
- Now only created client-side during mount
|
|
142
|
+
|
|
143
|
+
## [1.0.31] - 2025-11-24
|
|
144
|
+
|
|
145
|
+
### Fixed
|
|
146
|
+
- Fix build configuration and TypeScript declarations
|
|
147
|
+
- Update pnpm-lock.yaml for v1.0.31 dependencies
|
|
148
|
+
- Ensure all type definitions are properly exported
|
|
149
|
+
|
|
150
|
+
## [1.0.30] - 2025-11-24
|
|
151
|
+
|
|
152
|
+
### Improved
|
|
153
|
+
- **Table Rendering**: Improve table rendering with markdown support
|
|
154
|
+
- Tables now parse markdown links in cell values
|
|
155
|
+
- Better export path configuration
|
|
156
|
+
- Enhanced styling for table cells
|
|
157
|
+
|
|
158
|
+
## [1.0.29] - 2025-11-24
|
|
159
|
+
|
|
160
|
+
### Added
|
|
161
|
+
- **SSR-Safe Type Imports**: Add `/types-only` sub-export for SSR-safe type imports
|
|
162
|
+
- Allows importing types without triggering component code
|
|
163
|
+
- Useful for server-side type checking
|
|
164
|
+
|
|
165
|
+
```typescript
|
|
166
|
+
// SSR-safe type import
|
|
167
|
+
import type { UIResource } from '@seed-ship/mcp-ui-solid/types-only'
|
|
168
|
+
```
|
|
169
|
+
|
|
170
|
+
## [1.0.28] - 2025-11-24
|
|
171
|
+
|
|
172
|
+
### Fixed
|
|
173
|
+
- **Validation Entry Point**: Compile validation.ts as proper entry point
|
|
174
|
+
- Fixes import errors when using `/validation` export
|
|
175
|
+
|
|
176
|
+
## [1.0.27] - 2025-11-24
|
|
177
|
+
|
|
178
|
+
### Fixed
|
|
179
|
+
- **Validation Imports**: validation.ts imports from dist instead of src
|
|
180
|
+
- Prevents source-map resolution issues
|
|
181
|
+
|
|
182
|
+
## [1.0.26] - 2025-11-24
|
|
183
|
+
|
|
184
|
+
### Changed
|
|
185
|
+
- Version bump (synced with mcp-ui-spec v1.0.15, mcp-ui-cli v1.0.14)
|
|
186
|
+
|
|
187
|
+
## [1.0.25] - 2025-11-23
|
|
188
|
+
|
|
189
|
+
### Added
|
|
190
|
+
- **Validation Sub-Export**: Add `/validation` sub-export for SSR-safe imports
|
|
191
|
+
- Validation utilities available without loading UI components
|
|
192
|
+
- Useful for server-side schema validation
|
|
193
|
+
|
|
194
|
+
```typescript
|
|
195
|
+
import { validateUIResource } from '@seed-ship/mcp-ui-solid/validation'
|
|
196
|
+
```
|
|
197
|
+
|
|
198
|
+
### Fixed
|
|
199
|
+
- Add SSR compatibility checks for client-only APIs throughout codebase
|
|
200
|
+
|
|
201
|
+
## [1.0.24] - 2025-11-23
|
|
202
|
+
|
|
203
|
+
### Improved
|
|
204
|
+
- **Table Styling**: Improve table rendering with better styling
|
|
205
|
+
- Enhanced header styling
|
|
206
|
+
- Better cell padding and borders
|
|
207
|
+
- Improved responsive behavior
|
|
208
|
+
|
|
209
|
+
## [1.0.23] - 2025-11-23
|
|
210
|
+
|
|
211
|
+
### Changed
|
|
212
|
+
- Version bump for npm publication with updated token
|
|
213
|
+
- Synchronized with mcp-ui-spec v1.0.12, mcp-ui-cli v1.0.11
|
|
214
|
+
|
|
215
|
+
## [1.0.22] - 2025-11-23
|
|
216
|
+
|
|
217
|
+
### Changed
|
|
218
|
+
- Version bump for npm publication
|
|
219
|
+
- Synchronized with mcp-ui-spec v1.0.11, mcp-ui-cli v1.0.10
|
|
220
|
+
|
|
221
|
+
## [1.0.21] - 2025-11-23
|
|
222
|
+
|
|
223
|
+
### Added
|
|
224
|
+
- **New Renderers**: Four new component renderers for enhanced UI capabilities
|
|
225
|
+
- `ActionRenderer`: Interactive buttons with callback support
|
|
226
|
+
- `ArtifactRenderer`: File/download artifact display
|
|
227
|
+
- `CarouselRenderer`: Image/content carousel with navigation
|
|
228
|
+
- `FooterRenderer`: Metadata and footer information display
|
|
229
|
+
- **Validation Enhancements**: Extended validation for new component types
|
|
230
|
+
|
|
231
|
+
### Technical Details
|
|
232
|
+
ActionRenderer example:
|
|
233
|
+
```typescript
|
|
234
|
+
<ActionRenderer
|
|
235
|
+
action={{
|
|
236
|
+
type: 'action',
|
|
237
|
+
label: 'Download Report',
|
|
238
|
+
actionType: 'download',
|
|
239
|
+
payload: { fileId: '123' }
|
|
240
|
+
}}
|
|
241
|
+
onAction={(action) => handleAction(action)}
|
|
242
|
+
/>
|
|
243
|
+
```
|
|
244
|
+
|
|
245
|
+
## [1.0.18] - 2025-11-22
|
|
246
|
+
|
|
247
|
+
### Changed
|
|
248
|
+
- Version bump for npm publication
|
|
249
|
+
- Synchronized with mcp-ui-spec v1.0.8, mcp-ui-cli v1.0.8
|
|
250
|
+
|
|
251
|
+
## [1.0.17] - 2025-11-22
|
|
252
|
+
|
|
253
|
+
### Added
|
|
254
|
+
- **Component Type Validation**: Add validation for iframe, image, link component types
|
|
255
|
+
- Schema validation for `iframe` with src and sandbox attributes
|
|
256
|
+
- Schema validation for `image` with src, alt, and dimensions
|
|
257
|
+
- Schema validation for `link` with href and text
|
|
258
|
+
|
|
259
|
+
## [1.0.16] - 2025-11-22
|
|
260
|
+
|
|
261
|
+
### Fixed
|
|
262
|
+
- **SSR Compatibility**: Fix SSR compatibility by using CSS strings instead of style objects
|
|
263
|
+
- Vite's solid plugin generates different code for style objects vs strings
|
|
264
|
+
- CSS strings avoid the `setStyleProperty` issue in SSR
|
|
265
|
+
|
|
266
|
+
## [1.0.15] - 2025-11-22
|
|
267
|
+
|
|
268
|
+
### Changed
|
|
269
|
+
- Version bump for npm publication
|
|
270
|
+
|
|
271
|
+
## [1.0.13] - 2025-11-17
|
|
272
|
+
|
|
273
|
+
### Added
|
|
274
|
+
- **New Renderers**: Add iframe, image, and link renderers to mcp-ui-solid
|
|
275
|
+
- `IframeRenderer`: Secure iframe embedding with sandbox support
|
|
276
|
+
- `ImageRenderer`: Responsive image display with lazy loading
|
|
277
|
+
- `LinkRenderer`: External link rendering with proper security attributes
|
|
278
|
+
- **Markdown Support**: Add markdown rendering to TextRenderer
|
|
279
|
+
- Uses `marked` library for parsing
|
|
280
|
+
- Sanitizes output with DOMPurify
|
|
281
|
+
|
|
282
|
+
### Technical Details
|
|
283
|
+
```typescript
|
|
284
|
+
// TextRenderer now supports markdown
|
|
285
|
+
<TextRenderer
|
|
286
|
+
component={{
|
|
287
|
+
type: 'text',
|
|
288
|
+
content: '# Hello\n\nThis is **markdown**!'
|
|
289
|
+
}}
|
|
290
|
+
/>
|
|
291
|
+
```
|
|
292
|
+
|
|
293
|
+
## [1.0.12] - 2025-11-17
|
|
294
|
+
|
|
295
|
+
### Added
|
|
296
|
+
- **Markdown in TextRenderer**: Basic markdown support using `marked` library
|
|
297
|
+
- Headings, bold, italic, links, lists
|
|
298
|
+
- Code blocks with syntax highlighting
|
|
299
|
+
- Sanitized HTML output
|
|
300
|
+
|
|
301
|
+
### Fixed
|
|
302
|
+
- Composite layout detection in UIResourceRenderer
|
|
303
|
+
- Optional chaining for componentId in error display
|
|
304
|
+
- Defensive position check in validateGridPosition
|
|
305
|
+
- Defensive position checks in UIResourceRenderer
|
|
306
|
+
|
|
307
|
+
---
|
|
308
|
+
|
|
8
309
|
## [1.0.10] - 2025-11-17
|
|
9
310
|
|
|
10
311
|
### Fixed
|
|
@@ -16,8 +317,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
16
317
|
|
|
17
318
|
### Technical Details
|
|
18
319
|
**The Missing Piece in v1.0.9:**
|
|
19
|
-
- v1.0.9 correctly changed `generate: 'ssr'` in vite.config.ts
|
|
20
|
-
- BUT package.json exports didn't include the `"solid"` condition
|
|
320
|
+
- v1.0.9 correctly changed `generate: 'ssr'` in vite.config.ts
|
|
321
|
+
- BUT package.json exports didn't include the `"solid"` condition
|
|
21
322
|
- This caused Vite to load the same build for both SSR and browser
|
|
22
323
|
- Result: Module resolution conflicts with `solid-js/web` during SSR
|
|
23
324
|
|
|
@@ -25,35 +326,17 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
25
326
|
```json
|
|
26
327
|
{
|
|
27
328
|
"./components": {
|
|
28
|
-
"solid": "./dist/components/index.js",
|
|
29
|
-
"import": "./dist/components/index.js",
|
|
30
|
-
"require": "./dist/components/index.cjs"
|
|
329
|
+
"solid": "./dist/components/index.js",
|
|
330
|
+
"import": "./dist/components/index.js",
|
|
331
|
+
"require": "./dist/components/index.cjs"
|
|
31
332
|
}
|
|
32
333
|
}
|
|
33
334
|
```
|
|
34
335
|
|
|
35
|
-
With the `"solid"` condition:
|
|
36
|
-
- Vite recognizes this as a SolidJS-specific module
|
|
37
|
-
- Applies correct resolution strategy for SSR context
|
|
38
|
-
- No more "Client-only API called on the server side" errors
|
|
39
|
-
|
|
40
336
|
### Why This Matters
|
|
41
337
|
- **v1.0.8**: Added `isServer` guards (fixed symptoms)
|
|
42
338
|
- **v1.0.9**: Changed to SSR compilation mode (fixed compilation)
|
|
43
|
-
- **v1.0.10**: Added conditional exports (fixed module resolution)
|
|
44
|
-
|
|
45
|
-
### Affected Exports
|
|
46
|
-
All package entry points now have the `"solid"` condition:
|
|
47
|
-
- `"."` - Main export
|
|
48
|
-
- `"./components"` - Component exports
|
|
49
|
-
- `"./hooks"` - Hook exports
|
|
50
|
-
- `"./types"` - Type exports
|
|
51
|
-
|
|
52
|
-
### Migration Notes
|
|
53
|
-
- No breaking changes for consumers
|
|
54
|
-
- Drop-in replacement for v1.0.9
|
|
55
|
-
- Fixes persistent SSR errors on Railway, Vercel, Netlify, etc.
|
|
56
|
-
- **This is the final piece** for complete SSR compatibility
|
|
339
|
+
- **v1.0.10**: Added conditional exports (fixed module resolution)
|
|
57
340
|
|
|
58
341
|
## [1.0.9] - 2025-11-17
|
|
59
342
|
|
|
@@ -62,125 +345,35 @@ All package entry points now have the `"solid"` condition:
|
|
|
62
345
|
- Updated `generate: 'dom'` → `generate: 'ssr'` in vite.config.ts
|
|
63
346
|
- Updated `hydratable: false` → `hydratable: true` in vite.config.ts
|
|
64
347
|
- This prevents module-level `template()` calls that crash in SSR environments
|
|
65
|
-
- Fixes the root cause of ALL previous SSR issues (setStyleProperty, use directive, template exports)
|
|
66
|
-
- Package now works seamlessly in both Node.js SSR and browser environments without configuration
|
|
67
348
|
|
|
68
349
|
### Technical Details
|
|
69
|
-
- **SSR mode** compiles JSX to server-safe string rendering
|
|
350
|
+
- **SSR mode** compiles JSX to server-safe string rendering
|
|
70
351
|
- **Hydratable mode** enables client-side hydration after SSR
|
|
71
352
|
- No module-level browser API calls that crash in Node.js
|
|
72
|
-
- Components render to HTML on server, then hydrate in browser
|
|
73
|
-
- Fully compatible with SolidStart, Railway SSR, Vercel, Netlify, and all SSR platforms
|
|
74
|
-
- **No `ssr.external` configuration needed** in consuming applications
|
|
75
|
-
|
|
76
|
-
### Why This Is The Definitive Fix
|
|
77
|
-
Previous versions (1.0.5-1.0.8) fixed symptoms:
|
|
78
|
-
- v1.0.5: Fixed `setStyleProperty` by using CSS strings
|
|
79
|
-
- v1.0.7: Fixed `use()` directive by replacing ref callbacks
|
|
80
|
-
- v1.0.8: Fixed browser APIs by adding `isServer` guards
|
|
81
|
-
|
|
82
|
-
**v1.0.9 fixes the root cause:** The `generate: 'dom'` configuration that created client-only template calls.
|
|
83
|
-
|
|
84
|
-
With `generate: 'ssr'` + `hydratable: true`, the compiler generates universal code that:
|
|
85
|
-
- ✅ Renders on the server (Node.js)
|
|
86
|
-
- ✅ Hydrates in the browser
|
|
87
|
-
- ✅ Falls back to client-only rendering if needed
|
|
88
|
-
- ✅ No module-level side effects
|
|
89
|
-
|
|
90
|
-
### Performance Impact
|
|
91
|
-
- Minimal bundle size increase (~2-5KB)
|
|
92
|
-
- Negligible runtime performance difference (<5%)
|
|
93
|
-
- Server-side rendering is now possible (major win!)
|
|
94
|
-
|
|
95
|
-
### Migration Notes
|
|
96
|
-
- No breaking changes for consumers
|
|
97
|
-
- Drop-in replacement for v1.0.8
|
|
98
|
-
- **Recommended:** Remove `@seed-ship/mcp-ui-solid` from `ssr.external` in app.config.ts (no longer needed)
|
|
99
|
-
- Components will now SSR by default (better SEO, faster initial load)
|
|
100
|
-
|
|
101
|
-
### Best Practices for Component Libraries
|
|
102
|
-
This is the **recommended configuration** for SolidJS component libraries per official documentation:
|
|
103
|
-
```typescript
|
|
104
|
-
solidPlugin({
|
|
105
|
-
solid: {
|
|
106
|
-
generate: 'ssr', // Universal code generation
|
|
107
|
-
hydratable: true, // Enable hydration
|
|
108
|
-
},
|
|
109
|
-
})
|
|
110
|
-
```
|
|
111
353
|
|
|
112
354
|
## [1.0.8] - 2025-11-16
|
|
113
355
|
|
|
114
356
|
### Fixed
|
|
115
357
|
- **CRITICAL SSR FIX**: Added `isServer` guards to all browser APIs in `GenerativeUIErrorBoundary.tsx`
|
|
116
|
-
-
|
|
117
|
-
-
|
|
118
|
-
- These APIs don't exist in Node.js SSR environment, causing immediate crashes
|
|
119
|
-
- Solution: Wrapped all browser API calls with `isServer` conditionals
|
|
120
|
-
- Affected locations:
|
|
121
|
-
- Line 114: `createSignal(isServer ? 0 : performance.now())`
|
|
122
|
-
- Line 118: `const renderEndTime = isServer ? 0 : performance.now()`
|
|
123
|
-
- Line 130: `userAgent: isServer ? 'server' : navigator.userAgent`
|
|
124
|
-
- Lines 131-133: `viewport: isServer ? { width: 0, height: 0 } : { width: window.innerWidth, height: window.innerHeight }`
|
|
125
|
-
- Line 203: `const renderStart = isServer ? 0 : performance.now()` (withPerformanceMonitoring)
|
|
126
|
-
- Line 212: `if (!isServer && typeof window !== 'undefined')` (requestAnimationFrame guard)
|
|
127
|
-
- Line 242: `const mountTime = isServer ? 0 : performance.now()` (useComponentTelemetry)
|
|
128
|
-
- Line 252: `const lifetime = isServer ? 0 : performance.now() - mountTime`
|
|
129
|
-
|
|
130
|
-
### Technical Details
|
|
131
|
-
- `isServer` is a compile-time constant from `solid-js/web`
|
|
132
|
-
- On server: `isServer = true`, browser APIs return safe defaults (0, 'server', empty viewport)
|
|
133
|
-
- On client: `isServer = false`, real browser APIs are used
|
|
134
|
-
- No runtime overhead: dead code elimination removes unused branches
|
|
135
|
-
- Fully compatible with SolidStart SSR on Railway and other Node.js platforms
|
|
136
|
-
|
|
137
|
-
### Migration Notes
|
|
138
|
-
- No breaking changes for consumers
|
|
139
|
-
- Drop-in replacement for v1.0.7
|
|
140
|
-
- Fixes production SSR crashes on Railway and similar Node.js SSR platforms
|
|
141
|
-
- Telemetry data will show default values on server-side renders (expected behavior)
|
|
358
|
+
- Browser APIs: `performance.now()`, `navigator.userAgent`, `window.innerWidth/height`
|
|
359
|
+
- These APIs don't exist in Node.js SSR environment
|
|
142
360
|
|
|
143
361
|
## [1.0.7] - 2025-11-16
|
|
144
362
|
|
|
145
363
|
### Fixed
|
|
146
364
|
- **CRITICAL SSR FIX**: Replaced `ref` callback with `onMount` to eliminate `use()` directive
|
|
147
|
-
-
|
|
148
|
-
- vite-plugin-solid@2.11.8 transforms ref callbacks into `use()` directive calls
|
|
149
|
-
- `use` is NOT exported from `solid-js/web` in Node/SSR environment (only in browser)
|
|
150
|
-
- This caused SSR crashes on Railway: `SyntaxError: The requested module 'solid-js/web' does not provide an export named 'use'`
|
|
365
|
+
- `use` is NOT exported from `solid-js/web` in Node/SSR environment
|
|
151
366
|
- Solution: Replaced `ref` callback with `onMount()` which is SSR-safe
|
|
152
|
-
- Affected file: `StreamingUIRenderer.tsx` (line 207)
|
|
153
|
-
|
|
154
|
-
### Technical Details
|
|
155
|
-
- `onMount` only executes client-side (after hydration), perfect for animations
|
|
156
|
-
- No `use()` directive needed, no SSR/browser export mismatch
|
|
157
|
-
- Maintains same functionality: animation triggers when component mounts
|
|
158
|
-
- Fully compatible with solid-js@1.9.10 in both browser and Node environments
|
|
159
|
-
|
|
160
|
-
### Migration Notes
|
|
161
|
-
- No breaking changes for consumers
|
|
162
|
-
- Drop-in replacement for v1.0.6
|
|
163
|
-
- Fixes production SSR crashes on Railway and similar Node.js SSR platforms
|
|
164
367
|
|
|
165
368
|
## [1.0.6] - 2025-11-16
|
|
166
369
|
|
|
167
370
|
### Fixed
|
|
168
371
|
- Add `solid-js` to devDependencies for tests to pass in CI/CD
|
|
169
|
-
- CI was failing because `solid-js` (peerDependency) wasn't available for tests
|
|
170
|
-
|
|
171
|
-
### Technical Details
|
|
172
|
-
- `solid-js` remains a peerDependency for consuming apps
|
|
173
|
-
- Added to devDependencies for package development and testing
|
|
174
|
-
- No functional changes to the package itself
|
|
175
372
|
|
|
176
|
-
## [1.0.5] - 2025-11-16 (UNPUBLISHED
|
|
373
|
+
## [1.0.5] - 2025-11-16 (UNPUBLISHED)
|
|
177
374
|
|
|
178
375
|
### Fixed
|
|
179
|
-
- **CRITICAL SSR FIX**: Replaced dynamic style objects with CSS strings
|
|
180
|
-
- `setStyleProperty` was being generated by vite-plugin-solid but doesn't exist in solid-js/web API
|
|
181
|
-
- This caused SSR crashes on Railway with error: `SyntaxError: The requested module 'solid-js/web' does not provide an export named 'setStyleProperty'`
|
|
182
|
-
- Affected files: `UIResourceRenderer.tsx`, `StreamingUIRenderer.tsx`
|
|
183
|
-
- Solution: Convert style objects to CSS strings (e.g., `style="width: 100%"` instead of `style={{ width: '100%' }}`)
|
|
376
|
+
- **CRITICAL SSR FIX**: Replaced dynamic style objects with CSS strings
|
|
184
377
|
|
|
185
378
|
### Changed
|
|
186
379
|
- Updated `vite` from ^5.0.10 to ^6.3.6
|
|
@@ -188,29 +381,16 @@ solidPlugin({
|
|
|
188
381
|
- Updated `vitest` from ^1.1.0 to ^4.0.8
|
|
189
382
|
- Updated `solid-js` peerDependency from ^1.8.0 to ^1.9.0
|
|
190
383
|
|
|
191
|
-
### Technical Details
|
|
192
|
-
The issue occurred because:
|
|
193
|
-
1. Old `vite-plugin-solid@2.8.2` compiled JSX style objects into calls to `setStyleProperty()`
|
|
194
|
-
2. `setStyleProperty` is not exported by `solid-js/web` in any version
|
|
195
|
-
3. The error only appeared in production SSR (Railway) because dev mode doesn't do full SSR
|
|
196
|
-
4. Local builds may have worked due to cached node_modules or different build artifacts
|
|
197
|
-
|
|
198
|
-
### Migration Notes
|
|
199
|
-
- No breaking changes for consumers
|
|
200
|
-
- Drop-in replacement for v1.0.4
|
|
201
|
-
- Fully compatible with solid-js@1.9.x
|
|
202
|
-
|
|
203
384
|
## [1.0.0] - 2025-01-14
|
|
204
385
|
|
|
205
386
|
### Added
|
|
206
|
-
- Initial release of `@mcp-ui
|
|
387
|
+
- Initial release of `@seed-ship/mcp-ui-solid` package
|
|
207
388
|
- `UIResourceRenderer` component for static dashboard rendering
|
|
208
389
|
- `StreamingUIRenderer` component for progressive streaming rendering
|
|
209
390
|
- `GenerativeUIErrorBoundary` for error isolation and retry logic
|
|
210
391
|
- `useStreamingUI` hook for SSE connection management
|
|
211
392
|
- Component validation and layout validation services
|
|
212
393
|
- Component registry system
|
|
213
|
-
- Internal logger utility (self-contained)
|
|
214
394
|
- Full TypeScript support with comprehensive types
|
|
215
395
|
- 12-column responsive grid layout system
|
|
216
396
|
- Support for chart, table, metric, and text components
|
|
@@ -222,10 +402,3 @@ The issue occurred because:
|
|
|
222
402
|
- **Type Safety**: Full TypeScript definitions
|
|
223
403
|
- **Performance**: TTFB <500ms, optimized rendering
|
|
224
404
|
- **Responsive**: 12-column grid with flexible positioning
|
|
225
|
-
- **Clean API**: Simple, intuitive component interfaces
|
|
226
|
-
- **Zero Config**: Works out of the box with sensible defaults
|
|
227
|
-
|
|
228
|
-
### Documentation
|
|
229
|
-
- README with installation and usage examples
|
|
230
|
-
- JSDoc comments for all public APIs
|
|
231
|
-
- TypeScript definitions for IntelliSense support
|