Skip to content

Commit

Permalink
chore(Dashboard): Unblock Global Styles (apache#30440)
Browse files Browse the repository at this point in the history
  • Loading branch information
geido authored Sep 30, 2024
1 parent 4834390 commit c7aeb21
Showing 1 changed file with 12 additions and 7 deletions.
19 changes: 12 additions & 7 deletions superset-frontend/src/dashboard/containers/DashboardPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,6 @@ export const DashboardPage: FC<PageProps> = ({ idOrSlug }: PageProps) => {
}, [addDangerToast, datasets, datasetsApiError, dispatch]);

if (error) throw error; // caught in error boundary
if (!readyToRender || !hasDashboardInfoInitiated) return <Loading />;

return (
<>
Expand All @@ -205,12 +204,18 @@ export const DashboardPage: FC<PageProps> = ({ idOrSlug }: PageProps) => {
chartHeaderStyles(theme),
]}
/>
<SyncDashboardState dashboardPageId={dashboardPageId} />
<DashboardPageIdContext.Provider value={dashboardPageId}>
<DashboardContainer>
<DashboardBuilder />
</DashboardContainer>
</DashboardPageIdContext.Provider>
{readyToRender && hasDashboardInfoInitiated ? (
<>
<SyncDashboardState dashboardPageId={dashboardPageId} />
<DashboardPageIdContext.Provider value={dashboardPageId}>
<DashboardContainer>
<DashboardBuilder />
</DashboardContainer>
</DashboardPageIdContext.Provider>
</>
) : (
<Loading />
)}
</>
);
};
Expand Down

0 comments on commit c7aeb21

Please sign in to comment.