Skip to content

Commit b5a8fec

Browse files
committed
Null check for container width
1 parent 11c6c68 commit b5a8fec

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/filebrowser/src/listing.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -812,7 +812,7 @@ export class DirListing extends Widget {
812812
// Update the modified column's size
813813
private _updateModifiedSize(node: HTMLElement) {
814814
const modified = DOMUtils.findElement(node, ITEM_MODIFIED_CLASS);
815-
this._modifiedWidth = modified.getBoundingClientRect().width;
815+
this._modifiedWidth = modified?.getBoundingClientRect().width ?? 83;
816816
this._modifiedStyle =
817817
this._modifiedWidth < 90
818818
? 'narrow'

0 commit comments

Comments
 (0)