Commit graph

54 commits

Author SHA1 Message Date
Bastian Lederer
ea0ce32bc9 Change implicit nullable type declaration to explicit
Since PHP 8.4 implicitly nullable parameter types are deprecated.

Normalize scoped PHPDoc for nullable-parameter updates: use `?Type` instead of
`Type|null`, remove column alignment, and indent continuation lines with 2
spaces.

Co-authored-by: "Eric Lippmann <eric.lippmann@icinga.com>"
2026-03-10 16:40:27 +01:00
Sukhwinder Dhillon
e2e582b095 Navigation/-Item: Fix Variable '$classPath' is probably undefined 2023-08-23 10:53:14 +02:00
Johannes Meyer
c038e84fc2 Ensure Return Type Compatibility with Internal Classes 2022-03-24 12:29:06 +01:00
Eric Lippmann
7e7e2415dc Support $user.local_name$ macro in navigation items 2021-06-28 14:26:38 +02:00
Jennifer Mourek
b3b80fdc31 Make active first-level nav items better distinguishable 2019-03-20 11:07:39 +01:00
Eric Lippmann
b6b87796ed Menu: Link to the navigation dashboard if menu entry has children but no URL 2017-11-21 22:55:45 +01:00
Eric Lippmann
3660606ca1 Allow to set a description for navigation items
We will introduce a navigation dashboard for root menu items which do not a have a URL but children.
2017-11-21 22:55:45 +01:00
Johannes Meyer
181e2ef05c Swag: Fix swag (aka a whole bunch of code style issues..) 2017-01-27 14:48:59 +01:00
Eric Lippmann
a9461ada54 Only render a menu item when it's not empty
A menu item is not empty when it either has children or a defined URL.
2016-11-28 14:56:17 +01:00
Alexander A. Klimov
eecd15ee68 NavigationItem: fall back to the default renderer if an error occurrs
fixes #10486
2016-04-25 15:26:08 +02:00
Alexander A. Klimov
474803fee4 Change all license headers to only reflect a file's year of creation
refs #11000
2016-02-08 15:41:00 +01:00
Eric Lippmann
3d2521abf0 Merge branch 'master' into feature/dope-layout-5543 2015-10-01 17:42:24 +02:00
Johannes Meyer
0cc06d6af9 NavigationItem: Improve merge "algorithm" 2015-10-01 17:12:55 +02:00
Johannes Meyer
d54e5f62e6 NavigationItem: Accept priority while merging if none is set yet 2015-10-01 16:32:47 +02:00
Eric Lippmann
ed6da19876 lib: Support setting CSS class for li on navigation items
refs #5543
2015-09-28 16:39:28 +02:00
Eric Lippmann
63e0549618 Navigation: Support empty labels for creating containers
refs #5543
2015-09-27 15:42:26 +02:00
Johannes Meyer
76cf01869e NavigationItem: Add property $target
refs #5600
2015-09-21 10:18:46 +02:00
Johannes Meyer
bf4e492fa1 Action: Accept and apply option "filter"
refs #5600
2015-09-17 11:00:40 +02:00
Johannes Meyer
b1ee12f721 NavigationItem: Allow to dynamically decide whether to render an item
refs #5600
2015-09-17 09:11:17 +02:00
Johannes Meyer
21180e2fd4 NavigationItem: Fix method conflictsWith()
...

