Tab Constant is added

This commit is contained in:
2026-07-29 14:39:55 +05:30
parent 7ce1f2705e
commit f9c3e7968b
28 changed files with 1299 additions and 1093 deletions

View File

@@ -1,9 +1,6 @@
import { useState } from 'react';
import {
Building2,
Users,
MapPin,
Grid,
Plus,
Eye,
Settings,
@@ -13,164 +10,12 @@ import {
ChevronDown
} from "lucide-react";
import Button from "@/components/common/button";
import StatCard from "@/components/common/dashStatCard";
import Table from '@/components/common/dataTable';
import { StatusBadge } from '@/components/common/statusBadge';
import { organizationHeaders, organizationRows } from "@/constants/adminTableDatat";
export const organizationHeaders = [
"Organization",
"Tenant ID",
"Contact",
"Time Zone",
"Status",
"Actions",
];
const ActionButtons = () => (
<div className="flex items-center justify-center gap-1">
<Button className="flex h-8 w-8 items-center justify-center rounded-md border border-slate-700/60 text-slate-400 hover:bg-slate-800 hover:text-white transition">
<Eye size={15} />
</Button>
<Button className="flex h-8 w-8 items-center justify-center rounded-md border border-slate-700/60 text-slate-400 hover:bg-slate-800 hover:text-white transition">
<Settings size={15} />
</Button>
<Button className="flex h-8 w-8 items-center justify-center rounded-md border border-slate-700/60 text-slate-400 hover:bg-slate-800 hover:text-white transition">
<GitBranch size={15} />
</Button>
<Button className="flex h-8 w-8 items-center justify-center rounded-md border border-slate-700/60 text-slate-400 hover:bg-slate-800 hover:text-white transition">
<Pencil size={15} />
</Button>
</div>
);
export const organizationRows = [
[
<div className="flex items-center gap-3">
<div className="flex h-10 w-10 items-center justify-center rounded-xl bg-emerald-500/15 font-semibold text-emerald-400">
AO
</div>
<div>
<div className="font-semibold text-slate-100">Apple One</div>
<div className="text-slate-400">ops@appleone.com</div>
</div>
</div>,
<span className="rounded-md border border-slate-700 bg-slate-900 px-3 py-1 font-mono text-slate-300">
TNT-1001
</span>,
<div>
<div className="font-semibold text-slate-100">Dhananjay T.</div>
<div className="text-sky-300">+91 98200 10001</div>
</div>,
<span className="font-mono">Asia/Kolkata</span>,
<StatusBadge
text="Active"
color="bg-emerald-500/15 text-emerald-400"
/>,
<ActionButtons />,
],
[
<div className="flex items-center gap-3">
<div className="flex h-10 w-10 items-center justify-center rounded-xl bg-blue-500/15 font-semibold text-blue-400">
NP
</div>
<div>
<div className="font-semibold text-slate-100">Novotel Pune</div>
<div className="text-slate-400">fm@novotelpune.com</div>
</div>
</div>,
<span className="rounded-md border border-slate-700 bg-slate-900 px-3 py-1 font-mono text-slate-300">
TNT-1002
</span>,
<div>
<div className="font-semibold text-slate-100">Site FM Lead</div>
<div className="text-sky-300">+91 98220 20002</div>
</div>,
<span className="font-mono">Asia/Kolkata</span>,
<StatusBadge
text="Active"
color="bg-emerald-500/15 text-emerald-400"
/>,
<ActionButtons />,
],
[
<div className="flex items-center gap-3">
<div className="flex h-10 w-10 items-center justify-center rounded-xl bg-blue-500/15 font-semibold text-blue-400">
SC
</div>
<div>
<div className="font-semibold text-slate-100">SRM Campus</div>
<div className="text-slate-400">estates@srm.edu</div>
</div>
</div>,
<span className="rounded-md border border-slate-700 bg-slate-900 px-3 py-1 font-mono text-slate-300">
TNT-1003
</span>,
<div>
<div className="font-semibold text-slate-100">Estates Office</div>
<div className="text-sky-300">+91 98430 30003</div>
</div>,
<span className="font-mono">Asia/Kolkata</span>,
<StatusBadge
text="Active"
color="bg-emerald-500/15 text-emerald-400"
/>,
<ActionButtons />,
],
[
<div className="flex items-center gap-3">
<div className="flex h-10 w-10 items-center justify-center rounded-xl bg-blue-500/15 font-semibold text-blue-400">
L1
</div>
<div>
<div className="font-semibold text-slate-100">Local 1</div>
<div className="text-slate-400">admin@local1.com</div>
</div>
</div>,
<span className="rounded-md border border-slate-700 bg-slate-900 px-3 py-1 font-mono text-slate-300">
TNT-1004
</span>,
<div>
<div className="font-semibold text-slate-100">Local Admin</div>
<div className="text-sky-300">+91 98000 40004</div>
</div>,
<span className="font-mono">Asia/Kolkata</span>,
<StatusBadge
text="Active"
color="bg-emerald-500/15 text-emerald-400"
/>,
<ActionButtons />,
],
];
export default function TenantsPortal() {
@@ -180,12 +25,12 @@ export default function TenantsPortal() {
{/* --- HEADER SECTION --- */}
<div className="flex flex-col md:flex-row md:items-start md:justify-between gap-4 mb-6">
<div>
<div className="flex items-center gap-2 text-[10px] font-bold tracking-widest uppercase font-mono">
<span className="text-teal-400">PLATFORM</span>
<span className="text-slate-500"></span>
<span className="text-slate-500">TENANTS</span>
<div className="flex items-center gap-2 text-[12px] font-bold tracking-widest uppercase font-mono">
<span className="text-gray-400">PLATFORM</span>
<span className="text-gray-600"></span>
<span className="text-gray-400">TENANTS</span>
</div>
<h1 className="text-3xl font-bold text-white tracking-tight mt-1">
<h1 className="text-2xl font-bold text-white tracking-tight mt-1">
Tenants
</h1>
<p className="text-sm font-medium text-slate-400 mt-1 max-w-xl leading-relaxed">