mirror of
https://github.com/Memo-2023/mana-monorepo.git
synced 2026-05-15 01:01:09 +02:00
Moves the canonical SpaceType + SPACE_MODULE_ALLOWLIST to @mana/shared-types (framework-free) so the Bun services can consume them without pulling in Svelte. shared-branding keeps only the UI-facing labels and descriptions and re-exports the canonical types for frontend convenience. Wires two Better Auth organization hooks in mana-auth: - beforeCreateOrganization asserts metadata.type is a valid SpaceType, rejecting the create with a BAD_REQUEST otherwise. - beforeDeleteOrganization rejects deletion of the personal space. Covered by bun tests (11 assertions) for the helper module. No migration and no schema change — type lives in the existing organization.metadata jsonb column. Plan: docs/plans/spaces-foundation.md Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
32 lines
740 B
JSON
32 lines
740 B
JSON
{
|
|
"name": "@mana/auth",
|
|
"version": "0.1.0",
|
|
"private": true,
|
|
"type": "module",
|
|
"scripts": {
|
|
"dev": "bun run --watch src/index.ts",
|
|
"start": "bun run src/index.ts",
|
|
"test": "bun test",
|
|
"db:push": "drizzle-kit push",
|
|
"db:generate": "drizzle-kit generate",
|
|
"db:studio": "drizzle-kit studio"
|
|
},
|
|
"dependencies": {
|
|
"@mana/shared-ai": "workspace:*",
|
|
"@mana/shared-hono": "workspace:*",
|
|
"@mana/shared-types": "workspace:*",
|
|
"hono": "^4.7.0",
|
|
"better-auth": "^1.4.3",
|
|
"drizzle-orm": "^0.38.3",
|
|
"postgres": "^3.4.5",
|
|
"jose": "^6.1.2",
|
|
"bcryptjs": "^3.0.2",
|
|
"nanoid": "^5.0.0",
|
|
"zod": "^3.24.0"
|
|
},
|
|
"devDependencies": {
|
|
"@types/bcryptjs": "^2.4.6",
|
|
"drizzle-kit": "^0.30.4",
|
|
"typescript": "^5.9.3"
|
|
}
|
|
}
|