Files
dashboard/utils/reportOverlayLabels.ts

11 lines
467 B
TypeScript

import type { DashboardReportType } from '../types/dashboardReport.ts';
export const reportCtaLabel = (hasSnapshot: boolean): string =>
hasSnapshot ? 'Lihat Laporan' : 'Laporan';
export const reportOverlayTitle = (reportType: DashboardReportType): string =>
reportType === 'end_cycle' ? 'Laporan Akhir Siklus' : 'Laporan Harian IoT vs Manual';
export const generateButtonLabel = (hasSnapshot: boolean): string =>
hasSnapshot ? 'Generate ulang' : 'Generate';