1 | <?php |
||
2 | |||
3 | namespace SleepingOwl\Admin\Widgets; |
||
4 | |||
5 | use SleepingOwl\Admin\Facades\Template as AdminTemplate; |
||
6 | |||
7 | class EnvEditor extends Widget |
||
8 | { |
||
9 | /** |
||
10 | * @return bool |
||
11 | */ |
||
12 | public function active() |
||
13 | { |
||
14 | return config('sleeping_owl.show_editor'); |
||
15 | } |
||
16 | |||
17 | /** |
||
18 | * @return string |
||
19 | * @throws \Throwable |
||
20 | */ |
||
21 | public function toHtml() |
||
22 | { |
||
23 | return view(AdminTemplate::getViewPath('_partials.env_editor'))->render(); |
||
0 ignored issues
–
show
Bug
introduced
by
![]() |
|||
24 | } |
||
25 | |||
26 | /** |
||
27 | * @return string|array |
||
28 | */ |
||
29 | public function template() |
||
30 | { |
||
31 | return AdminTemplate::getViewPath('_partials.header'); |
||
32 | } |
||
33 | |||
34 | /** |
||
35 | * @return string |
||
36 | */ |
||
37 | public function block() |
||
38 | { |
||
39 | return 'navbar.right'; |
||
40 | } |
||
41 | } |
||
42 |