-
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
0bcc9f7
commit d830bdb
Showing
2 changed files
with
9 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,7 +8,7 @@ | |
* MarkupMenu is a module for generating menu markup. See README.md for more details. | ||
* Some ideas and code in this module are based on the Markup Simple Navigation module. | ||
* | ||
* @version 1.1.1 | ||
* @version 1.2.0 | ||
* @author Teppo Koivula <[email protected]> | ||
* @license Mozilla Public License v2.0 http://mozilla.org/MPL/2.0/ | ||
*/ | ||
|
@@ -103,9 +103,9 @@ public function render(array $options = []): string { | |
* Render menu from fixed array of items | ||
* | ||
* @param array $options Options for rendering | ||
* @param array|null $root Root item for the menu | ||
* @param array $items Menu items | ||
* @param int $level Current tree level (depth) | ||
* @param array|null $root Root item for the menu | ||
* @return string Rendered menu markup | ||
*/ | ||
protected function renderArray(array $options = [], ?array $root, array $items, int $level = 1): string { | ||
|
@@ -123,6 +123,7 @@ protected function renderArray(array $options = [], ?array $root, array $items, | |
$placeholders = [ | ||
'level' => $level, | ||
'root_page' => $options['root_page'], | ||
'root' => $root, | ||
]; | ||
|
||
// generate list markup | ||
|
@@ -167,6 +168,7 @@ protected function renderTree(array $options = [], Page $root = null, PageArray | |
$placeholders = [ | ||
'level' => $level, | ||
'root_page' => $options['root_page'], | ||
'root' => $root, | ||
]; | ||
|
||
// generate list markup | ||
|