diff --git a/apps/fishing-map/features/vessel-group-report/vessels/VesselGroupReportVesselsGraph.module.css b/apps/fishing-map/features/vessel-group-report/vessels/VesselGroupReportVesselsGraph.module.css index 9f5da2c0c5..7eadf8c446 100644 --- a/apps/fishing-map/features/vessel-group-report/vessels/VesselGroupReportVesselsGraph.module.css +++ b/apps/fishing-map/features/vessel-group-report/vessels/VesselGroupReportVesselsGraph.module.css @@ -1,7 +1,7 @@ .graph { width: 100%; height: 30rem; - margin-bottom: var(--space-S); + margin-block: var(--space-S); } .graph tspan { diff --git a/apps/fishing-map/features/vessel-group-report/vessels/VesselGroupReportVesselsTable.tsx b/apps/fishing-map/features/vessel-group-report/vessels/VesselGroupReportVesselsTable.tsx index 655779c4ed..75fc625b31 100644 --- a/apps/fishing-map/features/vessel-group-report/vessels/VesselGroupReportVesselsTable.tsx +++ b/apps/fishing-map/features/vessel-group-report/vessels/VesselGroupReportVesselsTable.tsx @@ -173,8 +173,7 @@ export default function VesselGroupReportVesselsTable() { })} - {/* TODO */} - + ) } diff --git a/apps/fishing-map/features/vessel-group-report/vessels/VesselGroupReportVesselsTableFooter.tsx b/apps/fishing-map/features/vessel-group-report/vessels/VesselGroupReportVesselsTableFooter.tsx index 8bbb7a72b1..6d759bedfa 100644 --- a/apps/fishing-map/features/vessel-group-report/vessels/VesselGroupReportVesselsTableFooter.tsx +++ b/apps/fishing-map/features/vessel-group-report/vessels/VesselGroupReportVesselsTableFooter.tsx @@ -10,6 +10,8 @@ import { useLocationConnect } from 'routes/routes.hook' import { selectTimeRange } from 'features/app/selectors/app.timebar.selectors' import { REPORT_SHOW_MORE_VESSELS_PER_PAGE, REPORT_VESSELS_PER_PAGE } from 'data/config' import { TrackCategory, trackEvent } from 'features/app/analytics.hooks' +import { selectVesselGroupReportData } from 'features/vessel-group-report/vessel-group-report.slice' +import { formatInfoField } from 'utils/info' import { selectVesselGroupReportVesselFilter } from '../vessel-group.config.selectors' import styles from './VesselGroupReportVesselsTableFooter.module.css' import { @@ -17,15 +19,10 @@ import { selectVesselGroupReportVesselsPagination, } from './vessel-group-report-vessels.selectors' -type ReportVesselsTableFooterProps = { - reportName: string -} - -export default function VesselGroupReportVesselsTableFooter({ - reportName, -}: ReportVesselsTableFooterProps) { +export default function VesselGroupReportVesselsTableFooter() { const { t } = useTranslation() const { dispatchQueryParams } = useLocationConnect() + const vesselGroup = useSelector(selectVesselGroupReportData) const allVessels = useSelector(selectVesselGroupReportVesselsFiltered) const reportVesselFilter = useSelector(selectVesselGroupReportVesselFilter) const pagination = useSelector(selectVesselGroupReportVesselsPagination) @@ -46,7 +43,7 @@ export default function VesselGroupReportVesselsTableFooter({ // }) const csv = unparseCSV(vessels) const blob = new Blob([csv], { type: 'text/plain;charset=utf-8' }) - saveAs(blob, `${reportName}-${start}-${end}.csv`) + saveAs(blob, `${formatInfoField(vesselGroup?.name, 'name')}-${start}-${end}.csv`) } }