From 06ca237a937477a93080e216e1ab27c6aaad09e9 Mon Sep 17 00:00:00 2001 From: "metabase-bot[bot]" <109303359+metabase-bot[bot]@users.noreply.github.com> Date: Wed, 27 Mar 2024 13:43:45 +0000 Subject: [PATCH] Fix filters disappeared from dashboard PDFs (#40664) (#40669) Co-authored-by: Anton Kulyk <kuliks.anton@gmail.com> --- .../dashboard/components/DashboardHeader/DashboardHeader.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/frontend/src/metabase/dashboard/components/DashboardHeader/DashboardHeader.tsx b/frontend/src/metabase/dashboard/components/DashboardHeader/DashboardHeader.tsx index 3b7aef5d10d..d69640072ea 100644 --- a/frontend/src/metabase/dashboard/components/DashboardHeader/DashboardHeader.tsx +++ b/frontend/src/metabase/dashboard/components/DashboardHeader/DashboardHeader.tsx @@ -62,7 +62,7 @@ import type { DashboardSidebarState, } from "metabase-types/store"; -import { SIDEBAR_NAME } from "../../constants"; +import { DASHBOARD_PDF_EXPORT_ROOT_ID, SIDEBAR_NAME } from "../../constants"; import { ExtraEditButtonsMenu } from "../ExtraEditButtonsMenu/ExtraEditButtonsMenu"; import { @@ -285,7 +285,7 @@ export const DashboardHeader = (props: DashboardHeaderProps) => { }; const saveAsPDF = async () => { - const cardNodeSelector = "#Dashboard-Cards-Container"; + const cardNodeSelector = `#${DASHBOARD_PDF_EXPORT_ROOT_ID}`; await saveDashboardPdf(cardNodeSelector, dashboard.name).then(() => { trackExportDashboardToPDF(dashboard.id); }); -- GitLab