Navigation
Module reahl.web.bootstrap.navs¶
Examples in this section
- tutorial.pageflow2bootstrap
Get a copy of an example by running:
reahl example <examplename>
New in version 3.2.
A Bootstrap “Nav” is a navigation menu: a list of items that are links to other Views. Navs can also have a second level so that if you click on an item, a dropdown list of vertically stacked options appear.
This module contains the necessary Widgets and Layouts to create and style Bootstrap Navs.
Nav¶
-
class
reahl.web.bootstrap.navs.
Nav
(view, a_list=None, css_id=None)¶ A Nav is a navigation menu, with items a user can click on to transition to possibly different Views. Individual Items visually indicate whether they are active or disabled.
Note
Don’t be confused
This, the
reahl.web.bootstrap.navs.Nav
is not the same thing as a simple HTML-levelreahl.web.bootstrap.ui.Nav
!Parameters: - view – (See
Widget
) - a_list – A list of
A
s representing the items. - css_id – (See
HTMLElement
)
-
add_dropdown
(title, dropdown_menu, drop_up=False, query_arguments={})¶ Adds the dropdown_menu
DropdownMenu
to this Nav. It appears as the top-level item with text title.Parameters: - drop_up – If True, the dropdown will drop upwards from its item, instead of down.
- query_arguments – (For internal use)
- view – (See
PillLayout¶
-
class
reahl.web.bootstrap.navs.
PillLayout
(stacked=False, justified=False)¶ This Layout makes a Nav appear as horizontally or vertically arranged pills (buttons).
Parameters: - stacked – If True, the pills are stacked vertically.
- justified – If True, the pills are widened to fill all available space.
TabLayout¶
-
class
reahl.web.bootstrap.navs.
TabLayout
(justified=False)¶ This Layout makes a Nav appear as horizontal tabs.
Parameters: justified – If True, the tabs are widened to fill all available space.
Table Of Contents
Previous topic
Package reahl.web.bootstrap.tables
Next topic
Module reahl.web.bootstrap.navbar