refs #5600
2015-09-07 13:26:44 +02:00
Johannes Meyer
bf2cb9ab7e NavigationItem: Provide a more sophisticated conflict detection
refs #5600
2015-09-07 13:20:49 +02:00
Johannes Meyer
0feaec7af1 NavigationItem: Return a instance of Url in method getUrl(), really
refs #5600
2015-09-07 13:20:17 +02:00
Johannes Meyer
451a0c91f2 NavigationItem: Add missing return statement in method merge()
refs #5600
2015-09-07 13:19:36 +02:00
Johannes Meyer
f9b68b683b NavigationItem: Consider unknown properties as element attributes
refs #5600
2015-09-07 09:49:05 +02:00
Johannes Meyer
2af06e9415 NavigationItem: Re-introduce a default priority of 100
refs #5600
2015-09-04 14:20:21 +02:00
Johannes Meyer
1a42c04c8e NavigationItem: Fix locating a module's custom navigation renderer
refs #5600
2015-09-04 13:47:17 +02:00
Johannes Meyer
07588595f2 NavigationItem: Automatically determine whether it's active or not
refs #5600
2015-09-04 10:10:33 +02:00
Johannes Meyer
975cc92f6b NavigationItem: Provide "#" as default url for items with children
refs #5600
2015-09-04 09:31:23 +02:00
Johannes Meyer
a8d5a78aa2 NavigationItem: Fix method getUniqueName()
refs #5600
2015-09-04 09:25:25 +02:00
Johannes Meyer
7adfc58878 NavigationItem: Add missing return keyword in method render()
refs #5600
2015-09-03 15:04:39 +02:00
Johannes Meyer
9a725330fb NavigationItem: Provide the item to the renderer before calling render
refs #5600
2015-09-03 14:22:38 +02:00
Johannes Meyer
67dee62c57 NavigationItemRenderer: Add support for options
refs #5600
2015-09-03 13:36:13 +02:00
Johannes Meyer
2834e206d5 NavigationItem: Add support for custom renderers
refs #5600
2015-09-03 11:25:51 +02:00
Johannes Meyer
811269df01 NavigationItem: Rename method getView() to view()
refs #5600
2015-09-03 10:39:11 +02:00
Johannes Meyer
206168672b NavigationItem: Add method getUniqueName()
refs #5600
2015-09-03 10:22:47 +02:00
Johannes Meyer
537db6000e NavigationItem: Add method merge()
refs #5600
2015-09-03 09:56:22 +02:00
Johannes Meyer
a626e8f7fb NavigationItem: Allow to set and get single url parameters
refs #5600
2015-09-03 09:56:02 +02:00
Johannes Meyer
00447488ee NavigationItem: Drop interface Countable
$item->count(), count of what?
$item->getChildren()->count(), Its children, of course!

refs #5600
2015-09-03 08:49:30 +02:00
Johannes Meyer
f4a6ab73c0 NavigationItem: Add property priority
refs #5600
2015-09-03 08:33:13 +02:00
Johannes Meyer
1393db687b NavigationItem: Adjust some docblocks
refs #5600
2015-09-02 15:42:54 +02:00
Johannes Meyer
298c4ad38b NavigationItem: Cast a string to Url already in setUrl()
refs #5600
2015-09-02 15:35:08 +02:00
Johannes Meyer
1788cc9b6a NavigationItem: Use setView() to initiliaze $view
refs #5600
2015-09-02 15:33:45 +02:00
Johannes Meyer
6802c0a9e4 NavigationItem: Do not disable the complete parent hierarchy..
..if just a child gets deactivated.

refs #5600
2015-09-02 15:32:37 +02:00
Johannes Meyer
2bfeb335a5 NavigationItem: Add method setParent() and getParent()
refs #5600
2015-09-02 15:30:35 +02:00
Johannes Meyer
e2beb7d027 NavigationItem: Return the name if no label is set in getLabel()
refs #5600
2015-09-02 15:27:34 +02:00
Johannes Meyer
1ef4a2f7d0 NavigationItem: Do not provide a default for setProperties()
refs #5600
2015-09-02 15:26:07 +02:00
Johannes Meyer
8a29660226 NavigationItem: Overwrite the property in method setAttributes()
A setter sets something instead of patching it.

refs #5600
2015-09-02 15:25:10 +02:00
Johannes Meyer
5efcb18fa0 NavigationItem: Set the parent on a child in method setChildren()
refs #5600
2015-09-02 15:21:40 +02:00
Johannes Meyer
c9050e2f21 NavigationItem: Initialize $children before setting the properties
refs #5600
2015-09-02 15:20:26 +02:00
Johannes Meyer
62f7a49a45 NavigationItem: Reduce code complexity in method addChild()
refs #5600
2015-09-02 15:17:26 +02:00