File tree Expand file tree Collapse file tree 1 file changed +7
-4
lines changed
superset-frontend/src/explore/components/controls/DndColumnSelectControl Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -92,10 +92,6 @@ const ColumnSelectPopoverTriggerInner = ({
92
92
initialPopoverLabel = editedColumn . label || defaultPopoverLabel ;
93
93
}
94
94
95
- useEffect ( ( ) => {
96
- setPopoverLabel ( initialPopoverLabel ) ;
97
- } , [ initialPopoverLabel , popoverVisible ] ) ;
98
-
99
95
const togglePopover = useCallback ( ( visible : boolean ) => {
100
96
setPopoverVisible ( visible ) ;
101
97
} , [ ] ) ;
@@ -121,6 +117,13 @@ const ColumnSelectPopoverTriggerInner = ({
121
117
setIsTitleEditDisabled ( tab !== editableTitleTab ) ;
122
118
} , [ ] ) ;
123
119
120
+ useEffect ( ( ) => {
121
+ if ( ! visible ) {
122
+ setPopoverLabel ( initialPopoverLabel ) ;
123
+ setHasCustomLabel ( false ) ;
124
+ }
125
+ } , [ initialPopoverLabel , visible ] ) ;
126
+
124
127
const overlayContent = useMemo (
125
128
( ) => (
126
129
< ExplorePopoverContent >
You can’t perform that action at this time.
0 commit comments