@@ -57,8 +57,8 @@ import { useContextMenu, useTable } from '../../hooks'
5757import type { EditingCell , QueryOptions , SaveReason } from '../../types'
5858import { cleanCellValue , generateColumnName as sharedGenerateColumnName } from '../../utils'
5959import type { ColumnConfig } from '../column-config-sidebar'
60+ import { ColumnDropdown } from '../column-dropdown'
6061import { ContextMenu } from '../context-menu'
61- import { NewColumnDropdown } from '../new-column-dropdown'
6262import type { WorkflowConfig } from '../workflow-sidebar'
6363import { ExpandedCellPopover } from './cells'
6464import { ADD_COL_WIDTH , COL_WIDTH , SELECTION_TINT_BG } from './constants'
@@ -898,7 +898,11 @@ export function TableGrid({
898898 * so solo editing never pays the map build. */
899899 const columnIndexById = useMemo ( ( ) => {
900900 const map = new Map < string , number > ( )
901- if ( remoteSelections . length > 0 ) displayColumns . forEach ( ( col , index ) => map . set ( col . key , index ) )
901+ if ( remoteSelections . length > 0 ) {
902+ displayColumns . forEach ( ( col , index ) => {
903+ map . set ( col . key , index )
904+ } )
905+ }
902906 return map
903907 } , [ displayColumns , remoteSelections . length ] )
904908
@@ -907,7 +911,11 @@ export function TableGrid({
907911 * solo editing never pays the O(n) map build on a refetch. */
908912 const rowIndexById = useMemo ( ( ) => {
909913 const map = new Map < string , number > ( )
910- if ( remoteSelections . length > 0 ) rows . forEach ( ( row , index ) => map . set ( row . id , index ) )
914+ if ( remoteSelections . length > 0 ) {
915+ rows . forEach ( ( row , index ) => {
916+ map . set ( row . id , index )
917+ } )
918+ }
911919 return map
912920 } , [ rows , remoteSelections . length ] )
913921
@@ -2251,7 +2259,9 @@ export function TableGrid({
22512259 const draggedGid = colByName . get ( dragged ) ?. workflowGroupId
22522260
22532261 const orderIndex = new Map < string , number > ( )
2254- currentOrder . forEach ( ( n , i ) => orderIndex . set ( n , i ) )
2262+ currentOrder . forEach ( ( n , i ) => {
2263+ orderIndex . set ( n , i )
2264+ } )
22552265
22562266 // Compute the contiguous run covering the dragged column. For a plain
22572267 // column this is just [fromIndex, fromIndex]. For a group member it spans
@@ -4853,7 +4863,7 @@ export function TableGrid({
48534863 )
48544864 } ) }
48554865 { userPermissions . canEdit && (
4856- < NewColumnDropdown
4866+ < ColumnDropdown
48574867 trigger = 'inline-header'
48584868 disabled = { addColumnMutation . isPending }
48594869 blocked = { ! canMutateSchema }
0 commit comments