Files
BizOne-portal/stitch_bizone/contacts_bizone_standard_layout/code.html

449 lines
22 KiB
HTML

<!DOCTYPE html>
<html class="light" lang="en"><head>
<meta charset="utf-8"/>
<meta content="width=device-width, initial-scale=1.0" name="viewport"/>
<title>Roles &amp; Permissions | BizOne Admin</title>
<script src="https://cdn.tailwindcss.com?plugins=forms,container-queries"></script>
<link href="https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;600;700;800&amp;family=Inter:wght@400;500;600&amp;family=JetBrains+Mono&amp;display=swap" rel="stylesheet"/>
<link href="https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:wght,FILL@100..700,0..1&amp;display=swap" rel="stylesheet"/>
<script id="tailwind-config">
tailwind.config = {
darkMode: "class",
theme: {
extend: {
"colors": {
"primary": "#001b44",
"primary-light": "#002d70",
"accent": "#00a3ff",
"on-surface": "#151e16",
"error": "#ba1a1a",
"surface": "#ffffff",
"secondary-container": "#e0f2fe",
"surface-tint": "#001b44",
"on-primary": "#ffffff",
"status-error": "#EF4444",
"background": "#F8F9FA",
"surface-variant": "#f1f5f9",
"on-surface-variant": "#475569",
"primary-container": "#001b44",
"on-primary-container": "#ffffff",
"surface-card": "#FFFFFF",
"outline-variant": "#E2E8F0",
"status-success": "#10b981",
"outline": "#94a3b8",
"surface-container": "#f8fafc",
"text-primary": "#0f172a",
"text-secondary": "#64748B",
"border-subtle": "#E2E8F0"
},
"borderRadius": {
"DEFAULT": "0.25rem",
"lg": "0.5rem",
"xl": "0.75rem",
"full": "9999px"
},
"spacing": {
"container-margin": "32px",
"gutter": "24px",
"sidebar-width": "260px",
"toolbar-height": "72px",
"card-padding": "20px",
"base": "8px"
},
"fontFamily": {
"headline-md": ["Plus Jakarta Sans"],
"body-md": ["Inter"],
"title-sm": ["Plus Jakarta Sans"],
"body-sm": ["Inter"],
"label-caps": ["Inter"],
"display-lg": ["Plus Jakarta Sans"],
"mono-code": ["jetbrainsMono"]
},
"fontSize": {
"headline-md": ["24px", {"lineHeight": "32px", "letterSpacing": "-0.01em", "fontWeight": "600"}],
"body-md": ["16px", {"lineHeight": "24px", "fontWeight": "400"}],
"title-sm": ["18px", {"lineHeight": "24px", "fontWeight": "600"}],
"body-sm": ["14px", {"lineHeight": "20px", "fontWeight": "400"}],
"label-caps": ["12px", {"lineHeight": "16px", "letterSpacing": "0.05em", "fontWeight": "600"}],
"display-lg": ["32px", {"lineHeight": "40px", "letterSpacing": "-0.02em", "fontWeight": "700"}],
"mono-code": ["13px", {"lineHeight": "20px", "fontWeight": "400"}]
}
},
},
}
</script>
<style>
body {
background-color: #F8F9FA;
font-family: 'Inter', sans-serif;
color: #151e16;
}
.material-symbols-outlined {
font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
vertical-align: middle;
}
.custom-scrollbar::-webkit-scrollbar { width: 4px; }
.custom-scrollbar::-webkit-scrollbar-track { background: transparent; }
.custom-scrollbar::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.1); border-radius: 10px; }
.permission-toggle:checked + .toggle-bg { background-color: #00a3ff; }
.permission-toggle:checked + .toggle-bg .toggle-dot { transform: translateX(100%); }
</style>
</head>
<body class="overflow-hidden">
<!-- SideNavBar -->
<aside class="fixed left-0 top-0 h-full w-[260px] bg-[#001b44] flex flex-col z-50">
<!-- Sidebar Header with Logo -->
<div class="h-[72px] bg-white flex items-center px-6 border-b border-gray-100">
<img alt="BizOne Logo" class="h-8 object-contain" src="https://lh3.googleusercontent.com/aida-public/AB6AXuCQgepHPm1Tlccl-KTg8J_Ohes_HmUgNgQpebBka5A4EQPSSDJrON0j4R_Wi6gOOlV-crnscfaztwQY6GRKbVjGWaAPn82BG2LhxBEdmD2OdYn3u-HSKsss2Q3qS4hTV0Dilzn1z0Qfx6dV3FRqKID5gAM5yb3TSVi4T96F6mQ69bBzh1Tib2zs9oKFXieUJs--RsKWw3BUiKUhBQcm-SBiWSSonbzAA8xFReCq3iOVJXR5O3RgUrfRv_GFfnoN4KFeTJM3smpcLrs"/>
</div>
<div class="mt-8 px-4 flex-1 flex flex-col gap-1 custom-scrollbar overflow-y-auto">
<button class="mb-6 w-full flex items-center justify-center gap-2 bg-accent text-white py-3 px-4 rounded-xl font-title-sm text-title-sm hover:opacity-90 transition-opacity">
<span class="material-symbols-outlined">add</span>
New Broadcast
</button>
<nav class="flex flex-col gap-1">
<a class="flex items-center gap-3 py-3 px-3 rounded-lg text-white/70 hover:text-white hover:bg-white/10 transition-colors font-body-md text-body-md" href="#">
<span class="material-symbols-outlined">dashboard</span>
Dashboard
</a>
<a class="flex items-center gap-3 py-3 px-3 rounded-lg text-white/70 hover:text-white hover:bg-white/10 transition-colors font-body-md text-body-md" href="#">
<span class="material-symbols-outlined">chat</span>
Conversations
</a>
<a class="flex items-center gap-3 py-3 px-3 rounded-lg text-white/70 hover:text-white hover:bg-white/10 transition-colors font-body-md text-body-md" href="#">
<span class="material-symbols-outlined">contacts</span>
Contacts
</a>
<a class="flex items-center gap-3 py-3 px-3 rounded-lg text-white/70 hover:text-white hover:bg-white/10 transition-colors font-body-md text-body-md" href="#">
<span class="material-symbols-outlined">description</span>
Templates
</a>
<a class="flex items-center gap-3 py-3 px-3 rounded-lg text-white/70 hover:text-white hover:bg-white/10 transition-colors font-body-md text-body-md" href="#">
<span class="material-symbols-outlined">webhook</span>
Webhooks
</a>
<a class="flex items-center gap-3 py-3 px-3 rounded-lg text-white/70 hover:text-white hover:bg-white/10 transition-colors font-body-md text-body-md" href="#">
<span class="material-symbols-outlined">monitoring</span>
Analytics
</a>
<a class="flex items-center gap-3 py-3 px-3 rounded-lg text-white font-bold bg-white/10 transition-colors font-body-md text-body-md" href="#">
<span class="material-symbols-outlined" style="font-variation-settings: 'FILL' 1;">settings</span>
Settings
</a>
</nav>
</div>
<div class="mt-auto p-4 border-t border-white/10 flex flex-col gap-1">
<a class="flex items-center gap-3 py-3 px-3 rounded-lg text-white/70 hover:text-white hover:bg-white/10 transition-colors font-body-md text-body-md" href="#">
<span class="material-symbols-outlined">help</span>
Help Center
</a>
<a class="flex items-center gap-3 py-3 px-3 rounded-lg text-white/70 hover:text-white hover:bg-white/10 transition-colors font-body-md text-body-md" href="#">
<span class="material-symbols-outlined">logout</span>
Logout
</a>
</div>
</aside>
<!-- Main Content Area -->
<div class="ml-[260px] min-h-screen flex flex-col">
<!-- TopNavBar -->
<header class="h-[72px] bg-white shadow-sm flex justify-between items-center px-gutter z-40 border-b border-gray-100">
<div class="flex items-center gap-6">
<div class="relative">
<span class="material-symbols-outlined absolute left-3 top-1/2 -translate-y-1/2 text-slate-400">search</span>
<input class="pl-10 pr-4 py-1.5 bg-slate-50 rounded-full border border-slate-200 focus:ring-2 focus:ring-accent focus:border-accent w-64 text-body-sm font-body-sm transition-all" placeholder="Search..." type="text"/>
</div>
<div class="flex gap-4 font-title-sm text-title-sm">
<a class="text-primary font-bold border-b-2 border-primary" href="#">English</a>
<a class="text-slate-500 hover:text-primary transition-all" href="#">Bahasa</a>
</div>
</div>
<div class="flex items-center gap-4">
<div class="flex gap-2">
<button class="p-2 rounded-full hover:bg-slate-50 text-slate-500 transition-colors">
<span class="material-symbols-outlined">notifications</span>
</button>
<button class="p-2 rounded-full hover:bg-slate-50 text-slate-500 transition-colors">
<span class="material-symbols-outlined">settings</span>
</button>
</div>
<div class="h-8 w-px bg-slate-200 mx-1"></div>
<div class="flex items-center gap-3">
<div class="text-right">
<p class="font-title-sm text-[14px] leading-tight font-bold text-primary">Admin User</p>
<p class="text-slate-500 text-[12px]">Global Admin</p>
</div>
<img alt="Admin Avatar" class="w-10 h-10 rounded-full object-cover border-2 border-slate-100" src="https://lh3.googleusercontent.com/aida-public/AB6AXuBaJS2OKrXWTy1XzOoMOfXrdLBIAP8f07UWKk8SrvBZl-XDCg0M9DvIxhv9t943CFtm9pwartTHJfa-AeR8Z2u2KqcnNbzTFpR9roPmrkOvZAFiTAewSMgvD-jA8cgsflEIi_dVkja8Ga-r5k3QFI5Mytf91IkCEQGhAjg4z6F4G1BdET2uX29j0ByJwog-qGCrMVWf1WYs19JUJ1vp83rONSVYdfucJuwbQpxdezjnInDT7w84eZzvEMx6Z19It3U7iIPH4pKhHwU"/>
</div>
</div>
</header>
<!-- Canvas -->
<main class="flex-1 overflow-y-auto p-gutter bg-[#F8F9FA]">
<div class="max-w-6xl mx-auto">
<!-- Page Header -->
<div class="mb-8 flex justify-between items-end">
<div>
<h2 class="font-display-lg text-display-lg text-primary mb-1">Roles &amp; Permissions</h2>
<p class="text-slate-600 font-body-md">Configure access levels and granular permissions for your team members.</p>
</div>
<button class="bg-primary text-white px-6 py-2.5 rounded-xl font-title-sm hover:bg-primary-light transition-all shadow-sm flex items-center gap-2">
<span class="material-symbols-outlined text-[20px]">add_moderator</span>
Create New Role
</button>
</div>
<!-- Bento Grid Layout for Roles -->
<div class="grid grid-cols-12 gap-6 mb-8">
<!-- Admin Role Card -->
<div class="col-span-12 lg:col-span-4 bg-white p-card-padding rounded-xl shadow-sm border border-slate-200 hover:shadow-md transition-shadow">
<div class="flex items-center justify-between mb-4">
<div class="p-3 bg-slate-100 rounded-lg">
<span class="material-symbols-outlined text-primary" style="font-variation-settings: 'FILL' 1;">shield_person</span>
</div>
<span class="px-3 py-1 bg-primary text-white text-label-caps rounded-full">Active</span>
</div>
<h3 class="font-headline-md text-[20px] mb-1">Admin</h3>
<p class="text-slate-500 text-body-sm mb-4">Full access to all modules, including system settings and billing.</p>
<div class="flex items-center gap-2 text-slate-500 text-body-sm">
<span class="material-symbols-outlined text-[18px]">group</span>
2 users assigned
</div>
</div>
<!-- Editor Role Card -->
<div class="col-span-12 lg:col-span-4 bg-white p-card-padding rounded-xl shadow-sm border border-slate-200 hover:shadow-md transition-shadow">
<div class="flex items-center justify-between mb-4">
<div class="p-3 bg-slate-100 rounded-lg">
<span class="material-symbols-outlined text-primary" style="font-variation-settings: 'FILL' 1;">edit_document</span>
</div>
<span class="px-3 py-1 bg-slate-100 text-slate-600 text-label-caps rounded-full">Standard</span>
</div>
<h3 class="font-headline-md text-[20px] mb-1">Editor</h3>
<p class="text-slate-500 text-body-sm mb-4">Can create templates and manage campaigns, but cannot change settings.</p>
<div class="flex items-center gap-2 text-slate-500 text-body-sm">
<span class="material-symbols-outlined text-[18px]">group</span>
5 users assigned
</div>
</div>
<!-- Agent Role Card -->
<div class="col-span-12 lg:col-span-4 bg-white p-card-padding rounded-xl shadow-sm border border-accent ring-1 ring-accent hover:shadow-md transition-shadow">
<div class="flex items-center justify-between mb-4">
<div class="p-3 bg-sky-50 rounded-lg">
<span class="material-symbols-outlined text-accent" style="font-variation-settings: 'FILL' 1;">support_agent</span>
</div>
<span class="px-3 py-1 bg-accent text-white text-label-caps rounded-full">Editing Now</span>
</div>
<h3 class="font-headline-md text-[20px] mb-1">Agent</h3>
<p class="text-slate-500 text-body-sm mb-4">Limited access to view analytics and respond to customer conversations.</p>
<div class="flex items-center gap-2 text-slate-500 text-body-sm">
<span class="material-symbols-outlined text-[18px]">group</span>
14 users assigned
</div>
</div>
</div>
<!-- Permission Matrix -->
<div class="bg-white rounded-xl shadow-sm border border-slate-200 overflow-hidden">
<div class="p-6 border-b border-slate-200 flex justify-between items-center bg-white">
<h3 class="font-title-sm text-title-sm">Permission Matrix: <span class="text-accent">Agent</span></h3>
<div class="flex gap-2">
<button class="px-4 py-2 border border-slate-300 rounded-lg text-body-sm font-medium text-slate-600 hover:bg-slate-50 transition-colors">Discard</button>
<button class="px-6 py-2 bg-primary text-white rounded-lg text-body-sm font-bold hover:bg-primary-light transition-opacity">Save Changes</button>
</div>
</div>
<div class="overflow-x-auto">
<table class="w-full text-left">
<thead>
<tr class="bg-slate-50/50">
<th class="py-4 px-6 text-label-caps text-slate-500 uppercase tracking-wider">Module / Permission</th>
<th class="py-4 px-6 text-label-caps text-slate-500 text-center uppercase tracking-wider">View</th>
<th class="py-4 px-6 text-label-caps text-slate-500 text-center uppercase tracking-wider">Create/Edit</th>
<th class="py-4 px-6 text-label-caps text-slate-500 text-center uppercase tracking-wider">Delete</th>
<th class="py-4 px-6 text-label-caps text-slate-500 text-center uppercase tracking-wider">Manage All</th>
</tr>
</thead>
<tbody class="divide-y divide-slate-100">
<!-- Group 1: Campaigns -->
<tr>
<td class="py-4 px-6">
<div class="flex items-center gap-3">
<span class="material-symbols-outlined text-slate-400">campaign</span>
<span class="font-title-sm text-[15px] text-slate-700">Manage Campaigns</span>
</div>
</td>
<td class="py-4 px-6 text-center">
<label class="relative inline-flex items-center cursor-pointer">
<input checked="" class="sr-only permission-toggle" type="checkbox"/>
<div class="w-10 h-5 bg-slate-200 rounded-full toggle-bg transition-colors flex items-center p-1">
<div class="w-3 h-3 bg-white rounded-full toggle-dot transition-transform shadow-sm"></div>
</div>
</label>
</td>
<td class="py-4 px-6 text-center">
<label class="relative inline-flex items-center cursor-pointer">
<input class="sr-only permission-toggle" type="checkbox"/>
<div class="w-10 h-5 bg-slate-200 rounded-full toggle-bg transition-colors flex items-center p-1">
<div class="w-3 h-3 bg-white rounded-full toggle-dot transition-transform shadow-sm"></div>
</div>
</label>
</td>
<td class="py-4 px-6 text-center">
<label class="relative inline-flex items-center cursor-pointer">
<input class="sr-only permission-toggle" type="checkbox"/>
<div class="w-10 h-5 bg-slate-200 rounded-full toggle-bg transition-colors flex items-center p-1">
<div class="w-3 h-3 bg-white rounded-full toggle-dot transition-transform shadow-sm"></div>
</div>
</label>
</td>
<td class="py-4 px-6 text-center">
<label class="relative inline-flex items-center cursor-pointer">
<input class="sr-only permission-toggle" type="checkbox"/>
<div class="w-10 h-5 bg-slate-200 rounded-full toggle-bg transition-colors flex items-center p-1">
<div class="w-3 h-3 bg-white rounded-full toggle-dot transition-transform shadow-sm"></div>
</div>
</label>
</td>
</tr>
<!-- Group 2: Analytics -->
<tr>
<td class="py-4 px-6">
<div class="flex items-center gap-3">
<span class="material-symbols-outlined text-slate-400">monitoring</span>
<span class="font-title-sm text-[15px] text-slate-700">View Analytics</span>
</div>
</td>
<td class="py-4 px-6 text-center">
<label class="relative inline-flex items-center cursor-pointer">
<input checked="" class="sr-only permission-toggle" type="checkbox"/>
<div class="w-10 h-5 bg-slate-200 rounded-full toggle-bg transition-colors flex items-center p-1">
<div class="w-3 h-3 bg-white rounded-full toggle-dot transition-transform shadow-sm"></div>
</div>
</label>
</td>
<td class="py-4 px-6 text-center"></td>
<td class="py-4 px-6 text-center"></td>
<td class="py-4 px-6 text-center">
<label class="relative inline-flex items-center cursor-pointer">
<input class="sr-only permission-toggle" type="checkbox"/>
<div class="w-10 h-5 bg-slate-200 rounded-full toggle-bg transition-colors flex items-center p-1">
<div class="w-3 h-3 bg-white rounded-full toggle-dot transition-transform shadow-sm"></div>
</div>
</label>
</td>
</tr>
<!-- Group 3: Settings -->
<tr>
<td class="py-4 px-6">
<div class="flex items-center gap-3">
<span class="material-symbols-outlined text-slate-400">settings</span>
<span class="font-title-sm text-[15px] text-slate-700">Edit Settings</span>
</div>
</td>
<td class="py-4 px-6 text-center">
<label class="relative inline-flex items-center cursor-pointer">
<input class="sr-only permission-toggle" type="checkbox"/>
<div class="w-10 h-5 bg-slate-200 rounded-full toggle-bg transition-colors flex items-center p-1">
<div class="w-3 h-3 bg-white rounded-full toggle-dot transition-transform shadow-sm"></div>
</div>
</label>
</td>
<td class="py-4 px-6 text-center">
<label class="relative inline-flex items-center cursor-pointer">
<input class="sr-only permission-toggle" type="checkbox"/>
<div class="w-10 h-5 bg-slate-200 rounded-full toggle-bg transition-colors flex items-center p-1">
<div class="w-3 h-3 bg-white rounded-full toggle-dot transition-transform shadow-sm"></div>
</div>
</label>
</td>
<td class="py-4 px-6 text-center">
<label class="relative inline-flex items-center cursor-pointer">
<input class="sr-only permission-toggle" type="checkbox"/>
<div class="w-10 h-5 bg-slate-200 rounded-full toggle-bg transition-colors flex items-center p-1">
<div class="w-3 h-3 bg-white rounded-full toggle-dot transition-transform shadow-sm"></div>
</div>
</label>
</td>
<td class="py-4 px-6 text-center">
<label class="relative inline-flex items-center cursor-pointer">
<input class="sr-only permission-toggle" type="checkbox"/>
<div class="w-10 h-5 bg-slate-200 rounded-full toggle-bg transition-colors flex items-center p-1">
<div class="w-3 h-3 bg-white rounded-full toggle-dot transition-transform shadow-sm"></div>
</div>
</label>
</td>
</tr>
<!-- Group 4: Billing -->
<tr>
<td class="py-4 px-6">
<div class="flex items-center gap-3">
<span class="material-symbols-outlined text-slate-400">payments</span>
<span class="font-title-sm text-[15px] text-slate-700">Billing &amp; Invoices</span>
</div>
</td>
<td class="py-4 px-6 text-center">
<label class="relative inline-flex items-center cursor-pointer">
<input class="sr-only permission-toggle" type="checkbox"/>
<div class="w-10 h-5 bg-slate-200 rounded-full toggle-bg transition-colors flex items-center p-1">
<div class="w-3 h-3 bg-white rounded-full toggle-dot transition-transform shadow-sm"></div>
</div>
</label>
</td>
<td class="py-4 px-6 text-center"></td>
<td class="py-4 px-6 text-center"></td>
<td class="py-4 px-6 text-center">
<label class="relative inline-flex items-center cursor-pointer">
<input class="sr-only permission-toggle" type="checkbox"/>
<div class="w-10 h-5 bg-slate-200 rounded-full toggle-bg transition-colors flex items-center p-1">
<div class="w-3 h-3 bg-white rounded-full toggle-dot transition-transform shadow-sm"></div>
</div>
</label>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<!-- Footer Log & Help Section -->
<div class="mt-8 grid grid-cols-12 gap-6">
<div class="col-span-12 lg:col-span-8 bg-white p-6 rounded-xl shadow-sm border border-slate-200">
<div class="flex items-center justify-between mb-6">
<h3 class="font-title-sm text-title-sm text-primary">Audit Log: Recent Changes</h3>
<a class="text-accent text-body-sm font-bold hover:underline" href="#">View All</a>
</div>
<div class="space-y-4">
<div class="flex items-center justify-between py-3 border-b border-slate-100 last:border-0">
<div class="flex items-center gap-4">
<div class="w-10 h-10 rounded-full bg-slate-50 flex items-center justify-center border border-slate-100">
<span class="material-symbols-outlined text-accent">person_edit</span>
</div>
<div>
<p class="text-body-md font-semibold text-slate-800">Admin updated 'Agent' permissions</p>
<p class="text-body-sm text-slate-500">Changed 'View Analytics' from OFF to ON</p>
</div>
</div>
<span class="text-label-caps text-slate-400">2 mins ago</span>
</div>
<div class="flex items-center justify-between py-3 border-b border-slate-100 last:border-0">
<div class="flex items-center gap-4">
<div class="w-10 h-10 rounded-full bg-slate-50 flex items-center justify-center border border-slate-100">
<span class="material-symbols-outlined text-accent">add_circle</span>
</div>
<div>
<p class="text-body-md font-semibold text-slate-800">Created new role: 'Reporting Only'</p>
<p class="text-body-sm text-slate-500">Assigned to 0 users</p>
</div>
</div>
<span class="text-label-caps text-slate-400">4 hours ago</span>
</div>
</div>
</div>
<div class="col-span-12 lg:col-span-4 bg-primary text-white p-6 rounded-xl shadow-lg relative overflow-hidden group">
<div class="relative z-10">
<h3 class="font-headline-md text-[20px] mb-2">Need help?</h3>
<p class="opacity-80 text-body-sm mb-6">Learn more about how to set up granular access for high-security enterprise environments.</p>
<button class="bg-white text-primary px-5 py-2 rounded-lg font-bold text-body-sm hover:bg-slate-50 transition-colors">Documentation</button>
</div>
<span class="material-symbols-outlined absolute -right-4 -bottom-4 text-[120px] opacity-10 group-hover:scale-110 transition-transform">lock_person</span>
</div>
</div>
</div>
</main>
</div>
</body></html>