Commits

pietschy committed 6c8c4e0

added 'join' render model

Comments (0)

Files changed (3)

elements/navigation_builder/default/nav_item.php

 }
 ?>
 <li class="<?= join(' ', $classNames)?>">
+    <?
+    $joinContent = $navItem->getRenderOption('join');
+    if ($joinContent && !$navItem->isFirstChild()):?>
+    <span class="join"><?= $joinContent ?></span>
+    <? endif ?>
+
     <a href="<?=$navItem->getURL()?>" class="<?= join(' ', $anchorClassNames)?>" target="<?=$navItem->getTarget()?>"><?=$navItem->getName()?></a>
     <? if ($navItem->hasChildren()) { ?>
     <ul>

elements/navigation_builder/folding_nav/nav_item.php

 $text = $navItem->getName();
 ?>
 <li class="<?= join(' ', $liClassNames)?>">
-    <a href="<?=$navItem->getURL()?>" class="<?= join(' ', $anchorClassNames)?>" target="<?=$navItem->getTarget()?>"><?=$text?></a>
+    <?
+    $joinContent = $navItem->getRenderOption('join');
+    if ($joinContent && !$navItem->isFirstChild()):?>
+    <span class="join"><?= $joinContent ?></span>
+    <? endif ?>    <a href="<?=$navItem->getURL()?>" class="<?= join(' ', $anchorClassNames)?>" target="<?=$navItem->getTarget()?>"><?=$text?></a>
     <? if ($navItem->hasChildren()) { ?>
     <a href="#" class="open-toggle"><span> </span></a>
     <ul>

elements/navigation_builder/nav_bar/nav_item.php

 <?php defined('C5_EXECUTE') or die("Access Denied.");
-/** @var NavItem $navItem*/
+/** @var NavItem $navItem */
 if (!isset($navItem)) {
     throw new Exception('Required parameter $navItem is missing');
 }
-/** @var NavItem $navItem */
 $classNames = $navItem->getClassNames();
 if ($navItem->isFirstChild()) {
     $classNames[] = 'first-child';
 }
 ?>
 <li class="<?= join(' ', $classNames)?>">
-    <a href="<?=$navItem->getURL()?>" class="<?= join(' ', $anchorClassNames)?>" target="<?=$navItem->getTarget()?>"><?=$navItem->getName()?></a>
+<?
+$joinContent = $navItem->getRenderOption('join');
+if ($joinContent && !$navItem->isFirstChild()):?>
+<span class="join"><?= $joinContent ?></span>
+<? endif ?>
+    <a href="<?=$navItem->getURL()?>" class="<?= join(' ', $anchorClassNames)?>"
+       target="<?=$navItem->getTarget()?>"><?=$navItem->getName()?></a>
     <? if ($navItem->hasChildren()) { ?>
     <a href="#" class="flyout-toggle"><span> </span></a>
     <ul class="flyout">
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.