139 lines
3.6 KiB
TypeScript
139 lines
3.6 KiB
TypeScript
// Path: Frontend/src/components/shell/data/shell.data.ts
|
|
|
|
import type { Component } from "solid-js";
|
|
import { Bell, Folder, Home, LayoutGrid, Search, Settings, User } from "../../../lib/icons";
|
|
|
|
type ShellIconProps = {
|
|
class?: string;
|
|
size?: number;
|
|
strokeWidth?: number;
|
|
};
|
|
|
|
export type ShellIcon = Component<ShellIconProps>;
|
|
|
|
export type RailItem = {
|
|
id: string;
|
|
label: string;
|
|
abbreviation: string;
|
|
kind: "personal" | "organization";
|
|
active?: boolean;
|
|
};
|
|
|
|
export type ServerDockAction = {
|
|
id: string;
|
|
label: string;
|
|
icon: ShellIcon;
|
|
};
|
|
|
|
export type ActiveServer = {
|
|
id: string;
|
|
name: string;
|
|
abbreviation: string;
|
|
kind: "personal" | "organization";
|
|
connectedLabel?: string;
|
|
subtitle?: string;
|
|
dockActions: readonly ServerDockAction[];
|
|
};
|
|
|
|
export type ActiveProject = {
|
|
id: string;
|
|
name: string;
|
|
};
|
|
|
|
export type ActiveDepartment = {
|
|
id: string;
|
|
name: string;
|
|
teamName: string;
|
|
};
|
|
|
|
export type DepartmentItem = {
|
|
id: string;
|
|
name: string;
|
|
teams: readonly string[];
|
|
active?: boolean;
|
|
};
|
|
|
|
export type ProjectItem = {
|
|
id: string;
|
|
name: string;
|
|
description: string;
|
|
active?: boolean;
|
|
};
|
|
|
|
export type SidebarItem = {
|
|
id: string;
|
|
label: string;
|
|
icon: ShellIcon;
|
|
active?: boolean;
|
|
meta?: string;
|
|
};
|
|
|
|
export type TopBarAction = {
|
|
id: string;
|
|
label: string;
|
|
icon: ShellIcon;
|
|
};
|
|
|
|
const personalDockActions: readonly ServerDockAction[] = [
|
|
{ id: "account", label: "Account", icon: User },
|
|
{ id: "settings", label: "Settings", icon: Settings },
|
|
] as const;
|
|
|
|
const organizationAdminDockActions: readonly ServerDockAction[] = [
|
|
{ id: "members", label: "Members", icon: User },
|
|
{ id: "server", label: "Server", icon: Settings },
|
|
] as const;
|
|
|
|
// Server shell scaffold data
|
|
export const railItems: readonly RailItem[] = [
|
|
{ id: "personal-server", label: "Personal Server Name", abbreviation: "P", kind: "personal" },
|
|
{ id: "organization-server", label: "Organization Name", abbreviation: "O", kind: "organization", active: true },
|
|
{ id: "design-review", label: "Design Review", abbreviation: "D", kind: "organization" },
|
|
] as const;
|
|
|
|
export const activeServer: ActiveServer = {
|
|
id: "organization-server",
|
|
name: "Organization Name",
|
|
abbreviation: "O",
|
|
kind: "organization",
|
|
connectedLabel: "12 connected",
|
|
dockActions: organizationAdminDockActions,
|
|
};
|
|
|
|
// Workspace framing scaffold data
|
|
export const activeProject: ActiveProject = {
|
|
id: "general",
|
|
name: "General",
|
|
};
|
|
|
|
export const activeDepartment: ActiveDepartment = {
|
|
id: "product",
|
|
name: "Product",
|
|
teamName: "Design Systems",
|
|
};
|
|
|
|
export const projectItems: readonly ProjectItem[] = [
|
|
{ id: "general", name: "General", description: "Default shared project", active: true },
|
|
{ id: "operations", name: "Operations", description: "Cross-team planning and delivery" },
|
|
{ id: "hiring", name: "Hiring", description: "Candidate pipeline and interview loops" },
|
|
] as const;
|
|
|
|
export const departmentItems: readonly DepartmentItem[] = [
|
|
{ id: "product", name: "Product", teams: ["Design Systems", "Research Ops"], active: true },
|
|
{ id: "engineering", name: "Engineering", teams: ["Platform", "Realtime Collaboration"] },
|
|
{ id: "operations", name: "Operations", teams: ["Shared Services", "People Ops"] },
|
|
] as const;
|
|
|
|
// Sidebar and topbar scaffold data
|
|
export const serverSidebarItems: readonly SidebarItem[] = [
|
|
{ id: "home", label: "Home", icon: Home, active: true },
|
|
{ id: "boards", label: "Boards", icon: LayoutGrid, meta: "0" },
|
|
{ id: "docs", label: "Docs", icon: Folder, meta: "0" },
|
|
{ id: "settings", label: "Settings", icon: Settings },
|
|
] as const;
|
|
|
|
export const topBarActions: readonly TopBarAction[] = [
|
|
{ id: "search", label: "Search", icon: Search },
|
|
{ id: "inbox", label: "Inbox", icon: Bell },
|
|
] as const;
|