// @ts-nocheck import React from 'react'; import { Button } from '@blueprintjs/core'; import { Icon, If, FormattedMessage as T } from '@/components'; import { useProfitLossSheetContext } from './ProfitLossProvider'; import FinancialLoadingBar from '../FinancialLoadingBar'; /** * Profit/loss sheet loading bar. */ export function ProfitLossSheetLoadingBar() { const { isFetching } = useProfitLossSheetContext(); return ( ); } /** * Balance sheet alerts. */ export function ProfitLossSheetAlerts() { const { isLoading, sheetRefetch, profitLossSheet } = useProfitLossSheetContext(); // Handle refetch the report sheet. const handleRecalcReport = () => { sheetRefetch(); }; // Can't display any error if the report is loading. if (isLoading) { return null; } return (
); }