// Copyright (c) 2021 David Vogel // // This software is released under the MIT License. // https://opensource.org/licenses/MIT package navigation import "github.com/vugu/vugu" type Sidebar struct { AttrMap vugu.AttrMap Entries vugu.Builder // Main content of the sidebar. Basically the menu entries. BottomEntries vugu.Builder // Static bottom part of the sidebar. Body vugu.Builder // The body contains the content that is right to or behind the sidebar. Width float64 // Width of the sidebar in DOM pixels. } func (s *Sidebar) Init(ctx vugu.InitCtx) { s.Width = 300 // Default width in pixels. }