import * as React from 'react';
import { useState } from 'react';
import { ReportFormatSelector } from './ReportFormatSelector';
import { ExportDestinationPicker } from './ExportDestinationPicker';
import { Flex } from '../../components/Flex';
export const ReportListItem = (props) => {
    const report = props.data;
    const [reportFormat, setReportFormat] = useState(null);
    const viewType = 'SettingsPanel';
    return (React.createElement(Flex, { flexDirection: "row", className: `ab-${viewType}__Export__panel` },
        React.createElement(ReportFormatSelector, { viewType: viewType, reportName: report.Name, reportFormat: reportFormat, onReportFormatSelected: (reportFormat) => setReportFormat(reportFormat) }),
        React.createElement(ExportDestinationPicker, { viewType: "SettingsPanel", reportName: report.Name, reportFormat: reportFormat })));
};
