41 lines
864 B
PHP
41 lines
864 B
PHP
|
<?php
|
||
|
namespace nur\v\html5;
|
||
|
|
||
|
use nur\A;
|
||
|
use nur\v\base\TagsManager;
|
||
|
use nur\v\model\INavbarManager;
|
||
|
use nur\v\v;
|
||
|
|
||
|
class Html5NavbarManager extends TagsManager implements INavbarManager {
|
||
|
function start($options=null): array {
|
||
|
$start = v::sdiv(["class" => ["navigation"]]);
|
||
|
$end = v::ediv();
|
||
|
return $this->push("navbar", $start, $end);
|
||
|
}
|
||
|
|
||
|
function end(): array {
|
||
|
return $this->pop("navbar");
|
||
|
}
|
||
|
|
||
|
function started(): bool {
|
||
|
return $this->haveMark("navbar");
|
||
|
}
|
||
|
|
||
|
function startNav($options=null): array {
|
||
|
$content = null;
|
||
|
A::append_nn($content, $this->pop("nav"));
|
||
|
A::append_nn($content, $this->push("nav"));
|
||
|
return $content;
|
||
|
}
|
||
|
|
||
|
function navItem($item): array {
|
||
|
return [];
|
||
|
}
|
||
|
|
||
|
function endNav(): array {
|
||
|
$content = $this->pop("nav");
|
||
|
if ($content === null) $content = [];
|
||
|
return $content;
|
||
|
}
|
||
|
}
|