Skip to content

Commit a7746ce

Browse files
authored
Merge pull request #94 from ypnos-web/patch-2
Extend and clarify documentation
2 parents 522f2b4 + cb97cfd commit a7746ce

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

src/View/Helper/BootstrapNavbarHelper.php

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -176,6 +176,8 @@ public function create ($brand, $options = []) {
176176
/**
177177
*
178178
* Add a link to the navbar or to a menu.
179+
* Links outside a menu are realized as buttons. Encapsulate links with
180+
* beginMenu(), endMenu() to create a horizontal hover menu in the navbar.
179181
*
180182
* @param name The link text
181183
* @param url The link URL
@@ -284,8 +286,12 @@ public function searchForm ($model = null, $options = []) {
284286

285287
/**
286288
*
287-
* Start a new menu, 2 levels: If not in submenu, create a dropdown menu,
288-
* oterwize create hover menu.
289+
* Start a new menu. Two types of menus exist: Horizontal hover menu in the
290+
* navbar (level 0) and vertical dropdown menu (level 1). The menu level is
291+
* determined automatically: A dropdown menu needs to be part of a hover menu.
292+
* In the hover menu case, pass the options array as the first argument.
293+
* Populate the menu with link(), divider(), and sub menus.
294+
* Use 'class' => 'navbar-right' option for flush right.
289295
*
290296
* @param name The name of the menu
291297
* @param url A URL for the menu (default null)

0 commit comments

Comments
 (0)