Skip to content

Commit

Permalink
fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
freekmurze committed Aug 22, 2018
1 parent 6b4ac9d commit 86ee45b
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions resources/js/tool.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
Nova.booting((Vue, router) => {
router.addRoutes([
{
name: '{{ component }}',
path: '/{{ component }}',
name: ':package_name',
path: '/:package_name',
component: require('./components/Tool'),
},
])
Expand Down
2 changes: 1 addition & 1 deletion resources/views/navigation.blade.php
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<router-link tag="h3" :to="{name: '{{ component }}'}" class="cursor-pointer flex items-center font-normal dim text-white mb-6 text-base no-underline">
<router-link tag="h3" :to="{name: ':package_name'}" class="cursor-pointer flex items-center font-normal dim text-white mb-6 text-base no-underline">
<svg class="sidebar-icon" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20"><path fill="#B3C1D1" d="M3 1h4c1.1045695 0 2 .8954305 2 2v4c0 1.1045695-.8954305 2-2 2H3c-1.1045695 0-2-.8954305-2-2V3c0-1.1045695.8954305-2 2-2zm0 2v4h4V3H3zm10-2h4c1.1045695 0 2 .8954305 2 2v4c0 1.1045695-.8954305 2-2 2h-4c-1.1045695 0-2-.8954305-2-2V3c0-1.1045695.8954305-2 2-2zm0 2v4h4V3h-4zM3 11h4c1.1045695 0 2 .8954305 2 2v4c0 1.1045695-.8954305 2-2 2H3c-1.1045695 0-2-.8954305-2-2v-4c0-1.1045695.8954305-2 2-2zm0 2v4h4v-4H3zm10-2h4c1.1045695 0 2 .8954305 2 2v4c0 1.1045695-.8954305 2-2 2h-4c-1.1045695 0-2-.8954305-2-2v-4c0-1.1045695.8954305-2 2-2zm0 2v4h4v-4h-4z"/></svg>
<span class="sidebar-label">
{{ title }}
Expand Down
6 changes: 3 additions & 3 deletions src/Tool.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ class Tool extends BaseTool
*/
public function boot()
{
Nova::script('{{ component }}', __DIR__.'/../dist/js/tool.js');
Nova::style('{{ component }}', __DIR__.'/../dist/css/tool.css');
Nova::script(':package_name', __DIR__.'/../dist/js/tool.js');
Nova::style(':package_name', __DIR__.'/../dist/css/tool.css');
}

/**
Expand All @@ -25,6 +25,6 @@ public function boot()
*/
public function renderNavigation()
{
return view('{{ component }}::navigation');
return view(':package_name::navigation');
}
}
2 changes: 1 addition & 1 deletion src/ToolServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ class ToolServiceProvider extends ServiceProvider
*/
public function boot()
{
$this->loadViewsFrom(__DIR__.'/../resources/views', '{{ component }}');
$this->loadViewsFrom(__DIR__.'/../resources/views', ':package_name');

$this->app->booted(function () {
$this->routes();
Expand Down

0 comments on commit 86ee45b

Please sign in to comment.