// @ts-nocheck import React from 'react'; import { NavbarGroup, NavbarDivider, Button, Classes, Popover, PopoverInteractionKind, Position, } from '@blueprintjs/core'; import { Icon, FormattedMessage as T, DashboardActionsBar } from '@/components'; import classNames from 'classnames'; import NumberFormatDropdown from '@/components/NumberFormatDropdown'; import { useCashFlowStatementContext } from './CashFlowStatementProvider'; import withCashFlowStatement from './withCashFlowStatement'; import withCashFlowStatementActions from './withCashFlowStatementActions'; import { compose, saveInvoke } from '@/utils'; import { CashflowSheetExportMenu } from './components'; import withDialogActions from '@/containers/Dialog/withDialogActions'; import { DialogsName } from '@/constants/dialogs'; /** * Cash flow statement actions bar. */ function CashFlowStatementActionsBar({ //#withCashFlowStatement isFilterDrawerOpen, //#withCashStatementActions toggleCashFlowStatementFilterDrawer, // #withDialogActions openDialog, //#ownProps numberFormat, onNumberFormatSubmit, }) { const { isCashFlowLoading, refetchCashFlow } = useCashFlowStatementContext(); // Handle filter toggle click. const handleFilterToggleClick = () => { toggleCashFlowStatementFilterDrawer(); }; // Handle recalculate report button. const handleRecalculateReport = () => { refetchCashFlow(); }; // handle number format form submit. const handleNumberFormatSubmit = (values) => saveInvoke(onNumberFormatSubmit, values); // Handle print button click. const handlePrintBtnClick = () => { openDialog(DialogsName.CashflowSheetPdfPreview); }; return (