diff --git a/apps/studio/components/layouts/TableEditorLayout/EntityListItem.tsx b/apps/studio/components/layouts/TableEditorLayout/EntityListItem.tsx index 60eef71bc66..054a596a557 100644 --- a/apps/studio/components/layouts/TableEditorLayout/EntityListItem.tsx +++ b/apps/studio/components/layouts/TableEditorLayout/EntityListItem.tsx @@ -118,161 +118,143 @@ const EntityListItem: ItemRenderer = ({ } return ( -
- - - - {entity.type === ENTITY_TYPE.TABLE ? ( - - ) : entity.type === ENTITY_TYPE.VIEW ? ( - - ) : ( -
- {Object.entries(ENTITY_TYPE) - .find(([, value]) => value === entity.type)?.[0]?.[0] - ?.toUpperCase()} -
- )} -
- - - - {formatTooltipText(entity.type)} - - -
-
- {/* only show tooltips if required, to reduce noise */} - {entity.name.length > 20 ? ( - - - {entity.name} - - - - - {entity.name} - - - + + + {entity.type === ENTITY_TYPE.TABLE ? ( + + ) : entity.type === ENTITY_TYPE.VIEW ? ( + ) : ( - entity.name - )} - - {entity.type === ENTITY_TYPE.TABLE && !entity.rls_enabled && ( -
- +
+ {Object.entries(ENTITY_TYPE) + .find(([, value]) => value === entity.type)?.[0]?.[0] + ?.toUpperCase()}
)} -
- -
- {entity.type === ENTITY_TYPE.TABLE && isActive && !isLocked && ( - - -
- -
-
- - { - e.stopPropagation() - snap.onEditTable() - }} - > - - Edit Table - - { - e.stopPropagation() - snap.onDuplicateTable() - }} - > - - Duplicate Table - - - - - View Policies - - - { - e.stopPropagation() - exportTableAsCSV() - }} - > - - Export as CSV - - - { - e.stopPropagation() - snap.onDeleteTable() - }} - > - - Delete Table - - -
+ + + + + {formatTooltipText(entity.type)} + + + +
+ {/* only show tooltips if required, to reduce noise */} + + {entity.name} + + + {entity.type === ENTITY_TYPE.TABLE && !entity.rls_enabled && ( + )}
-
+ + {entity.type === ENTITY_TYPE.TABLE && isActive && !isLocked && ( + + + + + + { + e.stopPropagation() + snap.onEditTable() + }} + > + + Edit Table + + { + e.stopPropagation() + snap.onDuplicateTable() + }} + > + + Duplicate Table + + + + + View Policies + + + { + e.stopPropagation() + exportTableAsCSV() + }} + > + + Export as CSV + + + { + e.stopPropagation() + snap.onDeleteTable() + }} + > + + Delete Table + + + + )} + ) }