@@ -14,8 +14,8 @@ import {DEFAULT_DEBOUNCE_DURATION} from 'sentry/constants';
14
14
import { t } from 'sentry/locale' ;
15
15
import { space } from 'sentry/styles/space' ;
16
16
import type { PageFilters , SelectValue } from 'sentry/types/core' ;
17
- import type { Organization } from 'sentry/types/organization' ;
18
17
import type { TableDataWithTitle } from 'sentry/utils/discover/discoverQuery' ;
18
+ import useOrganization from 'sentry/utils/useOrganization' ;
19
19
import usePrevious from 'sentry/utils/usePrevious' ;
20
20
import type { DashboardFilters , Widget , WidgetType } from 'sentry/views/dashboards/types' ;
21
21
import { DisplayType } from 'sentry/views/dashboards/types' ;
@@ -34,7 +34,6 @@ interface Props {
34
34
isWidgetInvalid : boolean ;
35
35
location : Location ;
36
36
onChange : ( displayType : DisplayType ) => void ;
37
- organization : Organization ;
38
37
pageFilters : PageFilters ;
39
38
widget : Widget ;
40
39
widgetLegendState : WidgetLegendSelectionState ;
@@ -45,7 +44,6 @@ interface Props {
45
44
}
46
45
47
46
export function VisualizationStep ( {
48
- organization,
49
47
pageFilters,
50
48
displayType,
51
49
error,
@@ -58,6 +56,7 @@ export function VisualizationStep({
58
56
onWidgetSplitDecision,
59
57
widgetLegendState,
60
58
} : Props ) {
59
+ const organization = useOrganization ( ) ;
61
60
const [ debouncedWidget , setDebouncedWidget ] = useState ( widget ) ;
62
61
63
62
const previousWidget = usePrevious ( widget ) ;
0 commit comments