Fix sidebar and tab overflow navigation
This commit is contained in:
@@ -13,10 +13,16 @@ const leafTypes: Set<TreeNodeType> = new Set([
|
||||
"saved-sql-file",
|
||||
]);
|
||||
|
||||
const fullWidthLabelTypes: Set<TreeNodeType> = new Set(["table", "view", "mongo-collection"]);
|
||||
|
||||
export function treeItemPaddingLeft(depth: number): string {
|
||||
return `${depth * 16 + 8}px`;
|
||||
}
|
||||
|
||||
export function usesFullWidthTreeLabel(type: TreeNodeType): boolean {
|
||||
return fullWidthLabelTypes.has(type);
|
||||
}
|
||||
|
||||
export function canTreeNodeExpand(type: TreeNodeType): boolean {
|
||||
return !leafTypes.has(type);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user