@veloxts/web 0.6.88 → 0.6.90

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.
Files changed (2) hide show
  1. package/CHANGELOG.md +22 -10
  2. package/package.json +20 -20
package/CHANGELOG.md CHANGED
@@ -1,5 +1,27 @@
1
1
  # @veloxts/web
2
2
 
3
+ ## 0.6.90
4
+
5
+ ### Patch Changes
6
+
7
+ - Dependencies updates – fix critical and high severity vulnerabilities
8
+ - Updated dependencies
9
+ - @veloxts/auth@0.6.90
10
+ - @veloxts/client@0.6.90
11
+ - @veloxts/core@0.6.90
12
+ - @veloxts/router@0.6.90
13
+
14
+ ## 0.6.89
15
+
16
+ ### Patch Changes
17
+
18
+ - expand preset system with server config, auth presets, and security validation
19
+ - Updated dependencies
20
+ - @veloxts/auth@0.6.89
21
+ - @veloxts/client@0.6.89
22
+ - @veloxts/core@0.6.89
23
+ - @veloxts/router@0.6.89
24
+
3
25
  ## 0.6.88
4
26
 
5
27
  ### Patch Changes
@@ -205,7 +227,6 @@
205
227
  - ### feat(auth): Unified Adapter-Only Architecture
206
228
 
207
229
  **New Features:**
208
-
209
230
  - Add `JwtAdapter` implementing the `AuthAdapter` interface for unified JWT authentication
210
231
  - Add `jwtAuth()` convenience function for direct adapter usage with optional built-in routes (`/api/auth/refresh`, `/api/auth/logout`)
211
232
  - Add `AuthContext` discriminated union (`NativeAuthContext | AdapterAuthContext`) for type-safe auth mode handling
@@ -213,24 +234,20 @@
213
234
  - Add shared decoration utilities (`decorateAuth`, `setRequestAuth`, `checkDoubleRegistration`)
214
235
 
215
236
  **Architecture Changes:**
216
-
217
237
  - `authPlugin` now uses `JwtAdapter` internally - all authentication flows through the adapter pattern
218
238
  - Single code path for authentication (no more dual native/adapter modes)
219
239
  - `authContext.authMode` is now always `'adapter'` with `providerId='jwt'` when using `authPlugin`
220
240
 
221
241
  **Breaking Changes:**
222
-
223
242
  - Remove deprecated `LegacySessionConfig` interface (use `sessionMiddleware` instead)
224
243
  - Remove deprecated `session` field from `AuthConfig`
225
244
  - `User` interface no longer has index signature (extend via declaration merging)
226
245
 
227
246
  **Type Safety Improvements:**
228
-
229
247
  - `AuthContext` discriminated union enables exhaustive type narrowing based on `authMode`
230
248
  - Export `NativeAuthContext` and `AdapterAuthContext` types for explicit typing
231
249
 
232
250
  **Migration:**
233
-
234
251
  - Existing `authPlugin` usage remains backward-compatible
235
252
  - If checking `authContext.token`, use `authContext.session` instead (token stored in session for adapter mode)
236
253
 
@@ -251,12 +268,10 @@
251
268
  Addresses 9 user feedback items to improve DX, reduce boilerplate, and eliminate template duplications.
252
269
 
253
270
  ### Phase 1: Validation Helpers (`@veloxts/validation`)
254
-
255
271
  - Add `prismaDecimal()`, `prismaDecimalNullable()`, `prismaDecimalOptional()` for Prisma Decimal → number conversion
256
272
  - Add `dateToIso`, `dateToIsoNullable`, `dateToIsoOptional` aliases for consistency
257
273
 
258
274
  ### Phase 2: Template Deduplication (`@veloxts/auth`)
259
-
260
275
  - Export `createEnhancedTokenStore()` with token revocation and refresh token reuse detection
261
276
  - Export `parseUserRoles()` and `DEFAULT_ALLOWED_ROLES`
262
277
  - Fix memory leak: track pending timeouts for proper cleanup on `destroy()`
