Adopt semantic campaign page actions
This commit is contained in:
@@ -22,7 +22,7 @@ import { DataGrid, type DataGridColumn, type DataGridListOption, type DataGridQu
|
||||
import { Dialog } from "@govoplan/core-webui";
|
||||
import { DismissibleAlert } from "@govoplan/core-webui";
|
||||
import { FormField } from "@govoplan/core-webui";
|
||||
import { PageLayout } from "@govoplan/core-webui";
|
||||
import { PageActionBar, PageLayout } from "@govoplan/core-webui";
|
||||
import { StatusBadge } from "@govoplan/core-webui";
|
||||
import VersionLine from "./components/VersionLine";
|
||||
import { LoadingFrame, TableActionGroup, ToggleSwitch, i18nMessage } from "@govoplan/core-webui";
|
||||
@@ -447,19 +447,22 @@ export default function CampaignReportPage({ settings, campaignId }: {settings:
|
||||
|
||||
return (
|
||||
<PageLayout
|
||||
archetype="detail"
|
||||
mode="workspace"
|
||||
title="i18n:govoplan-campaign.report.ee45c303"
|
||||
description={<VersionLine version={version} versions={data.versions} loadedAt={version?.updated_at ?? data.summary?.generated_at} />}
|
||||
headerLoading={loading}
|
||||
error={error || actionError}
|
||||
success={actionMessage}
|
||||
actions={
|
||||
<>
|
||||
actions={<PageActionBar
|
||||
variant="detail"
|
||||
refreshable
|
||||
reloadAction={<Button onClick={() => void reloadAll()} disabled={loading || jobsLoading}>i18n:govoplan-campaign.reload.cce71553</Button>}
|
||||
primaryActions={<>
|
||||
<Button onClick={() => void exportCsv()} disabled={busyAction === "csv"}>i18n:govoplan-campaign.download_csv.eaa216ad</Button>
|
||||
<Button onClick={() => setEmailOpen(true)}>i18n:govoplan-campaign.email_report.ee3e7091</Button>
|
||||
<Button onClick={() => void reloadAll()} disabled={loading || jobsLoading}>Discard</Button>
|
||||
</>
|
||||
}
|
||||
</>}
|
||||
/>}
|
||||
>
|
||||
<LoadingFrame loading={loading} label="i18n:govoplan-campaign.loading_report_data.0908ade5">
|
||||
<ContentGrid columns={2} collapseAt="workspace" className="">
|
||||
|
||||
Reference in New Issue
Block a user