Skip to content

Commit

Permalink
fixed dynamic property creation
Browse files Browse the repository at this point in the history
  • Loading branch information
denisdulici committed Oct 17, 2023
1 parent f0fba35 commit 5177c7c
Showing 1 changed file with 52 additions and 13 deletions.
65 changes: 52 additions & 13 deletions src/MenuItem.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,23 +4,12 @@

use Closure;
use Collective\Html\HtmlFacade as HTML;
use Illuminate\Contracts\Support\Arrayable as ArrayableContract;
use Illuminate\Contracts\Support\Arrayable;
use Illuminate\Support\Facades\Request;
use Illuminate\Support\Arr;
use Illuminate\Support\Str;

/**
* @property string url
* @property string route
* @property string title
* @property string name
* @property string icon
* @property int parent
* @property array attributes
* @property bool active
* @property int order
*/
class MenuItem implements ArrayableContract
class MenuItem implements Arrayable
{
/**
* Array properties.
Expand Down Expand Up @@ -55,6 +44,56 @@ class MenuItem implements ArrayableContract
'hideWhen',
];

/**
* @var string
*/
protected $url;

/**
* @var string
*/
protected $route;

/**
* @var string
*/
protected $fragment;

/**
* @var string
*/
protected $title;

/**
* @var string
*/
protected $name;

/**
* @var string
*/
protected $icon;

/**
* @var int
*/
protected $parent;

/**
* @var array
*/
protected $attributes;

/**
* @var bool
*/
protected $active;

/**
* @var int
*/
protected $order;

/**
* The hideWhen callback.
*
Expand Down

0 comments on commit 5177c7c

Please sign in to comment.