ivopetkov / navigation-menu-bearframework-addon
Navigation menu addon for Bear Framework
Installs: 2 162
Dependents: 1
Suggesters: 0
Security: 0
Stars: 0
Watchers: 4
Forks: 0
Open Issues: 0
Language:JavaScript
Requires
- php: 7.1.*|7.2.*|7.3.*|7.4.*|8.0.*|8.1.*|8.2.*|8.3.*
- bearframework/bearframework: 1.*
- ivopetkov/client-packages-bearframework-addon: 1.*
- ivopetkov/html-server-components-bearframework-addon: 1.*
- ivopetkov/html5-dom-document-php: 2.*
- ivopetkov/responsive-attributes-bearframework-addon: 1.*
Requires (Dev)
- dev-master
- v1.5.0
- v1.4.1
- v1.4.0
- v1.3.1
- v1.3.0
- v1.2.0
- v1.1.0
- v1.0.1
- v1.0.0
- v0.1.12
- v0.1.11
- v0.1.10
- v0.1.9
- v0.1.8
- v0.1.7
- v0.1.6
- v0.1.5
- v0.1.4
- v0.1.3
- v0.1.2
- v0.1.1
- v0.1.0
- v0.1.0-beta.7
- v0.1.0-beta.6
- v0.1.0-beta.5
- v0.1.0-beta.4
- v0.1.0-beta.3
- v0.1.0-beta.2
- v0.1.0-beta.1
- v0.0.7
- v0.0.6
- v0.0.5
- v0.0.4
- v0.0.3
- v0.0.2
- v0.0.1
This package is auto-updated.
Last update: 2024-12-03 15:16:00 UTC
README
Addon for Bear Framework
This addon enables you to easily create multiple types of navigations for your website.
Download and install
Install via Composer
composer require ivopetkov/navigation-menu-bearframework-addon
Download an archive
Download the latest release from the GitHub page and include the autoload file.
include '/path/to/the/addon/autoload.php';
Enable the addon
Enable the addon for your Bear Framework application.
$app->addons->add('ivopetkov/navigation-menu-bearframework-addon');
Usage
<component src="navigation-menu"> <ul> <li><a>Button 1</a></li> <li><a>Button 2</a> <ul> <li><a>Button 2.1</a></li> <li><a>Button 2.2</a></li> <li><a>Button 2.3</a></li> </ul> </li> <li><a>Button 3</a></li> </ul> </component>
Attributes
type
The type of the navigation. Available values: horizontal-down, vertical-left, vertical-right, list-vertical, list-horizontal
moreItemHtml
The HTML code for the more item. Must contain li and ul tags. Example: <li><a>...</a><ul></ul></li>
class
HTML class attribute value
style
HTML style attribute value
Examples
The navigation will be horizontal and submenus will show bellow. If there are too many first level items, a more item will be shown.
<component src="navigation-menu" type="horizontal-down"> <ul> <li><a>Button 1</a></li> <li><a>Button 2</a> <ul> <li><a>Button 2.1</a></li> <li><a>Button 2.2</a></li> <li><a>Button 2.3</a></li> </ul> </li> <li><a>Button 3</a></li> </ul> </component>
The navigation will be vertical and submenus will open to the right.
<component src="navigation-menu" type="vertical-right"> <ul> <li><a>Button 1</a></li> <li><a>Button 2</a> <ul> <li><a>Button 2.1</a></li> <li><a>Button 2.2</a></li> <li><a>Button 2.3</a></li> </ul> </li> <li><a>Button 3</a></li> </ul> </component>
License
Navigation menu addon for Bear Framework is open-sourced software. It's free to use under the MIT license. See the license file for more information.
Author
This addon is created by Ivo Petkov. Feel free to contact me at @IvoPetkovCom or ivopetkov.com.