tile-view: fix number of columns calculation
This commit is contained in:
parent
145596ac6a
commit
b70633ef24
|
@ -31,7 +31,7 @@ export function getCurrentLayout(state: Object) {
|
||||||
export function getMaxColumnCount() {
|
export function getMaxColumnCount() {
|
||||||
const configuredMax = interfaceConfig.TILE_VIEW_MAX_COLUMNS || 5;
|
const configuredMax = interfaceConfig.TILE_VIEW_MAX_COLUMNS || 5;
|
||||||
|
|
||||||
return Math.max(Math.min(configuredMax, 1), 5);
|
return Math.min(Math.max(configuredMax, 1), 5);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue