"use client";
import React, { useState } from "react";
import { Plus, QrCode, Sparkles } from "lucide-react";
export default function MasterDataPortal() {
const [activeTab, setActiveTab] = useState("Block / Floor / Zone");
// Sample data for the hierarchy cards
const blocks = ["Block 1", "Block 2", "Tower A"];
const floors = ["Ground", "Floor 1", "Floor 2"];
const zones = ["Zone N", "Zone Z1", "Zone Z2"];
return (
{/* --- BREADCRUMB --- */}
APPLE ONE — HQ TOWER
•
CONFIGURE
•
MASTER DATA
{/* --- PAGE HEADER --- */}
Master data
Every transactional module reads from these masters — keep them complete and
they cascade across equipment, requests, budgets, training and reports.
{/* --- CATEGORY BUTTONS / TABS --- */}
{/* Row 1: Site & Location, Assets, Operations, Finance */}
{/* SITE & LOCATION */}
SITE & LOCATION
setActiveTab("Block / Floor / Zone")}
className={`px-3 py-1.5 rounded-lg border text-xs font-semibold transition-all ${
activeTab === "Block / Floor / Zone"
? "bg-[#0b2926] text-emerald-400 border-emerald-500/80 shadow-[0_0_12px_rgba(16,185,129,0.15)]"
: "bg-[#0c1622] text-slate-300 border-slate-800 hover:border-slate-700"
}`}
>
Block / Floor / Zone
{/* ASSETS */}
ASSETS
{["Manufacturer", "Service Provider", "Criticality"].map((item) => (
setActiveTab(item)}
className={`px-3 py-1.5 rounded-lg border text-xs transition-all ${
activeTab === item
? "bg-[#0b2926] text-emerald-400 border-emerald-500/80"
: "bg-[#0c1622] text-slate-300 border-slate-800/80 hover:bg-slate-800/50"
}`}
>
{item}
))}
{/* OPERATIONS */}
OPERATIONS
{["Service Type", "Unit", "Store", "Partners"].map((item) => (
setActiveTab(item)}
className={`px-3 py-1.5 rounded-lg border text-xs transition-all ${
activeTab === item
? "bg-[#0b2926] text-emerald-400 border-emerald-500/80"
: "bg-[#0c1622] text-slate-300 border-slate-800/80 hover:bg-slate-800/50"
}`}
>
{item}
))}
{/* FINANCE */}
FINANCE
{["Budget Category", "Budget Type"].map((item) => (
setActiveTab(item)}
className={`px-3 py-1.5 rounded-lg border text-xs transition-all ${
activeTab === item
? "bg-[#0b2926] text-emerald-400 border-emerald-500/80"
: "bg-[#0c1622] text-slate-300 border-slate-800/80 hover:bg-slate-800/50"
}`}
>
{item}
))}
{/* Row 2: People */}
PEOPLE
setActiveTab("Course")}
className={`px-3 py-1.5 rounded-lg border text-xs font-semibold transition-all ${
activeTab === "Course"
? "bg-[#0b2926] text-emerald-400 border-emerald-500/80"
: "bg-[#0c1622] text-slate-300 border-slate-800/80 hover:bg-slate-800/50"
}`}
>
Course
{/* --- INFO BANNER --- */}
Within a site: sites themselves are defined in{" "}
Administration → Sites (with geofence).
Here you manage the Block / Floor / Zone hierarchy inside the active
site — reused by Equipment, Desks, Requests and Floor plans.
{/* --- ACTION BUTTON --- */}
Generate QR
{/* --- HIERARCHY CARDS GRID --- */}
{/* Block Column */}
Block
{blocks.length}
{blocks.map((item, idx) => (
))}
Add block
{/* Floor Column */}
Floor
{floors.length}
{floors.map((item, idx) => (
))}
Add floor
{/* Zone Column */}
Zone
{zones.length}
{zones.map((item, idx) => (
))}
Add zone
);
}