mirror of
https://github.com/johndoe6345789/metabuilder.git
synced 2026-04-30 16:54:57 +00:00
code: nextjs,frontends,script (13 files)
This commit is contained in:
@@ -19,8 +19,8 @@ import {
|
||||
import { PERMISSION_LEVELS, type PermissionLevel } from './levels-data'
|
||||
|
||||
const highlightColor = (level: PermissionLevel) => {
|
||||
if (level.id === 5) return 'warning.main'
|
||||
if (level.id === 4) return 'primary.main'
|
||||
if (level.id === 6) return 'warning.main'
|
||||
if (level.id === 5) return 'primary.main'
|
||||
return 'divider'
|
||||
}
|
||||
|
||||
@@ -62,10 +62,10 @@ export default function LevelsClient() {
|
||||
<Stack spacing={4}>
|
||||
<Stack spacing={1}>
|
||||
<Typography variant="h3" component="h1">
|
||||
The Five Permission Levels
|
||||
The Six Permission Levels
|
||||
</Typography>
|
||||
<Typography color="text.secondary">
|
||||
Level up through Guest, Regular User, Moderator, God, and Super God to unlock the right
|
||||
Level up through Public, User, Moderator, Admin, God, and Super God to unlock the right
|
||||
controls for your role.
|
||||
</Typography>
|
||||
</Stack>
|
||||
|
||||
@@ -11,47 +11,56 @@ export type PermissionLevel = {
|
||||
export const PERMISSION_LEVELS: PermissionLevel[] = [
|
||||
{
|
||||
id: 1,
|
||||
key: 'guest',
|
||||
title: 'Guest',
|
||||
badge: '👁️',
|
||||
description: 'Browse the public landing pages and marketing content with read-only access.',
|
||||
tagline: 'View-only browsing with zero privileges.',
|
||||
capabilities: ['Access front page', 'Read public articles', 'View news feed'],
|
||||
key: 'public',
|
||||
title: 'Public',
|
||||
badge: '🌍',
|
||||
description: 'Read-only access to marketing, help, and showcase pages without signing in.',
|
||||
tagline: 'Open browsing with zero authentication.',
|
||||
capabilities: ['Access the landing experience', 'Follow feature stories', 'Preview public dashboards'],
|
||||
},
|
||||
{
|
||||
id: 2,
|
||||
key: 'regular',
|
||||
title: 'Regular User',
|
||||
key: 'user',
|
||||
title: 'User',
|
||||
badge: '🧑💻',
|
||||
description: 'Interact with your profile, store preferences, and explore configurable dashboards.',
|
||||
tagline: 'Personalized space for regular contributors and team members.',
|
||||
capabilities: ['Edit personal settings', 'Update profile', 'Launch saved dashboards', 'Submit tickets'],
|
||||
description: 'Personalized workspace for building content, saving dashboards, and collaborating.',
|
||||
tagline: 'Everyday contributors and team members.',
|
||||
capabilities: ['Edit personal settings', 'Manage own content', 'Launch saved dashboards', 'Join shared workflows'],
|
||||
},
|
||||
{
|
||||
id: 3,
|
||||
key: 'moderator',
|
||||
title: 'Moderator',
|
||||
badge: '🛡️',
|
||||
description: 'Keep the community healthy, triage issues, and enforce conduct policies.',
|
||||
tagline: 'Guardrails for the wider user base.',
|
||||
capabilities: ['Moderate discussions', 'Resolve user flags', 'Review reports', 'Approve content'],
|
||||
description: 'Protect the community by triaging flags, reviewing reports, and shaping shared spaces.',
|
||||
tagline: 'Guardians of behavior and tone.',
|
||||
capabilities: ['Moderate discussions', 'Resolve user flags', 'Review incident reports', 'Hide or restore content'],
|
||||
},
|
||||
{
|
||||
id: 4,
|
||||
key: 'god',
|
||||
title: 'God',
|
||||
badge: '🧙♂️',
|
||||
description: 'Design workflows, compose pages, and orchestrate the system architecture.',
|
||||
tagline: 'Blueprint builder with editing rights.',
|
||||
capabilities: ['Edit the front page', 'Author workflows', 'Define multi-tenant settings', 'Seed packages'],
|
||||
key: 'admin',
|
||||
title: 'Admin',
|
||||
badge: '🧰',
|
||||
description: 'Tenant administrators who manage users, billing, policies, and broader content sets.',
|
||||
tagline: 'Operational control for the tenant layer.',
|
||||
capabilities: ['Manage user accounts', 'Adjust tenant settings', 'Approve packages', 'Oversee moderation queue'],
|
||||
},
|
||||
{
|
||||
id: 5,
|
||||
key: 'god',
|
||||
title: 'God',
|
||||
badge: '🧙♂️',
|
||||
description: 'Blueprint builders who orchestrate workflows, seed packages, and shape the system architecture.',
|
||||
tagline: 'Power users with advanced scripting rights.',
|
||||
capabilities: ['Author workflows', 'Compose the builder UI', 'Define multi-tenant templates', 'Seed packages'],
|
||||
},
|
||||
{
|
||||
id: 6,
|
||||
key: 'supergod',
|
||||
title: 'Super God',
|
||||
badge: '👑',
|
||||
description: 'Full sovereignty over the universe: transfer rights, manage infrastructure, and override controls.',
|
||||
tagline: 'Ultimate authority for system-level changes.',
|
||||
capabilities: ['Assign god roles', 'Transfer front page rights', 'Burn/restore tenants', 'Run security audits'],
|
||||
description: 'Full sovereignty over every tenant, infrastructure, and override path in the universe.',
|
||||
tagline: 'Ultimate authority for platform-level change.',
|
||||
capabilities: ['Assign god roles', 'Transfer ownership', 'Burn and restore tenants', 'Run system-wide audits'],
|
||||
},
|
||||
]
|
||||
|
||||
@@ -103,7 +103,9 @@ export function PageRoutesManager() {
|
||||
case 1: return 'bg-blue-500'
|
||||
case 2: return 'bg-green-500'
|
||||
case 3: return 'bg-orange-500'
|
||||
case 4: return 'bg-purple-500'
|
||||
case 4: return 'bg-sky-500'
|
||||
case 5: return 'bg-purple-500'
|
||||
case 6: return 'bg-rose-500'
|
||||
default: return 'bg-gray-500'
|
||||
}
|
||||
}
|
||||
@@ -165,8 +167,10 @@ export function PageRoutesManager() {
|
||||
<SelectContent>
|
||||
<SelectItem value="1">Level 1 - Public</SelectItem>
|
||||
<SelectItem value="2">Level 2 - User Area</SelectItem>
|
||||
<SelectItem value="3">Level 3 - Admin Panel</SelectItem>
|
||||
<SelectItem value="4">Level 4 - God Panel</SelectItem>
|
||||
<SelectItem value="3">Level 3 - Moderator Desk</SelectItem>
|
||||
<SelectItem value="4">Level 4 - Admin Panel</SelectItem>
|
||||
<SelectItem value="5">Level 5 - God Builder</SelectItem>
|
||||
<SelectItem value="6">Level 6 - Supergod Console</SelectItem>
|
||||
</SelectContent>
|
||||
</Select>
|
||||
</div>
|
||||
@@ -183,8 +187,10 @@ export function PageRoutesManager() {
|
||||
<SelectContent>
|
||||
<SelectItem value="public">Public</SelectItem>
|
||||
<SelectItem value="user">User</SelectItem>
|
||||
<SelectItem value="moderator">Moderator</SelectItem>
|
||||
<SelectItem value="admin">Admin</SelectItem>
|
||||
<SelectItem value="god">God</SelectItem>
|
||||
<SelectItem value="supergod">Supergod</SelectItem>
|
||||
</SelectContent>
|
||||
</Select>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user