| 1 | <?php |
||
| 12 | trait Insertable |
||
| 13 | { |
||
| 14 | /** |
||
| 15 | * Let the add method know not to append this item as it was spliced into the array. |
||
| 16 | * |
||
| 17 | * @var bool |
||
| 18 | */ |
||
| 19 | public $insert = false; |
||
| 20 | |||
| 21 | /** |
||
| 22 | * Insert this item after another item in the menu |
||
| 23 | * |
||
| 24 | * @param $slug |
||
| 25 | */ |
||
| 26 | public function insertAfter($slug) |
||
| 30 | |||
| 31 | /** |
||
| 32 | * Insert this item before another item in the menu |
||
| 33 | * |
||
| 34 | * @param $slug |
||
| 35 | */ |
||
| 36 | public function insertBefore($slug) |
||
| 40 | |||
| 41 | /** |
||
| 42 | * @param $slug |
||
| 43 | * @param $after |
||
| 44 | */ |
||
| 45 | private function insertObject($slug, $after = false) |
||
| 71 | } |
||
| 72 |