@@ -264,20 +279,17 @@
264
279
  - Fix jwtManager singleton pattern in templates
265
280
 
266
281
  ### Phase 3: Router Helpers (`@veloxts/router`)
267
-
268
282
  - Add `createRouter()` returning `{ collections, router }` for DRY setup
269
283
  - Add `toRouter()` for router-only use cases
270
284
  - Update all router templates to use `createRouter()`
271
285
 
272
286
  ### Phase 4: Guard Type Narrowing - Experimental (`@veloxts/auth`, `@veloxts/router`)
273
-
274
287
  - Add `NarrowingGuard` interface with phantom `_narrows` type
275
288
  - Add `authenticatedNarrow` and `hasRoleNarrow()` guards
276
289
  - Add `guardNarrow()` method to `ProcedureBuilder` for context narrowing
277
290
  - Enables `ctx.user` to be non-null after guard passes
278
291
 
279
292
  ### Phase 5: Documentation (`@veloxts/router`)
280
-
281
293
  - Document `.rest()` override patterns
282
294
  - Document `createRouter()` helper usage
283
295
  - Document `guardNarrow()` experimental API
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@veloxts/web",
3
- "version": "0.6.88",
3
+ "version": "0.6.90",
4
4
  "description": "React Server Components integration for VeloxTS framework using Vinxi",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -65,17 +65,17 @@
65
65
  "dependencies": {
66
66
  "@vinxi/server-functions": "0.5.1",
67
67
  "radix3": "1.1.2",
68
- "vinxi": "0.5.10",
69
- "vite-tsconfig-paths": "6.0.3",
68
+ "vinxi": "0.5.11",
69
+ "vite-tsconfig-paths": "6.0.5",
70
70
  "zod": "3.25.76"
71
71
  },
72
72
  "peerDependencies": {
73
73
  "react": ">=19.2.0",
74
74
  "react-dom": ">=19.2.0",
75
- "@veloxts/auth": "0.6.88",
76
- "@veloxts/core": "0.6.88",
77
- "@veloxts/router": "0.6.88",
78
- "@veloxts/client": "0.6.88"
75
+ "@veloxts/auth": "0.6.90",
76
+ "@veloxts/core": "0.6.90",
77
+ "@veloxts/client": "0.6.90",
78
+ "@veloxts/router": "0.6.90"
79
79
  },
80
80
  "peerDependenciesMeta": {
81
81
  "@veloxts/auth": {
@@ -87,21 +87,21 @@
87
87
  },
88
88
  "devDependencies": {
89
89
  "@types/jsdom": "27.0.0",
90
- "@types/node": "25.0.3",
91
- "@types/react": "19.2.7",
90
+ "@types/node": "25.1.0",
91
+ "@types/react": "19.2.10",
92
92
  "@types/react-dom": "19.2.3",
93
- "@vitest/coverage-v8": "4.0.16",
94
- "fastify": "5.6.2",
95
- "jsdom": "27.3.0",
96
- "react": "19.2.3",
97
- "react-dom": "19.2.3",
98
- "react-server-dom-webpack": "19.2.3",
93
+ "@vitest/coverage-v8": "4.0.18",
94
+ "fastify": "5.7.2",
95
+ "jsdom": "27.4.0",
96
+ "react": "19.2.4",
97
+ "react-dom": "19.2.4",
98
+ "react-server-dom-webpack": "19.2.4",
99
99
  "typescript": "5.9.3",
100
- "vitest": "4.0.16",
101
- "@veloxts/core": "0.6.88",
102
- "@veloxts/client": "0.6.88",
103
- "@veloxts/router": "0.6.88",
104
- "@veloxts/auth": "0.6.88"
100
+ "vitest": "4.0.18",
101
+ "@veloxts/auth": "0.6.90",
102
+ "@veloxts/core": "0.6.90",
103
+ "@veloxts/router": "0.6.90",
104
+ "@veloxts/client": "0.6.90"
105
105
  },
106
106
  "keywords": [
107
107
  "velox",