Skip to content
Snippets Groups Projects
Unverified Commit 848fd930 authored by Uladzimir Havenchyk's avatar Uladzimir Havenchyk Committed by GitHub
Browse files

Drop props spreading to DashboardHeader (#42887)

parent ba7eae75
Branches
Tags
No related merge requests found
......@@ -516,7 +516,6 @@ function DashboardInner(props: DashboardProps) {
</ParametersWidgetContainer>
);
};
return (
<DashboardLoadingAndErrorWrapper
isFullHeight={isEditing || isSharing}
......@@ -555,11 +554,45 @@ function DashboardInner(props: DashboardProps) {
* in Redux state which kicks off a fetch for the dashboard cards.
*/}
<DashboardHeader
{...props}
dashboardId={dashboardId}
isEditing={isEditing}
location={location}
dashboard={dashboard}
isNightMode={shouldRenderAsNightMode}
parametersWidget={parametersWidget}
isFullscreen={isFullscreen}
fetchDashboard={fetchDashboard}
onEditingChange={handleSetEditing}
setDashboardAttribute={handleSetDashboardAttribute}
addParameter={addParameter}
onSharingClick={handleToggleSharing}
addCardToDashboard={addCardToDashboard}
onRefreshPeriodChange={onRefreshPeriodChange}
addMarkdownDashCardToDashboard={
props.addMarkdownDashCardToDashboard
}
addHeadingDashCardToDashboard={
props.addHeadingDashCardToDashboard
}
addLinkDashCardToDashboard={props.addLinkDashCardToDashboard}
updateDashboardAndCards={props.updateDashboardAndCards}
dashboardBeforeEditing={props.dashboardBeforeEditing}
isDirty={props.isDirty}
onFullscreenChange={props.onFullscreenChange}
sidebar={props.sidebar}
setSidebar={props.setSidebar}
closeSidebar={props.closeSidebar}
databases={props.databases}
isAddParameterPopoverOpen={props.isAddParameterPopoverOpen}
showAddParameterPopover={props.showAddParameterPopover}
hideAddParameterPopover={props.hideAddParameterPopover}
isAdditionalInfoVisible={props.isAdditionalInfoVisible}
isAdmin={props.isAdmin}
canManageSubscriptions={props.canManageSubscriptions}
hasNightModeToggle={props.hasNightModeToggle}
onNightModeChange={props.onNightModeChange}
refreshPeriod={props.refreshPeriod}
setRefreshElapsedHook={props.setRefreshElapsedHook}
/>
</DashboardHeaderContainer>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment