File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
redisinsight/ui/src/pages/home/components/databases-list-component/databases-list Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -77,10 +77,10 @@ function DatabasesList({
77
77
offsetWidth : number ,
78
78
) : EuiTableFieldDataColumnType < Instance > [ ] => {
79
79
let sum = cols ?. reduce ( ( prev , next ) => prev + getColumnWidth ( next . width ) , 0 )
80
- const visibleColumns = cols . length - hiddenCols . current . size
80
+ const visibleColumnsLength = cols . length - hiddenCols . current . size
81
81
82
82
// hide columns
83
- if ( sum > offsetWidth && columnsToHide . length + visibleColumns ) {
83
+ if ( sum > offsetWidth && columnsToHide . length + visibleColumnsLength ) {
84
84
let resultsCol = [ ...cols ]
85
85
while ( sum > offsetWidth ) {
86
86
const colToHide = columnsToHide [ hiddenCols . current . size ]
@@ -97,7 +97,7 @@ function DatabasesList({
97
97
}
98
98
99
99
// show columns
100
- if ( columnsProp . length > visibleColumns ) {
100
+ if ( columnsProp . length > visibleColumnsLength ) {
101
101
// early return to not calculate other columns
102
102
const lastHiddenColWidth = getColumnWidth ( lastHiddenColumn . current ?. width )
103
103
if ( sum + lastHiddenColWidth > offsetWidth ) {
You can’t perform that action at this time.
0 commit comments