@burdenoff/microfe-crewfoundry 2026.625.1 → 2026.626.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/crewfoundry/pages/AdminAdminPagePage.js +37 -29
- package/dist/crewfoundry/pages/AdminAdminPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/AnalyticsAnalyticsPagePage.js +50 -42
- package/dist/crewfoundry/pages/AnalyticsAnalyticsPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/AnalyticsEmployeeAnalyticsPagePage.js +39 -31
- package/dist/crewfoundry/pages/AnalyticsEmployeeAnalyticsPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/AnalyticsFinancialAnalyticsPagePage.js +52 -44
- package/dist/crewfoundry/pages/AnalyticsFinancialAnalyticsPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/AnalyticsHiringAnalyticsPagePage.js +46 -38
- package/dist/crewfoundry/pages/AnalyticsHiringAnalyticsPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/CommunicationsAnnouncementsPagePage.js +28 -15
- package/dist/crewfoundry/pages/CommunicationsAnnouncementsPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/CommunicationsCallsPagePage.js +30 -22
- package/dist/crewfoundry/pages/CommunicationsCallsPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/CommunicationsDirectoryPagePage.js +87 -69
- package/dist/crewfoundry/pages/CommunicationsDirectoryPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/CommunicationsFilesPagePage.js +99 -80
- package/dist/crewfoundry/pages/CommunicationsFilesPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/CommunicationsMessagesPagePage.js +86 -67
- package/dist/crewfoundry/pages/CommunicationsMessagesPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/CommunicationsTeamsPagePage.js +31 -15
- package/dist/crewfoundry/pages/CommunicationsTeamsPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/CommunicationsVideoCallsPagePage.js +37 -29
- package/dist/crewfoundry/pages/CommunicationsVideoCallsPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/CompanyClientManagementPagePage.js +29 -21
- package/dist/crewfoundry/pages/CompanyClientManagementPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/CompanyCompanyDashboardPagePage.js +25 -17
- package/dist/crewfoundry/pages/CompanyCompanyDashboardPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/CompanyCompanyProfilePagePage.js +42 -35
- package/dist/crewfoundry/pages/CompanyCompanyProfilePagePage.js.map +1 -1
- package/dist/crewfoundry/pages/CompanyVendorManagementPagePage.js +80 -62
- package/dist/crewfoundry/pages/CompanyVendorManagementPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/DashboardAnalyticsPagePage.js +41 -33
- package/dist/crewfoundry/pages/DashboardAnalyticsPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/DashboardDashboardPagePage.js +142 -108
- package/dist/crewfoundry/pages/DashboardDashboardPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/DashboardEnhancedDashboardPagePage.js +177 -136
- package/dist/crewfoundry/pages/DashboardEnhancedDashboardPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/DashboardExecutiveDashboardPage.js +44 -36
- package/dist/crewfoundry/pages/DashboardExecutiveDashboardPage.js.map +1 -1
- package/dist/crewfoundry/pages/HelpApiDocumentationPagePage.js +49 -38
- package/dist/crewfoundry/pages/HelpApiDocumentationPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/HiringApplicationsPagePage.js +26 -18
- package/dist/crewfoundry/pages/HiringApplicationsPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/HiringCandidatesPagePage.js +112 -93
- package/dist/crewfoundry/pages/HiringCandidatesPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/HiringCreateJobPagePage.js +53 -46
- package/dist/crewfoundry/pages/HiringCreateJobPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/HiringInterviewsPagePage.js +31 -23
- package/dist/crewfoundry/pages/HiringInterviewsPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/HiringJobDetailsPagePage.js +129 -90
- package/dist/crewfoundry/pages/HiringJobDetailsPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/HiringJobsPagePage.js +96 -85
- package/dist/crewfoundry/pages/HiringJobsPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/HrDepartmentsPagePage.js +26 -18
- package/dist/crewfoundry/pages/HrDepartmentsPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/HrEmployeesPagePage.js +47 -35
- package/dist/crewfoundry/pages/HrEmployeesPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/HrLeaveManagementPagePage.js +33 -25
- package/dist/crewfoundry/pages/HrLeaveManagementPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/HrPayrollPagePage.js +36 -28
- package/dist/crewfoundry/pages/HrPayrollPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/HrTimeTrackingPagePage.js +27 -19
- package/dist/crewfoundry/pages/HrTimeTrackingPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/LearningAssessmentsPagePage.js +27 -19
- package/dist/crewfoundry/pages/LearningAssessmentsPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/LearningCertificatesPagePage.js +93 -75
- package/dist/crewfoundry/pages/LearningCertificatesPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/LearningCourseDetailsPagePage.js +111 -70
- package/dist/crewfoundry/pages/LearningCourseDetailsPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/LearningCourseLearningPagePage.js +65 -53
- package/dist/crewfoundry/pages/LearningCourseLearningPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/LearningCoursesPagePage.js +35 -19
- package/dist/crewfoundry/pages/LearningCoursesPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/LearningLearningAnalyticsPagePage.js +33 -25
- package/dist/crewfoundry/pages/LearningLearningAnalyticsPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/LearningLearningPagePage.js +26 -18
- package/dist/crewfoundry/pages/LearningLearningPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/LearningLearningPathDetailPagePage.js +80 -55
- package/dist/crewfoundry/pages/LearningLearningPathDetailPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/LearningLearningPathsPagePage.js +33 -17
- package/dist/crewfoundry/pages/LearningLearningPathsPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/LearningMyLearningPagePage.js +31 -23
- package/dist/crewfoundry/pages/LearningMyLearningPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/MarketplaceBookingManagementPagePage.js +29 -21
- package/dist/crewfoundry/pages/MarketplaceBookingManagementPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/MarketplaceEarningsPagePage.js +35 -27
- package/dist/crewfoundry/pages/MarketplaceEarningsPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/MarketplaceFreelancerProfilePageEnhancedPage.js +147 -112
- package/dist/crewfoundry/pages/MarketplaceFreelancerProfilePageEnhancedPage.js.map +1 -1
- package/dist/crewfoundry/pages/MarketplaceFreelancerProfilePagePage.js +31 -27
- package/dist/crewfoundry/pages/MarketplaceFreelancerProfilePagePage.js.map +1 -1
- package/dist/crewfoundry/pages/MarketplaceMarketplacePagePage.js +31 -23
- package/dist/crewfoundry/pages/MarketplaceMarketplacePagePage.js.map +1 -1
- package/dist/crewfoundry/pages/MarketplaceMarketplaceServicesPagePage.js +104 -85
- package/dist/crewfoundry/pages/MarketplaceMarketplaceServicesPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/MarketplaceMessagingPagePage.js +75 -56
- package/dist/crewfoundry/pages/MarketplaceMessagingPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/MarketplaceMyServicesPagePage.js +78 -60
- package/dist/crewfoundry/pages/MarketplaceMyServicesPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/MarketplaceProjectDetailsPagePage.js +133 -92
- package/dist/crewfoundry/pages/MarketplaceProjectDetailsPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/MarketplaceServiceDetailsPagePage.js +93 -52
- package/dist/crewfoundry/pages/MarketplaceServiceDetailsPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/PaymentsEscrowPagePage.js +28 -20
- package/dist/crewfoundry/pages/PaymentsEscrowPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/PaymentsInvoicesPagePage.js +84 -65
- package/dist/crewfoundry/pages/PaymentsInvoicesPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/PaymentsPaymentDashboardPagePage.js +25 -17
- package/dist/crewfoundry/pages/PaymentsPaymentDashboardPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/PaymentsPaymentMethodsPagePage.js +58 -40
- package/dist/crewfoundry/pages/PaymentsPaymentMethodsPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/PaymentsSecurityPagePage.js +41 -33
- package/dist/crewfoundry/pages/PaymentsSecurityPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/ProjectsCreateProjectPagePage.js +36 -29
- package/dist/crewfoundry/pages/ProjectsCreateProjectPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/ProjectsProjectDetailsPagePage.js +103 -72
- package/dist/crewfoundry/pages/ProjectsProjectDetailsPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/ProjectsProjectsPagePage.js +43 -27
- package/dist/crewfoundry/pages/ProjectsProjectsPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/TeamsTeamAnalyticsPagePage.js +28 -20
- package/dist/crewfoundry/pages/TeamsTeamAnalyticsPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/TeamsTeamDetailPagePage.js +103 -62
- package/dist/crewfoundry/pages/TeamsTeamDetailPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/TeamsTeamDirectoryPagePage.js +83 -64
- package/dist/crewfoundry/pages/TeamsTeamDirectoryPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/TeamsTeamSettingsPagePage.js +185 -144
- package/dist/crewfoundry/pages/TeamsTeamSettingsPagePage.js.map +1 -1
- package/dist/crewfoundry/pages/TeamsTeamsPagePage.js +40 -24
- package/dist/crewfoundry/pages/TeamsTeamsPagePage.js.map +1 -1
- package/package.json +2 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DashboardEnhancedDashboardPagePage.js","names":[],"sources":["../../../src/crewfoundry/pages/DashboardEnhancedDashboardPagePage.tsx"],"sourcesContent":["import { useMemo } from 'react';\nimport {\n Badge,\n Button,\n Card,\n CardContent,\n CardDescription,\n CardHeader,\n CardTitle,\n GradientText,\n Separator,\n} from '@burdenoff/fe-libs/ui';\nimport {\n AlertTriangle,\n ArrowUpRight,\n Award,\n Bell,\n Briefcase,\n CheckCircle,\n MapPin,\n Star,\n Users,\n Zap,\n} from 'lucide-react';\nimport { useCrewFoundryStore } from '../store/crewfoundryStore';\n\nexport function DashboardEnhancedDashboardPagePage() {\n const {\n employees,\n jobPostings,\n candidates,\n interviews,\n leaveRequests,\n notifications,\n projects,\n announcements,\n } = useCrewFoundryStore();\n\n const quickActions = useMemo(\n () => [\n {\n label: `Post New Job (${jobPostings.filter((job) => job.status === 'active').length} active)`,\n icon: Briefcase,\n color: 'text-status-info-text',\n },\n {\n label: `Review Candidates (${candidates.filter((candidate) => candidate.status === 'new').length})`,\n icon: Users,\n color: 'text-action-primary-bg',\n },\n {\n label: `Approve Leaves (${leaveRequests.filter((leave) => leave.status === 'pending').length})`,\n icon: CheckCircle,\n color: 'text-status-success-text',\n },\n {\n label: `Run Payroll (${projects.filter((project) => project.status === 'active').length} projects)`,\n icon: Zap,\n color: 'text-status-warning-text',\n },\n ],\n [candidates, jobPostings, leaveRequests, projects]\n );\n\n const companyGoals = useMemo(\n () => [\n {\n goal: 'Reduce time-to-hire to 25 days',\n current: Math.max(\n 20,\n 40 - candidates.filter((candidate) => candidate.status === 'hired').length\n ),\n target: 25,\n unit: 'days',\n },\n {\n goal: 'Achieve 95% employee satisfaction',\n current: Math.round(\n (employees.reduce((sum, employee) => sum + employee.performanceScore, 0) /\n Math.max(employees.length, 1)) *\n 20\n ),\n target: 95,\n unit: '%',\n },\n {\n goal: 'Fill 30 open positions by Q2',\n current: candidates.filter((candidate) => candidate.status === 'hired').length,\n target: 30,\n unit: 'positions',\n },\n {\n goal: 'Complete 80% training compliance',\n current: Math.min(\n 100,\n 60 +\n Math.round(\n (employees.filter((employee) => employee.status === 'active').length /\n Math.max(employees.length, 1)) *\n 30\n )\n ),\n target: 80,\n unit: '%',\n },\n ],\n [candidates, employees]\n );\n\n const upcomingInterviews = interviews.filter((i) => i.status === 'scheduled');\n const pendingLeaves = leaveRequests.filter((l) => l.status === 'pending');\n const unreadNotifs = notifications.filter((n) => !n.read);\n const pinnedAnnouncements = announcements.filter((a) => a.isPinned);\n const topPerformers = [...employees]\n .sort((a, b) => b.performanceScore - a.performanceScore)\n .slice(0, 5);\n const recentHires = [...employees]\n .sort((a, b) => b.startDate.localeCompare(a.startDate))\n .slice(0, 5);\n\n const locationMap = employees.reduce<Record<string, number>>((acc, e) => {\n acc[e.location] = (acc[e.location] || 0) + 1;\n return acc;\n }, {});\n\n return (\n <div className=\"space-y-6 p-6\">\n <div className=\"flex items-center justify-between\">\n <div>\n <h1 className=\"text-2xl font-semibold\">\n <GradientText>Enhanced Dashboard</GradientText>\n </h1>\n <p className=\"text-sm text-text-secondary\">Complete workforce command center</p>\n </div>\n <div className=\"flex items-center gap-3\">\n <div className=\"relative\">\n <Bell className=\"h-5 w-5 text-text-secondary\" />\n {unreadNotifs.length > 0 && (\n <span className=\"absolute -top-1 -right-1 h-4 w-4 rounded-full bg-status-error-text text-[10px] text-white flex items-center justify-center\">\n {unreadNotifs.length}\n </span>\n )}\n </div>\n <Button size=\"sm\">\n <Zap className=\"h-4 w-4 mr-1\" />\n Quick Actions\n </Button>\n </div>\n </div>\n\n <div className=\"grid gap-3 md:grid-cols-4\">\n {quickActions.map((action) => (\n <Card key={action.label} className=\"cursor-pointer hover:shadow-md transition-shadow\">\n <CardContent className=\"flex items-center gap-3 p-4\">\n <action.icon className={`h-5 w-5 ${action.color}`} />\n <span className=\"text-sm font-medium\">{action.label}</span>\n <ArrowUpRight className=\"h-4 w-4 ml-auto text-text-secondary\" />\n </CardContent>\n </Card>\n ))}\n </div>\n\n {pinnedAnnouncements.length > 0 && (\n <Card className=\"border-status-warning-text/30 bg-status-warning-bg/50\">\n <CardContent className=\"p-4\">\n {pinnedAnnouncements.map((ann) => (\n <div key={ann.id} className=\"flex items-start gap-3\">\n <AlertTriangle className=\"h-4 w-4 text-status-warning-text mt-0.5\" />\n <div>\n <p className=\"text-sm font-medium\">{ann.title}</p>\n <p className=\"text-xs text-text-secondary mt-1\">{ann.content.slice(0, 120)}...</p>\n <p className=\"text-xs text-text-secondary mt-1\">\n — {ann.author}, {ann.authorRole}\n </p>\n </div>\n <Badge variant=\"outline\" className=\"ml-auto flex-shrink-0\">\n {ann.priority}\n </Badge>\n </div>\n ))}\n </CardContent>\n </Card>\n )}\n\n <div className=\"grid gap-4 md:grid-cols-3\">\n <Card>\n <CardHeader>\n <CardTitle className=\"text-base\">Company Goals</CardTitle>\n <CardDescription>Q1 2026 targets</CardDescription>\n </CardHeader>\n <CardContent className=\"space-y-4\">\n {companyGoals.map((g) => {\n const pct = Math.round((g.current / g.target) * 100);\n return (\n <div key={g.goal} className=\"space-y-1\">\n <div className=\"flex justify-between text-xs\">\n <span className=\"text-text-secondary\">{g.goal}</span>\n <span className=\"font-medium\">\n {g.current}/{g.target} {g.unit}\n </span>\n </div>\n <div className=\"h-2 bg-bg-sunken rounded overflow-hidden\">\n <div\n className={`h-2 rounded ${pct >= 90 ? 'bg-status-success-text' : pct >= 70 ? 'bg-status-warning-text' : 'bg-status-error-text'}`}\n style={{ width: `${Math.min(pct, 100)}%` }}\n />\n </div>\n </div>\n );\n })}\n </CardContent>\n </Card>\n\n <Card>\n <CardHeader>\n <CardTitle className=\"text-base\">Upcoming Interviews</CardTitle>\n <CardDescription>{upcomingInterviews.length} scheduled</CardDescription>\n </CardHeader>\n <CardContent className=\"space-y-3\">\n {upcomingInterviews.map((interview) => (\n <div key={interview.id} className=\"flex items-center gap-3 rounded border p-2\">\n <div className=\"flex-1 min-w-0\">\n <p className=\"text-sm font-medium truncate\">{interview.candidateName}</p>\n <p className=\"text-xs text-text-secondary\">{interview.position}</p>\n </div>\n <div className=\"text-right flex-shrink-0\">\n <p className=\"text-xs font-medium\">{interview.date}</p>\n <p className=\"text-xs text-text-secondary\">{interview.time}</p>\n </div>\n <Badge variant=\"outline\" className=\"text-[10px]\">\n {interview.type}\n </Badge>\n </div>\n ))}\n </CardContent>\n </Card>\n\n <Card>\n <CardHeader>\n <CardTitle className=\"text-base\">Pending Actions</CardTitle>\n <CardDescription>Items requiring your attention</CardDescription>\n </CardHeader>\n <CardContent className=\"space-y-3\">\n {pendingLeaves.map((leave) => (\n <div key={leave.id} className=\"flex items-center justify-between rounded border p-2\">\n <div>\n <p className=\"text-sm font-medium\">{leave.employeeName}</p>\n <p className=\"text-xs text-text-secondary\">\n {leave.type} leave · {leave.days} days\n </p>\n </div>\n <div className=\"flex gap-1\">\n <Button size=\"sm\" variant=\"outline\" className=\"h-7 text-xs\">\n Deny\n </Button>\n <Button size=\"sm\" className=\"h-7 text-xs\">\n Approve\n </Button>\n </div>\n </div>\n ))}\n <Separator />\n <div className=\"text-xs text-text-secondary text-center\">\n {candidates.filter((c) => c.status === 'new').length} new applications to review\n </div>\n </CardContent>\n </Card>\n </div>\n\n <div className=\"grid gap-4 md:grid-cols-2\">\n <Card>\n <CardHeader>\n <CardTitle className=\"text-base flex items-center gap-2\">\n <Award className=\"h-4 w-4 text-status-warning-text\" />\n Top Performers\n </CardTitle>\n </CardHeader>\n <CardContent className=\"space-y-3\">\n {topPerformers.map((emp, idx) => (\n <div key={emp.id} className=\"flex items-center gap-3\">\n <span className=\"text-sm font-bold text-text-secondary w-5\">#{idx + 1}</span>\n <div className=\"flex-1\">\n <p className=\"text-sm font-medium\">\n {emp.firstName} {emp.lastName}\n </p>\n <p className=\"text-xs text-text-secondary\">\n {emp.position} · {emp.department}\n </p>\n </div>\n <div className=\"flex items-center gap-1\">\n <Star className=\"h-3 w-3 text-status-warning-text\" />\n <span className=\"text-sm font-medium\">{emp.performanceScore}</span>\n </div>\n </div>\n ))}\n </CardContent>\n </Card>\n\n <Card>\n <CardHeader>\n <CardTitle className=\"text-base flex items-center gap-2\">\n <MapPin className=\"h-4 w-4\" />\n Workforce Locations\n </CardTitle>\n </CardHeader>\n <CardContent className=\"space-y-3\">\n {Object.entries(locationMap)\n .sort(([, a], [, b]) => b - a)\n .map(([location, count]) => (\n <div key={location} className=\"flex items-center justify-between\">\n <span className=\"text-sm\">{location}</span>\n <div className=\"flex items-center gap-2\">\n <span className=\"text-sm font-medium\">{count}</span>\n <span className=\"text-xs text-text-secondary\">\n ({Math.round((count / employees.length) * 100)}%)\n </span>\n </div>\n </div>\n ))}\n </CardContent>\n </Card>\n </div>\n\n <Card>\n <CardHeader>\n <CardTitle>Recent Hires</CardTitle>\n <CardDescription>Newest team members</CardDescription>\n </CardHeader>\n <CardContent>\n <div className=\"grid grid-cols-6 gap-2 text-xs font-medium text-text-secondary border-b pb-2 mb-2\">\n <span>Name</span>\n <span>Position</span>\n <span>Department</span>\n <span>Location</span>\n <span>Start Date</span>\n <span>Type</span>\n </div>\n {recentHires.map((emp) => (\n <div\n key={emp.id}\n className=\"grid grid-cols-6 gap-2 py-2 border-b last:border-0 text-sm\"\n >\n <span className=\"font-medium\">\n {emp.firstName} {emp.lastName}\n </span>\n <span className=\"text-text-secondary truncate\">{emp.position}</span>\n <span>{emp.department}</span>\n <span className=\"text-text-secondary truncate\">{emp.location}</span>\n <span>{emp.startDate}</span>\n <Badge variant=\"outline\" className=\"w-fit text-[10px]\">\n {emp.type.replace('_', ' ')}\n </Badge>\n </div>\n ))}\n </CardContent>\n </Card>\n </div>\n );\n}\n"],"mappings":";;;;;;AA0BA,SAAgB,IAAqC;CACnD,IAAM,E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,CAAA;KACvB,kBAAC,QAAD,EAAA,UAAM,QAAW,CAAA;KACb;OACL,EAAY,KAAK,MAChB,kBAAC,OAAD;IAEE,WAAU;cAFZ;KAIE,kBAAC,QAAD;MAAM,WAAU;gBAAhB;OACG,EAAI;OAAU;OAAE,EAAI;OAChB;;KACP,kBAAC,QAAD;MAAM,WAAU;gBAAgC,EAAI;MAAgB,CAAA;KACpE,kBAAC,QAAD,EAAA,UAAO,EAAI,YAAkB,CAAA;KAC7B,kBAAC,QAAD;MAAM,WAAU;gBAAgC,EAAI;MAAgB,CAAA;KACpE,kBAAC,QAAD,EAAA,UAAO,EAAI,WAAiB,CAAA;KAC5B,kBAAC,GAAD;MAAO,SAAQ;MAAU,WAAU;gBAChC,EAAI,KAAK,QAAQ,KAAK,IAAI;MACrB,CAAA;KACJ;MAbC,EAAI,GAaL,CACN,CACU,EAAA,CAAA,CACT,EAAA,CAAA;GACH"}
|
|
1
|
+
{"version":3,"file":"DashboardEnhancedDashboardPagePage.js","names":[],"sources":["../../../src/crewfoundry/pages/DashboardEnhancedDashboardPagePage.tsx"],"sourcesContent":["import { useMemo } from 'react';\nimport {\n Badge,\n Button,\n Card,\n CardContent,\n CardDescription,\n CardHeader,\n CardTitle,\n EmphasisPanel,\n GradientText,\n NextSteps,\n PagePurpose,\n Separator,\n} from '@burdenoff/fe-libs/ui';\nimport {\n AlertTriangle,\n ArrowUpRight,\n Award,\n Bell,\n Briefcase,\n CheckCircle,\n MapPin,\n Star,\n Users,\n Zap,\n} from 'lucide-react';\nimport { useNavigate } from 'react-router-dom';\nimport { useCrewFoundryStore } from '../store/crewfoundryStore';\n\nexport function DashboardEnhancedDashboardPagePage() {\n const navigate = useNavigate();\n const {\n employees,\n jobPostings,\n candidates,\n interviews,\n leaveRequests,\n notifications,\n projects,\n announcements,\n } = useCrewFoundryStore();\n\n const quickActions = useMemo(\n () => [\n {\n label: `Post New Job (${jobPostings.filter((job) => job.status === 'active').length} active)`,\n icon: Briefcase,\n color: 'text-status-info-text',\n },\n {\n label: `Review Candidates (${candidates.filter((candidate) => candidate.status === 'new').length})`,\n icon: Users,\n color: 'text-action-primary-bg',\n },\n {\n label: `Approve Leaves (${leaveRequests.filter((leave) => leave.status === 'pending').length})`,\n icon: CheckCircle,\n color: 'text-status-success-text',\n },\n {\n label: `Run Payroll (${projects.filter((project) => project.status === 'active').length} projects)`,\n icon: Zap,\n color: 'text-status-warning-text',\n },\n ],\n [candidates, jobPostings, leaveRequests, projects]\n );\n\n const companyGoals = useMemo(\n () => [\n {\n goal: 'Reduce time-to-hire to 25 days',\n current: Math.max(\n 20,\n 40 - candidates.filter((candidate) => candidate.status === 'hired').length\n ),\n target: 25,\n unit: 'days',\n },\n {\n goal: 'Achieve 95% employee satisfaction',\n current: Math.round(\n (employees.reduce((sum, employee) => sum + employee.performanceScore, 0) /\n Math.max(employees.length, 1)) *\n 20\n ),\n target: 95,\n unit: '%',\n },\n {\n goal: 'Fill 30 open positions by Q2',\n current: candidates.filter((candidate) => candidate.status === 'hired').length,\n target: 30,\n unit: 'positions',\n },\n {\n goal: 'Complete 80% training compliance',\n current: Math.min(\n 100,\n 60 +\n Math.round(\n (employees.filter((employee) => employee.status === 'active').length /\n Math.max(employees.length, 1)) *\n 30\n )\n ),\n target: 80,\n unit: '%',\n },\n ],\n [candidates, employees]\n );\n\n const upcomingInterviews = interviews.filter((i) => i.status === 'scheduled');\n const pendingLeaves = leaveRequests.filter((l) => l.status === 'pending');\n const unreadNotifs = notifications.filter((n) => !n.read);\n const pinnedAnnouncements = announcements.filter((a) => a.isPinned);\n const topPerformers = [...employees]\n .sort((a, b) => b.performanceScore - a.performanceScore)\n .slice(0, 5);\n const recentHires = [...employees]\n .sort((a, b) => b.startDate.localeCompare(a.startDate))\n .slice(0, 5);\n\n const locationMap = employees.reduce<Record<string, number>>((acc, e) => {\n acc[e.location] = (acc[e.location] || 0) + 1;\n return acc;\n }, {});\n\n return (\n <div className=\"space-y-6 p-6\">\n <div className=\"flex items-center justify-between\">\n <div>\n <h1 className=\"text-2xl font-semibold\">\n <GradientText>Enhanced Dashboard</GradientText>\n </h1>\n <p className=\"text-sm text-text-secondary\">Complete workforce command center</p>\n <PagePurpose className=\"mt-1\">A richer, customizable command center for your workforce — see live metrics, activity, and trends tailored to how you run your organization.</PagePurpose>\n </div>\n <div className=\"flex items-center gap-3\">\n <div className=\"relative\">\n <Bell className=\"h-5 w-5 text-text-secondary\" />\n {unreadNotifs.length > 0 && (\n <span className=\"absolute -top-1 -right-1 h-4 w-4 rounded-full bg-status-error-text text-[10px] text-white flex items-center justify-center\">\n {unreadNotifs.length}\n </span>\n )}\n </div>\n <Button size=\"sm\">\n <Zap className=\"h-4 w-4 mr-1\" />\n Quick Actions\n </Button>\n </div>\n </div>\n\n <NextSteps\n storageKey=\"crewfoundry-enhanced-dashboard\"\n steps={[\n {\n id: 'hiring',\n label: 'Move hiring forward',\n description: 'Review open roles and applicants in your pipeline.',\n icon: <Briefcase className=\"h-4 w-4\" />,\n onClick: () => navigate('../../hiring/jobs-page'),\n },\n {\n id: 'people',\n label: 'Check on your people',\n description: 'See who is active, on leave, or needs attention.',\n icon: <Users className=\"h-4 w-4\" />,\n onClick: () => navigate('../../hr/employees-page'),\n },\n {\n id: 'analytics',\n label: 'Dig into analytics',\n description: 'Explore deeper workforce and hiring trends.',\n icon: <ArrowUpRight className=\"h-4 w-4\" />,\n onClick: () => navigate('../../analytics/analytics-page'),\n },\n ]}\n />\n\n <div className=\"grid gap-3 md:grid-cols-4\">\n {quickActions.map((action) => (\n <Card key={action.label} className=\"cursor-pointer hover:shadow-md transition-shadow\">\n <CardContent className=\"flex items-center gap-3 p-4\">\n <action.icon className={`h-5 w-5 ${action.color}`} />\n <span className=\"text-sm font-medium\">{action.label}</span>\n <ArrowUpRight className=\"h-4 w-4 ml-auto text-text-secondary\" />\n </CardContent>\n </Card>\n ))}\n </div>\n\n {pinnedAnnouncements.length > 0 && (\n <Card className=\"border-status-warning-text/30 bg-status-warning-bg/50\">\n <CardContent className=\"p-4\">\n {pinnedAnnouncements.map((ann) => (\n <div key={ann.id} className=\"flex items-start gap-3\">\n <AlertTriangle className=\"h-4 w-4 text-status-warning-text mt-0.5\" />\n <div>\n <p className=\"text-sm font-medium\">{ann.title}</p>\n <p className=\"text-xs text-text-secondary mt-1\">{ann.content.slice(0, 120)}...</p>\n <p className=\"text-xs text-text-secondary mt-1\">\n — {ann.author}, {ann.authorRole}\n </p>\n </div>\n <Badge variant=\"outline\" className=\"ml-auto flex-shrink-0\">\n {ann.priority}\n </Badge>\n </div>\n ))}\n </CardContent>\n </Card>\n )}\n\n <div className=\"grid gap-4 md:grid-cols-3\">\n <EmphasisPanel>\n <div className=\"text-base font-semibold\">Company Goals</div>\n <p className=\"mb-4 text-sm text-text-secondary\">Q1 2026 targets</p>\n <div className=\"space-y-4\">\n {companyGoals.map((g) => {\n const pct = Math.round((g.current / g.target) * 100);\n return (\n <div key={g.goal} className=\"space-y-1\">\n <div className=\"flex justify-between text-xs\">\n <span className=\"text-text-secondary\">{g.goal}</span>\n <span className=\"font-medium\">\n {g.current}/{g.target} {g.unit}\n </span>\n </div>\n <div className=\"h-2 bg-bg-sunken rounded overflow-hidden\">\n <div\n className={`h-2 rounded ${pct >= 90 ? 'bg-status-success-text' : pct >= 70 ? 'bg-status-warning-text' : 'bg-status-error-text'}`}\n style={{ width: `${Math.min(pct, 100)}%` }}\n />\n </div>\n </div>\n );\n })}\n </div>\n </EmphasisPanel>\n\n <Card>\n <CardHeader>\n <CardTitle className=\"text-base\">Upcoming Interviews</CardTitle>\n <CardDescription>{upcomingInterviews.length} scheduled</CardDescription>\n </CardHeader>\n <CardContent className=\"space-y-3\">\n {upcomingInterviews.map((interview) => (\n <div key={interview.id} className=\"flex items-center gap-3 rounded border p-2\">\n <div className=\"flex-1 min-w-0\">\n <p className=\"text-sm font-medium truncate\">{interview.candidateName}</p>\n <p className=\"text-xs text-text-secondary\">{interview.position}</p>\n </div>\n <div className=\"text-right flex-shrink-0\">\n <p className=\"text-xs font-medium\">{interview.date}</p>\n <p className=\"text-xs text-text-secondary\">{interview.time}</p>\n </div>\n <Badge variant=\"outline\" className=\"text-[10px]\">\n {interview.type}\n </Badge>\n </div>\n ))}\n </CardContent>\n </Card>\n\n <Card>\n <CardHeader>\n <CardTitle className=\"text-base\">Pending Actions</CardTitle>\n <CardDescription>Items requiring your attention</CardDescription>\n </CardHeader>\n <CardContent className=\"space-y-3\">\n {pendingLeaves.map((leave) => (\n <div key={leave.id} className=\"flex items-center justify-between rounded border p-2\">\n <div>\n <p className=\"text-sm font-medium\">{leave.employeeName}</p>\n <p className=\"text-xs text-text-secondary\">\n {leave.type} leave · {leave.days} days\n </p>\n </div>\n <div className=\"flex gap-1\">\n <Button size=\"sm\" variant=\"outline\" className=\"h-7 text-xs\">\n Deny\n </Button>\n <Button size=\"sm\" className=\"h-7 text-xs\">\n Approve\n </Button>\n </div>\n </div>\n ))}\n <Separator />\n <div className=\"text-xs text-text-secondary text-center\">\n {candidates.filter((c) => c.status === 'new').length} new applications to review\n </div>\n </CardContent>\n </Card>\n </div>\n\n <div className=\"grid gap-4 md:grid-cols-2\">\n <Card>\n <CardHeader>\n <CardTitle className=\"text-base flex items-center gap-2\">\n <Award className=\"h-4 w-4 text-status-warning-text\" />\n Top Performers\n </CardTitle>\n </CardHeader>\n <CardContent className=\"space-y-3\">\n {topPerformers.map((emp, idx) => (\n <div key={emp.id} className=\"flex items-center gap-3\">\n <span className=\"text-sm font-bold text-text-secondary w-5\">#{idx + 1}</span>\n <div className=\"flex-1\">\n <p className=\"text-sm font-medium\">\n {emp.firstName} {emp.lastName}\n </p>\n <p className=\"text-xs text-text-secondary\">\n {emp.position} · {emp.department}\n </p>\n </div>\n <div className=\"flex items-center gap-1\">\n <Star className=\"h-3 w-3 text-status-warning-text\" />\n <span className=\"text-sm font-medium\">{emp.performanceScore}</span>\n </div>\n </div>\n ))}\n </CardContent>\n </Card>\n\n <Card>\n <CardHeader>\n <CardTitle className=\"text-base flex items-center gap-2\">\n <MapPin className=\"h-4 w-4\" />\n Workforce Locations\n </CardTitle>\n </CardHeader>\n <CardContent className=\"space-y-3\">\n {Object.entries(locationMap)\n .sort(([, a], [, b]) => b - a)\n .map(([location, count]) => (\n <div key={location} className=\"flex items-center justify-between\">\n <span className=\"text-sm\">{location}</span>\n <div className=\"flex items-center gap-2\">\n <span className=\"text-sm font-medium\">{count}</span>\n <span className=\"text-xs text-text-secondary\">\n ({Math.round((count / employees.length) * 100)}%)\n </span>\n </div>\n </div>\n ))}\n </CardContent>\n </Card>\n </div>\n\n <Card>\n <CardHeader>\n <CardTitle>Recent Hires</CardTitle>\n <CardDescription>Newest team members</CardDescription>\n </CardHeader>\n <CardContent>\n <div className=\"grid grid-cols-6 gap-2 text-xs font-medium text-text-secondary border-b pb-2 mb-2\">\n <span>Name</span>\n <span>Position</span>\n <span>Department</span>\n <span>Location</span>\n <span>Start Date</span>\n <span>Type</span>\n </div>\n {recentHires.map((emp) => (\n <div\n key={emp.id}\n className=\"grid grid-cols-6 gap-2 py-2 border-b last:border-0 text-sm\"\n >\n <span className=\"font-medium\">\n {emp.firstName} {emp.lastName}\n </span>\n <span className=\"text-text-secondary truncate\">{emp.position}</span>\n <span>{emp.department}</span>\n <span className=\"text-text-secondary truncate\">{emp.location}</span>\n <span>{emp.startDate}</span>\n <Badge variant=\"outline\" className=\"w-fit text-[10px]\">\n {emp.type.replace('_', ' ')}\n </Badge>\n </div>\n ))}\n </CardContent>\n </Card>\n </div>\n );\n}\n"],"mappings":";;;;;;;AA8BA,SAAgB,IAAqC;CACnD,IAAM,IAAW,GAAa,EACxB,EACJ,cACA,gBACA,eACA,eACA,kBACA,kBACA,aACA,qBACE,GAAqB,EAEnB,IAAe,QACb;EACJ;GACE,OAAO,iBAAiB,EAAY,QAAQ,MAAQ,EAAI,WAAW,SAAS,CAAC,OAAO;GACpF,MAAM;GACN,OAAO;GACR;EACD;GACE,OAAO,sBAAsB,EAAW,QAAQ,MAAc,EAAU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,kBAAC,QAAD,EAAA,UAAM,QAAW,CAAA;KACjB,kBAAC,QAAD,EAAA,UAAM,YAAe,CAAA;KACrB,kBAAC,QAAD,EAAA,UAAM,cAAiB,CAAA;KACvB,kBAAC,QAAD,EAAA,UAAM,YAAe,CAAA;KACrB,kBAAC,QAAD,EAAA,UAAM,cAAiB,CAAA;KACvB,kBAAC,QAAD,EAAA,UAAM,QAAW,CAAA;KACb;OACL,EAAY,KAAK,MAChB,kBAAC,OAAD;IAEE,WAAU;cAFZ;KAIE,kBAAC,QAAD;MAAM,WAAU;gBAAhB;OACG,EAAI;OAAU;OAAE,EAAI;OAChB;;KACP,kBAAC,QAAD;MAAM,WAAU;gBAAgC,EAAI;MAAgB,CAAA;KACpE,kBAAC,QAAD,EAAA,UAAO,EAAI,YAAkB,CAAA;KAC7B,kBAAC,QAAD;MAAM,WAAU;gBAAgC,EAAI;MAAgB,CAAA;KACpE,kBAAC,QAAD,EAAA,UAAO,EAAI,WAAiB,CAAA;KAC5B,kBAAC,GAAD;MAAO,SAAQ;MAAU,WAAU;gBAChC,EAAI,KAAK,QAAQ,KAAK,IAAI;MACrB,CAAA;KACJ;MAbC,EAAI,GAaL,CACN,CACU,EAAA,CAAA,CACT,EAAA,CAAA;GACH"}
|
|
@@ -2,18 +2,18 @@ import { useCrewFoundryStore as e } from "../store/crewfoundryStore.js";
|
|
|
2
2
|
import { useMemo as t } from "react";
|
|
3
3
|
import { ArrowUp as n, Building2 as r, DollarSign as i, Percent as a, Target as o } from "lucide-react";
|
|
4
4
|
import { jsx as s, jsxs as c } from "react/jsx-runtime";
|
|
5
|
-
import { Badge as l, Card as u, CardContent as d, CardDescription as f, CardHeader as p, CardTitle as m, GlassCard as h, GradientText as g,
|
|
5
|
+
import { Badge as l, Card as u, CardContent as d, CardDescription as f, CardHeader as p, CardTitle as m, GlassCard as h, GradientText as g, PagePurpose as _, Separator as v } from "@burdenoff/fe-libs/ui";
|
|
6
6
|
//#region src/crewfoundry/pages/DashboardExecutiveDashboardPage.tsx
|
|
7
|
-
function
|
|
8
|
-
let { employees:
|
|
7
|
+
function y() {
|
|
8
|
+
let { employees: y, departments: b, projects: x, jobPostings: S } = e(), C = t(() => {
|
|
9
9
|
let e = [
|
|
10
10
|
"Q1 2025",
|
|
11
11
|
"Q2 2025",
|
|
12
12
|
"Q3 2025",
|
|
13
13
|
"Q4 2025"
|
|
14
|
-
], t =
|
|
14
|
+
], t = x.reduce((e, t) => e + t.budget, 0) || 1e6;
|
|
15
15
|
return e.map((e, n) => {
|
|
16
|
-
let r = Math.round(t * (.55 + n * .08)), i = Math.max(1,
|
|
16
|
+
let r = Math.round(t * (.55 + n * .08)), i = Math.max(1, y.length - (3 - n) * 4);
|
|
17
17
|
return {
|
|
18
18
|
quarter: e,
|
|
19
19
|
revenue: r,
|
|
@@ -21,57 +21,64 @@ function v() {
|
|
|
21
21
|
revenuePerHead: Math.round(r / i)
|
|
22
22
|
};
|
|
23
23
|
});
|
|
24
|
-
}, [
|
|
24
|
+
}, [y.length, x]), w = t(() => [
|
|
25
25
|
{
|
|
26
26
|
metric: "Flight Risk Employees",
|
|
27
|
-
value:
|
|
27
|
+
value: y.filter((e) => e.performanceScore < 3.6).length,
|
|
28
28
|
severity: "warning",
|
|
29
|
-
detail: `${Math.round(
|
|
29
|
+
detail: `${Math.round(y.filter((e) => e.performanceScore < 3.6).length / Math.max(y.length, 1) * 100)}% of workforce`
|
|
30
30
|
},
|
|
31
31
|
{
|
|
32
32
|
metric: "Overdue Performance Reviews",
|
|
33
|
-
value:
|
|
33
|
+
value: y.filter((e) => e.status === "on_leave").length,
|
|
34
34
|
severity: "error",
|
|
35
35
|
detail: "Review follow-ups required"
|
|
36
36
|
},
|
|
37
37
|
{
|
|
38
38
|
metric: "Unfilled Critical Roles",
|
|
39
|
-
value:
|
|
39
|
+
value: S.filter((e) => e.status === "active" && e.experienceLevel === "lead").length,
|
|
40
40
|
severity: "warning",
|
|
41
41
|
detail: "Open lead-level positions"
|
|
42
42
|
},
|
|
43
43
|
{
|
|
44
44
|
metric: "Expiring Contracts",
|
|
45
|
-
value:
|
|
45
|
+
value: y.filter((e) => e.type === "contract").length,
|
|
46
46
|
severity: "info",
|
|
47
47
|
detail: "Contract renewals in focus"
|
|
48
48
|
}
|
|
49
|
-
], [
|
|
49
|
+
], [y, S]), T = t(() => [{
|
|
50
50
|
category: "Company",
|
|
51
51
|
male: 52,
|
|
52
52
|
female: 43,
|
|
53
53
|
other: 5
|
|
54
|
-
}, ...
|
|
55
|
-
let t =
|
|
54
|
+
}, ...b.map((e) => {
|
|
55
|
+
let t = y.filter((t) => t.department === e.name).length, n = Math.min(100, Math.round(45 + t % 15)), r = Math.min(100 - n, Math.round(40 + t % 10)), i = Math.max(0, 100 - n - r);
|
|
56
56
|
return {
|
|
57
57
|
category: e.name,
|
|
58
58
|
male: n,
|
|
59
59
|
female: r,
|
|
60
60
|
other: i
|
|
61
61
|
};
|
|
62
|
-
}).slice(0, 3)], [
|
|
62
|
+
}).slice(0, 3)], [b, y]), E = y.reduce((e, t) => e + t.salary, 0), D = b.reduce((e, t) => e + t.budget, 0), O = x.reduce((e, t) => e + t.budget, 0), k = x.reduce((e, t) => e + t.spent, 0), A = Math.round(k / O * 100);
|
|
63
63
|
return /* @__PURE__ */ c("div", {
|
|
64
64
|
className: "space-y-6 p-6",
|
|
65
65
|
children: [
|
|
66
66
|
/* @__PURE__ */ c("div", {
|
|
67
67
|
className: "flex items-center justify-between",
|
|
68
|
-
children: [/* @__PURE__ */ c("div", { children: [
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
68
|
+
children: [/* @__PURE__ */ c("div", { children: [
|
|
69
|
+
/* @__PURE__ */ s("h1", {
|
|
70
|
+
className: "text-2xl font-semibold",
|
|
71
|
+
children: /* @__PURE__ */ s(g, { children: "Executive Dashboard" })
|
|
72
|
+
}),
|
|
73
|
+
/* @__PURE__ */ s("p", {
|
|
74
|
+
className: "text-sm text-text-secondary",
|
|
75
|
+
children: "Strategic workforce insights for leadership"
|
|
76
|
+
}),
|
|
77
|
+
/* @__PURE__ */ s(_, {
|
|
78
|
+
className: "mt-1",
|
|
79
|
+
children: "The executive snapshot — top-line workforce, financial, and hiring KPIs in one view so leaders can make decisions fast."
|
|
80
|
+
})
|
|
81
|
+
] }), /* @__PURE__ */ s(l, {
|
|
75
82
|
variant: "outline",
|
|
76
83
|
children: "Q1 2026"
|
|
77
84
|
})]
|
|
@@ -80,7 +87,8 @@ function v() {
|
|
|
80
87
|
className: "grid gap-4 md:grid-cols-2 lg:grid-cols-4",
|
|
81
88
|
children: [
|
|
82
89
|
/* @__PURE__ */ c(h, {
|
|
83
|
-
treatment: "
|
|
90
|
+
treatment: "glass",
|
|
91
|
+
glow: !0,
|
|
84
92
|
className: "border-border-seam",
|
|
85
93
|
children: [/* @__PURE__ */ c(p, {
|
|
86
94
|
className: "flex flex-row items-center justify-between space-y-0 pb-2",
|
|
@@ -109,7 +117,7 @@ function v() {
|
|
|
109
117
|
className: "text-2xl font-bold tabular-nums",
|
|
110
118
|
children: [
|
|
111
119
|
"$",
|
|
112
|
-
(
|
|
120
|
+
(E / 1e6).toFixed(1),
|
|
113
121
|
"M"
|
|
114
122
|
]
|
|
115
123
|
}), /* @__PURE__ */ s("p", {
|
|
@@ -128,14 +136,14 @@ function v() {
|
|
|
128
136
|
}), /* @__PURE__ */ s(a, { className: "h-4 w-4 text-text-secondary" })]
|
|
129
137
|
}), /* @__PURE__ */ c(d, { children: [/* @__PURE__ */ c("div", {
|
|
130
138
|
className: "text-2xl font-bold tabular-nums",
|
|
131
|
-
children: [
|
|
139
|
+
children: [A, "%"]
|
|
132
140
|
}), /* @__PURE__ */ c("p", {
|
|
133
141
|
className: "text-xs text-text-secondary",
|
|
134
142
|
children: [
|
|
135
143
|
"$",
|
|
136
|
-
(
|
|
144
|
+
(k / 1e6).toFixed(1),
|
|
137
145
|
"M of $",
|
|
138
|
-
(
|
|
146
|
+
(O / 1e6).toFixed(1),
|
|
139
147
|
"M"
|
|
140
148
|
]
|
|
141
149
|
})] })]
|
|
@@ -178,7 +186,7 @@ function v() {
|
|
|
178
186
|
children: "Rev/Head"
|
|
179
187
|
})
|
|
180
188
|
]
|
|
181
|
-
}),
|
|
189
|
+
}), C.map((e) => /* @__PURE__ */ c("div", {
|
|
182
190
|
className: "grid grid-cols-4 gap-2 py-2 border-b last:border-0 text-sm",
|
|
183
191
|
children: [
|
|
184
192
|
/* @__PURE__ */ s("span", {
|
|
@@ -204,7 +212,7 @@ function v() {
|
|
|
204
212
|
]
|
|
205
213
|
}, e.quarter))] })] }), /* @__PURE__ */ c(u, { children: [/* @__PURE__ */ c(p, { children: [/* @__PURE__ */ s(m, { children: "Risk Indicators" }), /* @__PURE__ */ s(f, { children: "Items requiring executive attention" })] }), /* @__PURE__ */ s(d, {
|
|
206
214
|
className: "space-y-3",
|
|
207
|
-
children:
|
|
215
|
+
children: w.map((e) => /* @__PURE__ */ c("div", {
|
|
208
216
|
className: "flex items-center justify-between rounded border p-3",
|
|
209
217
|
children: [/* @__PURE__ */ c("div", {
|
|
210
218
|
className: "flex items-center gap-3",
|
|
@@ -224,7 +232,7 @@ function v() {
|
|
|
224
232
|
}),
|
|
225
233
|
/* @__PURE__ */ c(u, { children: [/* @__PURE__ */ c(p, { children: [/* @__PURE__ */ s(m, { children: "Diversity & Inclusion Metrics" }), /* @__PURE__ */ s(f, { children: "Gender distribution across organization segments" })] }), /* @__PURE__ */ s(d, { children: /* @__PURE__ */ s("div", {
|
|
226
234
|
className: "space-y-4",
|
|
227
|
-
children:
|
|
235
|
+
children: T.map((e) => /* @__PURE__ */ c("div", {
|
|
228
236
|
className: "space-y-1",
|
|
229
237
|
children: [/* @__PURE__ */ c("div", {
|
|
230
238
|
className: "flex justify-between text-sm",
|
|
@@ -282,7 +290,7 @@ function v() {
|
|
|
282
290
|
})
|
|
283
291
|
]
|
|
284
292
|
}),
|
|
285
|
-
|
|
293
|
+
b.map((e) => {
|
|
286
294
|
let t = e.employeeCount > 0 ? Math.round(e.budget / e.employeeCount) : 0;
|
|
287
295
|
return /* @__PURE__ */ c("div", {
|
|
288
296
|
className: "grid grid-cols-5 gap-2 py-2 border-b last:border-0 text-sm",
|
|
@@ -318,7 +326,7 @@ function v() {
|
|
|
318
326
|
]
|
|
319
327
|
}, e.id);
|
|
320
328
|
}),
|
|
321
|
-
/* @__PURE__ */ s(
|
|
329
|
+
/* @__PURE__ */ s(v, { className: "my-2" }),
|
|
322
330
|
/* @__PURE__ */ c("div", {
|
|
323
331
|
className: "grid grid-cols-5 gap-2 text-sm font-bold",
|
|
324
332
|
children: [
|
|
@@ -326,13 +334,13 @@ function v() {
|
|
|
326
334
|
/* @__PURE__ */ s("span", {}),
|
|
327
335
|
/* @__PURE__ */ s("span", {
|
|
328
336
|
className: "text-right",
|
|
329
|
-
children:
|
|
337
|
+
children: b.reduce((e, t) => e + t.employeeCount, 0)
|
|
330
338
|
}),
|
|
331
339
|
/* @__PURE__ */ c("span", {
|
|
332
340
|
className: "text-right",
|
|
333
341
|
children: [
|
|
334
342
|
"$",
|
|
335
|
-
(
|
|
343
|
+
(D / 1e6).toFixed(1),
|
|
336
344
|
"M"
|
|
337
345
|
]
|
|
338
346
|
}),
|
|
@@ -340,7 +348,7 @@ function v() {
|
|
|
340
348
|
className: "text-right",
|
|
341
349
|
children: [
|
|
342
350
|
"$",
|
|
343
|
-
(
|
|
351
|
+
(D / b.reduce((e, t) => e + t.employeeCount, 0) / 1e3).toFixed(0),
|
|
344
352
|
"K"
|
|
345
353
|
]
|
|
346
354
|
})
|
|
@@ -351,6 +359,6 @@ function v() {
|
|
|
351
359
|
});
|
|
352
360
|
}
|
|
353
361
|
//#endregion
|
|
354
|
-
export {
|
|
362
|
+
export { y as DashboardExecutiveDashboardPage };
|
|
355
363
|
|
|
356
364
|
//# sourceMappingURL=DashboardExecutiveDashboardPage.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DashboardExecutiveDashboardPage.js","names":[],"sources":["../../../src/crewfoundry/pages/DashboardExecutiveDashboardPage.tsx"],"sourcesContent":["import {\n Badge,\n Card,\n CardContent,\n CardDescription,\n CardHeader,\n CardTitle,\n GlassCard,\n GradientText,\n Separator,\n} from '@burdenoff/fe-libs/ui';\nimport { ArrowUp, Building2, DollarSign, Percent, Target } from 'lucide-react';\nimport { useMemo } from 'react';\nimport { useCrewFoundryStore } from '../store/crewfoundryStore';\n\nexport function DashboardExecutiveDashboardPage() {\n const { employees, departments, projects, jobPostings } = useCrewFoundryStore();\n\n const quarterlyRevenue = useMemo(() => {\n const quarters = ['Q1 2025', 'Q2 2025', 'Q3 2025', 'Q4 2025'];\n const base = projects.reduce((sum, project) => sum + project.budget, 0) || 1000000;\n return quarters.map((quarter, index) => {\n const revenue = Math.round(base * (0.55 + index * 0.08));\n const headcount = Math.max(1, employees.length - (3 - index) * 4);\n return {\n quarter,\n revenue,\n headcount,\n revenuePerHead: Math.round(revenue / headcount),\n };\n });\n }, [employees.length, projects]);\n\n const riskIndicators = useMemo(\n () => [\n {\n metric: 'Flight Risk Employees',\n value: employees.filter((employee) => employee.performanceScore < 3.6).length,\n severity: 'warning' as const,\n detail: `${Math.round((employees.filter((employee) => employee.performanceScore < 3.6).length / Math.max(employees.length, 1)) * 100)}% of workforce`,\n },\n {\n metric: 'Overdue Performance Reviews',\n value: employees.filter((employee) => employee.status === 'on_leave').length,\n severity: 'error' as const,\n detail: 'Review follow-ups required',\n },\n {\n metric: 'Unfilled Critical Roles',\n value: jobPostings.filter(\n (posting) => posting.status === 'active' && posting.experienceLevel === 'lead'\n ).length,\n severity: 'warning' as const,\n detail: 'Open lead-level positions',\n },\n {\n metric: 'Expiring Contracts',\n value: employees.filter((employee) => employee.type === 'contract').length,\n severity: 'info' as const,\n detail: 'Contract renewals in focus',\n },\n ],\n [employees, jobPostings]\n );\n\n const diversityMetrics = useMemo(() => {\n const byDepartment = departments.map((department) => {\n const count = employees.filter((employee) => employee.department === department.name).length;\n const male = Math.min(100, Math.round(45 + (count % 15)));\n const female = Math.min(100 - male, Math.round(40 + (count % 10)));\n const other = Math.max(0, 100 - male - female);\n return { category: department.name, male, female, other };\n });\n return [\n {\n category: 'Company',\n male: 52,\n female: 43,\n other: 5,\n },\n ...byDepartment.slice(0, 3),\n ];\n }, [departments, employees]);\n\n const totalSalaryBudget = employees.reduce((sum, e) => sum + e.salary, 0);\n const totalDeptBudget = departments.reduce((sum, d) => sum + d.budget, 0);\n const totalProjectBudget = projects.reduce((sum, p) => sum + p.budget, 0);\n const totalProjectSpent = projects.reduce((sum, p) => sum + p.spent, 0);\n const budgetUtilization = Math.round((totalProjectSpent / totalProjectBudget) * 100);\n\n return (\n <div className=\"space-y-6 p-6\">\n <div className=\"flex items-center justify-between\">\n <div>\n <h1 className=\"text-2xl font-semibold\">\n <GradientText>Executive Dashboard</GradientText>\n </h1>\n <p className=\"text-sm text-text-secondary\">Strategic workforce insights for leadership</p>\n </div>\n <Badge variant=\"outline\">Q1 2026</Badge>\n </div>\n\n <div className=\"grid gap-4 md:grid-cols-2 lg:grid-cols-4\">\n <GlassCard treatment=\"metric\" className=\"border-border-seam\">\n <CardHeader className=\"flex flex-row items-center justify-between space-y-0 pb-2\">\n <CardTitle className=\"text-sm font-medium\">Revenue per Employee</CardTitle>\n <DollarSign className=\"h-4 w-4 text-text-secondary\" />\n </CardHeader>\n <CardContent>\n <div className=\"text-2xl font-bold tabular-nums\">$21,862</div>\n <div className=\"flex items-center text-xs text-status-success-text\">\n <ArrowUp className=\"h-3 w-3 mr-1\" />\n +2.0% from Q3\n </div>\n </CardContent>\n </GlassCard>\n <GlassCard treatment=\"metric\" className=\"border-border-seam\">\n <CardHeader className=\"flex flex-row items-center justify-between space-y-0 pb-2\">\n <CardTitle className=\"text-sm font-medium\">Total Workforce Cost</CardTitle>\n <Building2 className=\"h-4 w-4 text-text-secondary\" />\n </CardHeader>\n <CardContent>\n <div className=\"text-2xl font-bold tabular-nums\">\n ${(totalSalaryBudget / 1000000).toFixed(1)}M\n </div>\n <p className=\"text-xs text-text-secondary\">Annual salary expenditure</p>\n </CardContent>\n </GlassCard>\n <GlassCard treatment=\"metric\" className=\"border-border-seam\">\n <CardHeader className=\"flex flex-row items-center justify-between space-y-0 pb-2\">\n <CardTitle className=\"text-sm font-medium\">Budget Utilization</CardTitle>\n <Percent className=\"h-4 w-4 text-text-secondary\" />\n </CardHeader>\n <CardContent>\n <div className=\"text-2xl font-bold tabular-nums\">{budgetUtilization}%</div>\n <p className=\"text-xs text-text-secondary\">\n ${(totalProjectSpent / 1000000).toFixed(1)}M of $\n {(totalProjectBudget / 1000000).toFixed(1)}M\n </p>\n </CardContent>\n </GlassCard>\n <GlassCard treatment=\"metric\" className=\"border-border-seam\">\n <CardHeader className=\"flex flex-row items-center justify-between space-y-0 pb-2\">\n <CardTitle className=\"text-sm font-medium\">Retention Rate</CardTitle>\n <Target className=\"h-4 w-4 text-text-secondary\" />\n </CardHeader>\n <CardContent>\n <div className=\"text-2xl font-bold tabular-nums\">95.8%</div>\n <div className=\"flex items-center text-xs text-status-success-text\">\n <ArrowUp className=\"h-3 w-3 mr-1\" />\n +1.1% improvement\n </div>\n </CardContent>\n </GlassCard>\n </div>\n\n <div className=\"grid gap-4 md:grid-cols-2\">\n <Card>\n <CardHeader>\n <CardTitle>Revenue & Headcount Trend</CardTitle>\n <CardDescription>Quarterly performance metrics</CardDescription>\n </CardHeader>\n <CardContent>\n <div className=\"grid grid-cols-4 gap-2 text-xs font-medium text-text-secondary border-b pb-2 mb-2\">\n <span>Quarter</span>\n <span className=\"text-right\">Revenue</span>\n <span className=\"text-right\">Headcount</span>\n <span className=\"text-right\">Rev/Head</span>\n </div>\n {quarterlyRevenue.map((q) => (\n <div\n key={q.quarter}\n className=\"grid grid-cols-4 gap-2 py-2 border-b last:border-0 text-sm\"\n >\n <span className=\"font-medium\">{q.quarter}</span>\n <span className=\"text-right\">${(q.revenue / 1000000).toFixed(1)}M</span>\n <span className=\"text-right\">{q.headcount}</span>\n <span className=\"text-right font-medium\">${q.revenuePerHead.toLocaleString()}</span>\n </div>\n ))}\n </CardContent>\n </Card>\n\n <Card>\n <CardHeader>\n <CardTitle>Risk Indicators</CardTitle>\n <CardDescription>Items requiring executive attention</CardDescription>\n </CardHeader>\n <CardContent className=\"space-y-3\">\n {riskIndicators.map((risk) => (\n <div\n key={risk.metric}\n className=\"flex items-center justify-between rounded border p-3\"\n >\n <div className=\"flex items-center gap-3\">\n <div\n className={`h-3 w-3 rounded-full ${\n risk.severity === 'error'\n ? 'bg-status-error-text'\n : risk.severity === 'warning'\n ? 'bg-status-warning-text'\n : 'bg-status-info-text'\n }`}\n />\n <div>\n <p className=\"text-sm font-medium\">{risk.metric}</p>\n <p className=\"text-xs text-text-secondary\">{risk.detail}</p>\n </div>\n </div>\n <span className=\"text-lg font-bold\">{risk.value}</span>\n </div>\n ))}\n </CardContent>\n </Card>\n </div>\n\n <Card>\n <CardHeader>\n <CardTitle>Diversity & Inclusion Metrics</CardTitle>\n <CardDescription>Gender distribution across organization segments</CardDescription>\n </CardHeader>\n <CardContent>\n <div className=\"space-y-4\">\n {diversityMetrics.map((d) => (\n <div key={d.category} className=\"space-y-1\">\n <div className=\"flex justify-between text-sm\">\n <span className=\"font-medium\">{d.category}</span>\n <span className=\"text-xs text-text-secondary\">\n M: {d.male}% · F: {d.female}% · Other: {d.other}%\n </span>\n </div>\n <div className=\"flex h-3 rounded overflow-hidden\">\n <div className=\"bg-status-info-text\" style={{ width: `${d.male}%` }} />\n <div className=\"bg-action-primary-bg\" style={{ width: `${d.female}%` }} />\n <div className=\"bg-status-success-text\" style={{ width: `${d.other}%` }} />\n </div>\n </div>\n ))}\n </div>\n </CardContent>\n </Card>\n\n <Card>\n <CardHeader>\n <CardTitle>Department Budget Status</CardTitle>\n <CardDescription>Annual budget allocation and headcount</CardDescription>\n </CardHeader>\n <CardContent>\n <div className=\"grid grid-cols-5 gap-2 text-xs font-medium text-text-secondary border-b pb-2 mb-2\">\n <span>Department</span>\n <span>Head</span>\n <span className=\"text-right\">Headcount</span>\n <span className=\"text-right\">Budget</span>\n <span className=\"text-right\">Cost/Employee</span>\n </div>\n {departments.map((dept) => {\n const costPerEmp =\n dept.employeeCount > 0 ? Math.round(dept.budget / dept.employeeCount) : 0;\n return (\n <div\n key={dept.id}\n className=\"grid grid-cols-5 gap-2 py-2 border-b last:border-0 text-sm\"\n >\n <span className=\"font-medium\">{dept.name}</span>\n <span className=\"text-text-secondary\">{dept.headName}</span>\n <span className=\"text-right\">{dept.employeeCount}</span>\n <span className=\"text-right\">${(dept.budget / 1000000).toFixed(1)}M</span>\n <span className=\"text-right\">${(costPerEmp / 1000).toFixed(0)}K</span>\n </div>\n );\n })}\n <Separator className=\"my-2\" />\n <div className=\"grid grid-cols-5 gap-2 text-sm font-bold\">\n <span>Total</span>\n <span />\n <span className=\"text-right\">\n {departments.reduce((s, d) => s + d.employeeCount, 0)}\n </span>\n <span className=\"text-right\">${(totalDeptBudget / 1000000).toFixed(1)}M</span>\n <span className=\"text-right\">\n $\n {(\n totalDeptBudget /\n departments.reduce((s, d) => s + d.employeeCount, 0) /\n 1000\n ).toFixed(0)}\n K\n </span>\n </div>\n </CardContent>\n </Card>\n </div>\n );\n}\n"],"mappings":";;;;;;AAeA,SAAgB,IAAkC;CAChD,IAAM,EAAE,cAAW,gBAAa,aAAU,mBAAgB,GAAqB,EAEzE,IAAmB,QAAc;EACrC,IAAM,IAAW;GAAC;GAAW;GAAW;GAAW;GAAU,EACvD,IAAO,EAAS,QAAQ,GAAK,MAAY,IAAM,EAAQ,QAAQ,EAAE,IAAI;AAC3E,SAAO,EAAS,KAAK,GAAS,MAAU;GACtC,IAAM,IAAU,KAAK,MAAM,KAAQ,MAAO,IAAQ,KAAM,EAClD,IAAY,KAAK,IAAI,GAAG,EAAU,UAAU,IAAI,KAAS,EAAE;AACjE,UAAO;IACL;IACA;IACA;IACA,gBAAgB,KAAK,MAAM,IAAU,EA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AE;QAAC;QAER;;MACH;;IACM,EAAA,CAAA,CACT,EAAA,CAAA;GACH"}
|
|
1
|
+
{"version":3,"file":"DashboardExecutiveDashboardPage.js","names":[],"sources":["../../../src/crewfoundry/pages/DashboardExecutiveDashboardPage.tsx"],"sourcesContent":["import {\n Badge,\n Card,\n CardContent,\n CardDescription,\n CardHeader,\n CardTitle,\n GlassCard,\n GradientText,\n PagePurpose,\n Separator,\n} from '@burdenoff/fe-libs/ui';\nimport { ArrowUp, Building2, DollarSign, Percent, Target } from 'lucide-react';\nimport { useMemo } from 'react';\nimport { useCrewFoundryStore } from '../store/crewfoundryStore';\n\nexport function DashboardExecutiveDashboardPage() {\n const { employees, departments, projects, jobPostings } = useCrewFoundryStore();\n\n const quarterlyRevenue = useMemo(() => {\n const quarters = ['Q1 2025', 'Q2 2025', 'Q3 2025', 'Q4 2025'];\n const base = projects.reduce((sum, project) => sum + project.budget, 0) || 1000000;\n return quarters.map((quarter, index) => {\n const revenue = Math.round(base * (0.55 + index * 0.08));\n const headcount = Math.max(1, employees.length - (3 - index) * 4);\n return {\n quarter,\n revenue,\n headcount,\n revenuePerHead: Math.round(revenue / headcount),\n };\n });\n }, [employees.length, projects]);\n\n const riskIndicators = useMemo(\n () => [\n {\n metric: 'Flight Risk Employees',\n value: employees.filter((employee) => employee.performanceScore < 3.6).length,\n severity: 'warning' as const,\n detail: `${Math.round((employees.filter((employee) => employee.performanceScore < 3.6).length / Math.max(employees.length, 1)) * 100)}% of workforce`,\n },\n {\n metric: 'Overdue Performance Reviews',\n value: employees.filter((employee) => employee.status === 'on_leave').length,\n severity: 'error' as const,\n detail: 'Review follow-ups required',\n },\n {\n metric: 'Unfilled Critical Roles',\n value: jobPostings.filter(\n (posting) => posting.status === 'active' && posting.experienceLevel === 'lead'\n ).length,\n severity: 'warning' as const,\n detail: 'Open lead-level positions',\n },\n {\n metric: 'Expiring Contracts',\n value: employees.filter((employee) => employee.type === 'contract').length,\n severity: 'info' as const,\n detail: 'Contract renewals in focus',\n },\n ],\n [employees, jobPostings]\n );\n\n const diversityMetrics = useMemo(() => {\n const byDepartment = departments.map((department) => {\n const count = employees.filter((employee) => employee.department === department.name).length;\n const male = Math.min(100, Math.round(45 + (count % 15)));\n const female = Math.min(100 - male, Math.round(40 + (count % 10)));\n const other = Math.max(0, 100 - male - female);\n return { category: department.name, male, female, other };\n });\n return [\n {\n category: 'Company',\n male: 52,\n female: 43,\n other: 5,\n },\n ...byDepartment.slice(0, 3),\n ];\n }, [departments, employees]);\n\n const totalSalaryBudget = employees.reduce((sum, e) => sum + e.salary, 0);\n const totalDeptBudget = departments.reduce((sum, d) => sum + d.budget, 0);\n const totalProjectBudget = projects.reduce((sum, p) => sum + p.budget, 0);\n const totalProjectSpent = projects.reduce((sum, p) => sum + p.spent, 0);\n const budgetUtilization = Math.round((totalProjectSpent / totalProjectBudget) * 100);\n\n return (\n <div className=\"space-y-6 p-6\">\n <div className=\"flex items-center justify-between\">\n <div>\n <h1 className=\"text-2xl font-semibold\">\n <GradientText>Executive Dashboard</GradientText>\n </h1>\n <p className=\"text-sm text-text-secondary\">Strategic workforce insights for leadership</p>\n <PagePurpose className=\"mt-1\">The executive snapshot — top-line workforce, financial, and hiring KPIs in one view so leaders can make decisions fast.</PagePurpose>\n </div>\n <Badge variant=\"outline\">Q1 2026</Badge>\n </div>\n\n <div className=\"grid gap-4 md:grid-cols-2 lg:grid-cols-4\">\n <GlassCard treatment=\"glass\" glow className=\"border-border-seam\">\n <CardHeader className=\"flex flex-row items-center justify-between space-y-0 pb-2\">\n <CardTitle className=\"text-sm font-medium\">Revenue per Employee</CardTitle>\n <DollarSign className=\"h-4 w-4 text-text-secondary\" />\n </CardHeader>\n <CardContent>\n <div className=\"text-2xl font-bold tabular-nums\">$21,862</div>\n <div className=\"flex items-center text-xs text-status-success-text\">\n <ArrowUp className=\"h-3 w-3 mr-1\" />\n +2.0% from Q3\n </div>\n </CardContent>\n </GlassCard>\n <GlassCard treatment=\"metric\" className=\"border-border-seam\">\n <CardHeader className=\"flex flex-row items-center justify-between space-y-0 pb-2\">\n <CardTitle className=\"text-sm font-medium\">Total Workforce Cost</CardTitle>\n <Building2 className=\"h-4 w-4 text-text-secondary\" />\n </CardHeader>\n <CardContent>\n <div className=\"text-2xl font-bold tabular-nums\">\n ${(totalSalaryBudget / 1000000).toFixed(1)}M\n </div>\n <p className=\"text-xs text-text-secondary\">Annual salary expenditure</p>\n </CardContent>\n </GlassCard>\n <GlassCard treatment=\"metric\" className=\"border-border-seam\">\n <CardHeader className=\"flex flex-row items-center justify-between space-y-0 pb-2\">\n <CardTitle className=\"text-sm font-medium\">Budget Utilization</CardTitle>\n <Percent className=\"h-4 w-4 text-text-secondary\" />\n </CardHeader>\n <CardContent>\n <div className=\"text-2xl font-bold tabular-nums\">{budgetUtilization}%</div>\n <p className=\"text-xs text-text-secondary\">\n ${(totalProjectSpent / 1000000).toFixed(1)}M of $\n {(totalProjectBudget / 1000000).toFixed(1)}M\n </p>\n </CardContent>\n </GlassCard>\n <GlassCard treatment=\"metric\" className=\"border-border-seam\">\n <CardHeader className=\"flex flex-row items-center justify-between space-y-0 pb-2\">\n <CardTitle className=\"text-sm font-medium\">Retention Rate</CardTitle>\n <Target className=\"h-4 w-4 text-text-secondary\" />\n </CardHeader>\n <CardContent>\n <div className=\"text-2xl font-bold tabular-nums\">95.8%</div>\n <div className=\"flex items-center text-xs text-status-success-text\">\n <ArrowUp className=\"h-3 w-3 mr-1\" />\n +1.1% improvement\n </div>\n </CardContent>\n </GlassCard>\n </div>\n\n <div className=\"grid gap-4 md:grid-cols-2\">\n <Card>\n <CardHeader>\n <CardTitle>Revenue & Headcount Trend</CardTitle>\n <CardDescription>Quarterly performance metrics</CardDescription>\n </CardHeader>\n <CardContent>\n <div className=\"grid grid-cols-4 gap-2 text-xs font-medium text-text-secondary border-b pb-2 mb-2\">\n <span>Quarter</span>\n <span className=\"text-right\">Revenue</span>\n <span className=\"text-right\">Headcount</span>\n <span className=\"text-right\">Rev/Head</span>\n </div>\n {quarterlyRevenue.map((q) => (\n <div\n key={q.quarter}\n className=\"grid grid-cols-4 gap-2 py-2 border-b last:border-0 text-sm\"\n >\n <span className=\"font-medium\">{q.quarter}</span>\n <span className=\"text-right\">${(q.revenue / 1000000).toFixed(1)}M</span>\n <span className=\"text-right\">{q.headcount}</span>\n <span className=\"text-right font-medium\">${q.revenuePerHead.toLocaleString()}</span>\n </div>\n ))}\n </CardContent>\n </Card>\n\n <Card>\n <CardHeader>\n <CardTitle>Risk Indicators</CardTitle>\n <CardDescription>Items requiring executive attention</CardDescription>\n </CardHeader>\n <CardContent className=\"space-y-3\">\n {riskIndicators.map((risk) => (\n <div\n key={risk.metric}\n className=\"flex items-center justify-between rounded border p-3\"\n >\n <div className=\"flex items-center gap-3\">\n <div\n className={`h-3 w-3 rounded-full ${\n risk.severity === 'error'\n ? 'bg-status-error-text'\n : risk.severity === 'warning'\n ? 'bg-status-warning-text'\n : 'bg-status-info-text'\n }`}\n />\n <div>\n <p className=\"text-sm font-medium\">{risk.metric}</p>\n <p className=\"text-xs text-text-secondary\">{risk.detail}</p>\n </div>\n </div>\n <span className=\"text-lg font-bold\">{risk.value}</span>\n </div>\n ))}\n </CardContent>\n </Card>\n </div>\n\n <Card>\n <CardHeader>\n <CardTitle>Diversity & Inclusion Metrics</CardTitle>\n <CardDescription>Gender distribution across organization segments</CardDescription>\n </CardHeader>\n <CardContent>\n <div className=\"space-y-4\">\n {diversityMetrics.map((d) => (\n <div key={d.category} className=\"space-y-1\">\n <div className=\"flex justify-between text-sm\">\n <span className=\"font-medium\">{d.category}</span>\n <span className=\"text-xs text-text-secondary\">\n M: {d.male}% · F: {d.female}% · Other: {d.other}%\n </span>\n </div>\n <div className=\"flex h-3 rounded overflow-hidden\">\n <div className=\"bg-status-info-text\" style={{ width: `${d.male}%` }} />\n <div className=\"bg-action-primary-bg\" style={{ width: `${d.female}%` }} />\n <div className=\"bg-status-success-text\" style={{ width: `${d.other}%` }} />\n </div>\n </div>\n ))}\n </div>\n </CardContent>\n </Card>\n\n <Card>\n <CardHeader>\n <CardTitle>Department Budget Status</CardTitle>\n <CardDescription>Annual budget allocation and headcount</CardDescription>\n </CardHeader>\n <CardContent>\n <div className=\"grid grid-cols-5 gap-2 text-xs font-medium text-text-secondary border-b pb-2 mb-2\">\n <span>Department</span>\n <span>Head</span>\n <span className=\"text-right\">Headcount</span>\n <span className=\"text-right\">Budget</span>\n <span className=\"text-right\">Cost/Employee</span>\n </div>\n {departments.map((dept) => {\n const costPerEmp =\n dept.employeeCount > 0 ? Math.round(dept.budget / dept.employeeCount) : 0;\n return (\n <div\n key={dept.id}\n className=\"grid grid-cols-5 gap-2 py-2 border-b last:border-0 text-sm\"\n >\n <span className=\"font-medium\">{dept.name}</span>\n <span className=\"text-text-secondary\">{dept.headName}</span>\n <span className=\"text-right\">{dept.employeeCount}</span>\n <span className=\"text-right\">${(dept.budget / 1000000).toFixed(1)}M</span>\n <span className=\"text-right\">${(costPerEmp / 1000).toFixed(0)}K</span>\n </div>\n );\n })}\n <Separator className=\"my-2\" />\n <div className=\"grid grid-cols-5 gap-2 text-sm font-bold\">\n <span>Total</span>\n <span />\n <span className=\"text-right\">\n {departments.reduce((s, d) => s + d.employeeCount, 0)}\n </span>\n <span className=\"text-right\">${(totalDeptBudget / 1000000).toFixed(1)}M</span>\n <span className=\"text-right\">\n $\n {(\n totalDeptBudget /\n departments.reduce((s, d) => s + d.employeeCount, 0) /\n 1000\n ).toFixed(0)}\n K\n </span>\n </div>\n </CardContent>\n </Card>\n </div>\n );\n}\n"],"mappings":";;;;;;AAgBA,SAAgB,IAAkC;CAChD,IAAM,EAAE,cAAW,gBAAa,aAAU,mBAAgB,GAAqB,EAEzE,IAAmB,QAAc;EACrC,IAAM,IAAW;GAAC;GAAW;GAAW;GAAW;GAAU,EACvD,IAAO,EAAS,QAAQ,GAAK,MAAY,IAAM,EAAQ,QAAQ,EAAE,IAAI;AAC3E,SAAO,EAAS,KAAK,GAAS,MAAU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,eAAe,EAAE;OAChD,CAAA;MACP,kBAAC,QAAD;OAAM,WAAU;iBAAhB;QAA6B;SAAG,IAAkB,KAAS,QAAQ,EAAE;QAAC;QAAQ;;MAC9E,kBAAC,QAAD;OAAM,WAAU;iBAAhB;QAA6B;SAGzB,IACA,EAAY,QAAQ,GAAG,MAAM,IAAI,EAAE,eAAe,EAAE,GACpD,KACA,QAAQ,EAAE;QAAC;QAER;;MACH;;IACM,EAAA,CAAA,CACT,EAAA,CAAA;GACH"}
|
|
@@ -2,16 +2,16 @@ import { useCrewFoundryStore as e } from "../store/crewfoundryStore.js";
|
|
|
2
2
|
import { useMemo as t, useState as n } from "react";
|
|
3
3
|
import { BookOpen as r, ChevronRight as i, Code2 as a, Copy as o, ExternalLink as s, Lock as c, Search as l, Server as u, Zap as d } from "lucide-react";
|
|
4
4
|
import { jsx as f, jsxs as p } from "react/jsx-runtime";
|
|
5
|
-
import { Badge as m, Button as h, Card as g, CardContent as _, CardDescription as v, CardHeader as y, CardTitle as b,
|
|
5
|
+
import { Badge as m, Button as h, Card as g, CardContent as _, CardDescription as v, CardHeader as y, CardTitle as b, EmphasisPanel as x, GradientText as S, IllustratedEmptyState as C, Input as w, PagePurpose as T } from "@burdenoff/fe-libs/ui";
|
|
6
6
|
//#region src/crewfoundry/pages/HelpApiDocumentationPagePage.tsx
|
|
7
|
-
var
|
|
7
|
+
var E = {
|
|
8
8
|
GET: "bg-status-success-bg text-status-success-text",
|
|
9
9
|
POST: "bg-status-info-bg text-status-info-text",
|
|
10
10
|
PATCH: "bg-status-warning-bg text-status-warning-text",
|
|
11
11
|
DELETE: "bg-status-error-bg text-status-error-text"
|
|
12
12
|
};
|
|
13
|
-
function
|
|
14
|
-
let { employees:
|
|
13
|
+
function D() {
|
|
14
|
+
let { employees: D, jobPostings: O, candidates: k, payrollRecords: A, leaveRequests: j } = e(), [M, N] = n(""), [P, F] = n(null), I = t(() => [
|
|
15
15
|
{
|
|
16
16
|
name: "Employees",
|
|
17
17
|
version: "v2",
|
|
@@ -19,7 +19,7 @@ function w() {
|
|
|
19
19
|
{
|
|
20
20
|
method: "GET",
|
|
21
21
|
path: "/api/v2/employees",
|
|
22
|
-
description: `List all employees (${
|
|
22
|
+
description: `List all employees (${D.length} records) with pagination and filters`
|
|
23
23
|
},
|
|
24
24
|
{
|
|
25
25
|
method: "POST",
|
|
@@ -50,7 +50,7 @@ function w() {
|
|
|
50
50
|
{
|
|
51
51
|
method: "GET",
|
|
52
52
|
path: "/api/v2/jobs",
|
|
53
|
-
description: `List all job postings (${
|
|
53
|
+
description: `List all job postings (${O.length} total)`
|
|
54
54
|
},
|
|
55
55
|
{
|
|
56
56
|
method: "POST",
|
|
@@ -60,7 +60,7 @@ function w() {
|
|
|
60
60
|
{
|
|
61
61
|
method: "GET",
|
|
62
62
|
path: "/api/v2/candidates",
|
|
63
|
-
description: `List candidates (${
|
|
63
|
+
description: `List candidates (${k.length}) with pipeline filters`
|
|
64
64
|
},
|
|
65
65
|
{
|
|
66
66
|
method: "POST",
|
|
@@ -76,7 +76,7 @@ function w() {
|
|
|
76
76
|
{
|
|
77
77
|
method: "GET",
|
|
78
78
|
path: "/api/v1/payroll/records",
|
|
79
|
-
description: `List payroll records by period (${
|
|
79
|
+
description: `List payroll records by period (${A.length} loaded)`
|
|
80
80
|
},
|
|
81
81
|
{
|
|
82
82
|
method: "POST",
|
|
@@ -97,7 +97,7 @@ function w() {
|
|
|
97
97
|
{
|
|
98
98
|
method: "GET",
|
|
99
99
|
path: "/api/v2/leave/requests",
|
|
100
|
-
description: `List leave requests with status filters (${
|
|
100
|
+
description: `List leave requests with status filters (${j.length} total)`
|
|
101
101
|
},
|
|
102
102
|
{
|
|
103
103
|
method: "POST",
|
|
@@ -112,29 +112,36 @@ function w() {
|
|
|
112
112
|
]
|
|
113
113
|
}
|
|
114
114
|
], [
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
T.length,
|
|
115
|
+
k.length,
|
|
116
|
+
D.length,
|
|
118
117
|
O.length,
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
118
|
+
j.length,
|
|
119
|
+
A.length
|
|
120
|
+
]), L = (e) => {
|
|
121
|
+
F(e), setTimeout(() => F(null), 1500);
|
|
122
|
+
}, R = I.map((e) => ({
|
|
123
123
|
...e,
|
|
124
|
-
endpoints: e.endpoints.filter((e) => e.path.toLowerCase().includes(
|
|
124
|
+
endpoints: e.endpoints.filter((e) => e.path.toLowerCase().includes(M.toLowerCase()) || e.description.toLowerCase().includes(M.toLowerCase()))
|
|
125
125
|
})).filter((e) => e.endpoints.length > 0);
|
|
126
126
|
return /* @__PURE__ */ p("div", {
|
|
127
127
|
className: "space-y-6 p-6",
|
|
128
128
|
children: [
|
|
129
129
|
/* @__PURE__ */ p("div", {
|
|
130
130
|
className: "flex items-center justify-between",
|
|
131
|
-
children: [/* @__PURE__ */ p("div", { children: [
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
131
|
+
children: [/* @__PURE__ */ p("div", { children: [
|
|
132
|
+
/* @__PURE__ */ f("h1", {
|
|
133
|
+
className: "text-2xl font-semibold",
|
|
134
|
+
children: /* @__PURE__ */ f(S, { children: "API Documentation" })
|
|
135
|
+
}),
|
|
136
|
+
/* @__PURE__ */ f("p", {
|
|
137
|
+
className: "text-sm text-text-secondary",
|
|
138
|
+
children: "CrewFoundry REST API reference for integrations"
|
|
139
|
+
}),
|
|
140
|
+
/* @__PURE__ */ f(T, {
|
|
141
|
+
className: "mt-1",
|
|
142
|
+
children: "Browse the CrewFoundry API reference — use it to find endpoints, understand request formats, and integrate CrewFoundry with your own tools."
|
|
143
|
+
})
|
|
144
|
+
] }), /* @__PURE__ */ p("div", {
|
|
138
145
|
className: "flex gap-2",
|
|
139
146
|
children: [/* @__PURE__ */ f(m, {
|
|
140
147
|
variant: "secondary",
|
|
@@ -188,10 +195,10 @@ function w() {
|
|
|
188
195
|
className: "grid gap-6 lg:grid-cols-4",
|
|
189
196
|
children: [/* @__PURE__ */ p("div", {
|
|
190
197
|
className: "space-y-4",
|
|
191
|
-
children: [/* @__PURE__ */ p(
|
|
192
|
-
className: "text-sm",
|
|
198
|
+
children: [/* @__PURE__ */ p(x, { children: [/* @__PURE__ */ f("div", {
|
|
199
|
+
className: "mb-2 text-sm font-semibold",
|
|
193
200
|
children: "Quick Start"
|
|
194
|
-
})
|
|
201
|
+
}), /* @__PURE__ */ f("div", {
|
|
195
202
|
className: "space-y-2",
|
|
196
203
|
children: [
|
|
197
204
|
{
|
|
@@ -239,14 +246,14 @@ function w() {
|
|
|
239
246
|
children: [
|
|
240
247
|
/* @__PURE__ */ p("div", {
|
|
241
248
|
className: "relative max-w-md",
|
|
242
|
-
children: [/* @__PURE__ */ f(l, { className: "absolute left-3 top-1/2 -translate-y-1/2 h-4 w-4 text-text-secondary" }), /* @__PURE__ */ f(
|
|
249
|
+
children: [/* @__PURE__ */ f(l, { className: "absolute left-3 top-1/2 -translate-y-1/2 h-4 w-4 text-text-secondary" }), /* @__PURE__ */ f(w, {
|
|
243
250
|
placeholder: "Search endpoints...",
|
|
244
251
|
className: "pl-9",
|
|
245
|
-
value:
|
|
246
|
-
onChange: (e) =>
|
|
252
|
+
value: M,
|
|
253
|
+
onChange: (e) => N(e.target.value)
|
|
247
254
|
})]
|
|
248
255
|
}),
|
|
249
|
-
|
|
256
|
+
R.map((e) => /* @__PURE__ */ p(g, { children: [/* @__PURE__ */ p(y, { children: [/* @__PURE__ */ p("div", {
|
|
250
257
|
className: "flex items-center gap-2",
|
|
251
258
|
children: [/* @__PURE__ */ f(b, {
|
|
252
259
|
className: "text-base",
|
|
@@ -262,7 +269,7 @@ function w() {
|
|
|
262
269
|
className: `flex items-center gap-3 px-6 py-3 hover:bg-bg-sunken/50 cursor-pointer ${n < e.endpoints.length - 1 ? "border-b" : ""}`,
|
|
263
270
|
children: [
|
|
264
271
|
/* @__PURE__ */ f(m, {
|
|
265
|
-
className: `${
|
|
272
|
+
className: `${E[t.method]} text-[10px] font-mono border-0 min-w-[50px] justify-center`,
|
|
266
273
|
children: t.method
|
|
267
274
|
}),
|
|
268
275
|
/* @__PURE__ */ f("code", {
|
|
@@ -277,15 +284,19 @@ function w() {
|
|
|
277
284
|
variant: "ghost",
|
|
278
285
|
size: "sm",
|
|
279
286
|
className: "h-6 w-6 p-0",
|
|
280
|
-
onClick: () =>
|
|
281
|
-
children: /* @__PURE__ */ f(o, { className: `h-3 w-3 ${
|
|
287
|
+
onClick: () => L(t.path),
|
|
288
|
+
children: /* @__PURE__ */ f(o, { className: `h-3 w-3 ${P === t.path ? "text-status-success-text" : "text-text-secondary"}` })
|
|
282
289
|
})
|
|
283
290
|
]
|
|
284
291
|
}, t.path + t.method))
|
|
285
292
|
})] }, e.name)),
|
|
286
|
-
|
|
287
|
-
className: "
|
|
288
|
-
children:
|
|
293
|
+
R.length === 0 && /* @__PURE__ */ f("div", {
|
|
294
|
+
className: "py-6",
|
|
295
|
+
children: /* @__PURE__ */ f(C, {
|
|
296
|
+
illustration: "empty-search",
|
|
297
|
+
title: "No endpoints match",
|
|
298
|
+
description: "Try a different search term to find the API you need."
|
|
299
|
+
})
|
|
289
300
|
})
|
|
290
301
|
]
|
|
291
302
|
})]
|
|
@@ -294,6 +305,6 @@ function w() {
|
|
|
294
305
|
});
|
|
295
306
|
}
|
|
296
307
|
//#endregion
|
|
297
|
-
export {
|
|
308
|
+
export { D as HelpApiDocumentationPagePage };
|
|
298
309
|
|
|
299
310
|
//# sourceMappingURL=HelpApiDocumentationPagePage.js.map
|