Add config option to disable auto-expanding folders (#367)

This commit is contained in:
cyberme0w 2024-03-16 12:21:14 +00:00 • committed by GitHub
parent 260fe3718a
commit c1b3597b8c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 3 additions and 0 deletions

View file

@ -53,6 +53,7 @@ func (gt *GuildsTree) createGuildFolderNode(parent *tview.TreeNode, gf gateway.G
}
n := tview.NewTreeNode(name)
n.SetExpanded(cfg.Theme.GuildsTree.AutoExpandFolders)
parent.AddChild(n)
for _, gid := range gf.GuildIDs {

View file

@ -66,6 +66,7 @@ type Config struct {
BackgroundColor string `yaml:"background_color"`
GuildsTree struct {
AutoExpandFolders bool `yaml:"auto_expand_folders"`
Graphics bool `yaml:"graphics"`
} `yaml:"guilds_tree"`

View file

@ -49,6 +49,7 @@ theme:
background_color: default
guilds_tree:
auto_expand_folders: true
graphics: true
messages_text: