mirror of
https://github.com/appwrite/console.git
synced 2026-06-06 19:27:48 +00:00
update: safe fallback.
This commit is contained in:
+4
-1
@@ -348,7 +348,10 @@
|
||||
columnsWithBase.reduce((sum, col) => sum + col.baseWidth, 0);
|
||||
|
||||
// distribute excess space equally across custom columns
|
||||
const viewportWidth = spreadsheetContainer?.clientWidth || window.innerWidth;
|
||||
const viewportWidth =
|
||||
spreadsheetContainer?.clientWidth ||
|
||||
(typeof window !== 'undefined' ? window.innerWidth : totalUsed);
|
||||
|
||||
const extraPerColumn =
|
||||
Math.max(0, viewportWidth - totalUsed) / (columnsWithBase.length || 1);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user