mirror of
https://github.com/apache/superset.git
synced 2026-04-17 15:15:20 +00:00
perf(dashboard): Improve perf of highlighting charts in scope of active filter (#15424)
* perf(dashboard): Improve perf of highlighting charts in scope of active filter * More optimizations * fix tests * Fix lint * bug fix
This commit is contained in:
committed by
GitHub
parent
f33a0e1d68
commit
f109da479d
@@ -31,7 +31,7 @@ import DashboardComponent from 'src/dashboard/containers/DashboardComponent';
|
||||
import DeleteComponentButton from 'src/dashboard/components/DeleteComponentButton';
|
||||
import HoverMenu from 'src/dashboard/components/menu/HoverMenu';
|
||||
import DragDroppable from 'src/dashboard/components/dnd/DragDroppable';
|
||||
import Tabs from 'src/dashboard/components/gridComponents/Tabs';
|
||||
import { Tabs } from 'src/dashboard/components/gridComponents/Tabs';
|
||||
import { DASHBOARD_ROOT_ID } from 'src/dashboard/util/constants';
|
||||
import emptyDashboardLayout from 'src/dashboard/fixtures/emptyDashboardLayout';
|
||||
import { dashboardLayoutWithTabs } from 'spec/fixtures/mockDashboardLayout';
|
||||
@@ -66,14 +66,15 @@ describe('Tabs', () => {
|
||||
nativeFilters: nativeFilters.filters,
|
||||
};
|
||||
|
||||
const mockStore = getMockStore({
|
||||
...initialState,
|
||||
dashboardLayout: dashboardLayoutWithTabs,
|
||||
dashboardFilters: {},
|
||||
});
|
||||
|
||||
function setup(overrideProps) {
|
||||
// We have to wrap provide DragDropContext for the underlying DragDroppable
|
||||
// otherwise we cannot assert on DragDroppable children
|
||||
const mockStore = getMockStore({
|
||||
...initialState,
|
||||
dashboardLayout: dashboardLayoutWithTabs,
|
||||
dashboardFilters: {},
|
||||
});
|
||||
const wrapper = mount(
|
||||
<Provider store={mockStore}>
|
||||
<DndProvider backend={HTML5Backend}>
|
||||
|
||||
Reference in New Issue
Block a user