NavigationSidebarController<T> constructor
NavigationSidebarController<T> ({})
Implementation
NavigationSidebarController({
required List<NavSection<T>> sections,
NavNodeId? active,
Set<NavNodeId>? expanded,
bool collapsed = false,
bool drawerOpen = false,
bool autoExpandActive = true,
}) : _sections = List.unmodifiable(sections),
_active = active,
_expanded = {...?expanded},
_collapsed = collapsed,
_drawerOpen = drawerOpen,
_autoExpandActive = autoExpandActive {
if (_autoExpandActive && active != null) {
_expanded.addAll(NavOps.ancestorsOf<T>(_sections, active));
}
}