feat(auth): add centralized @manacore/better-auth-types package

Create new shared package for Better Auth type definitions:
- UserRole, JWTPayload, CurrentUserData types
- Type guards: isValidUserRole, isValidOrganizationRole
- Utility functions: jwtPayloadToCurrentUser
- userAdditionalFields for client type inference

Migrate shared packages to use centralized types:
- @manacore/shared-auth re-exports from new package
- @manacore/shared-nestjs-auth uses new package as dependency
This commit is contained in:
Wuesteon 2025-12-16 02:43:55 +01:00
parent eeab9b7fea
commit 26ca921158
9 changed files with 513 additions and 32 deletions

View file

@ -16,6 +16,7 @@
},
"dependencies": {
"@manacore/shared-types": "workspace:*",
"@manacore/better-auth-types": "workspace:*",
"base64-js": "^1.5.1"
},
"devDependencies": {