From cc24d478aafd2054e84e1b0ebdf98e9a0ede99f9 Mon Sep 17 00:00:00 2001 From: Dan Brown Date: Sat, 13 Apr 2019 12:46:15 +0100 Subject: [PATCH] Organised entity action buttons a little more --- resources/assets/sass/_blocks.scss | 2 +- resources/assets/sass/_lists.scss | 11 ++++++++++ resources/views/books/index.blade.php | 3 ++- resources/views/books/show.blade.php | 28 ++++++++++++++---------- resources/views/chapters/show.blade.php | 29 +++++++++++++++---------- resources/views/pages/show.blade.php | 27 +++++++++++++---------- resources/views/shelves/index.blade.php | 2 +- 7 files changed, 64 insertions(+), 38 deletions(-) diff --git a/resources/assets/sass/_blocks.scss b/resources/assets/sass/_blocks.scss index e1a2f9e1f..278917cd5 100644 --- a/resources/assets/sass/_blocks.scss +++ b/resources/assets/sass/_blocks.scss @@ -176,7 +176,7 @@ } .content-wrap.card { - padding: $-l $-xxl; + padding: $-m $-xxl; margin-left: auto; margin-right: auto; margin-bottom: $-xl; diff --git a/resources/assets/sass/_lists.scss b/resources/assets/sass/_lists.scss index a8f0113b8..dc4dc8816 100644 --- a/resources/assets/sass/_lists.scss +++ b/resources/assets/sass/_lists.scss @@ -363,6 +363,17 @@ ul.pagination { } } +.icon-list hr { + margin: $-s $-m; + max-width: 140px; + opacity: 0.25; + height: 1.1px; +} + +.icon-list hr + hr, .icon-list hr:first-child, .icon-list hr:last-child { + display: none; +} + .entity-list-item, .icon-list-item { padding: $-s $-m; display: flex; diff --git a/resources/views/books/index.blade.php b/resources/views/books/index.blade.php index bdfe4a480..38286c201 100644 --- a/resources/views/books/index.blade.php +++ b/resources/views/books/index.blade.php @@ -38,13 +38,14 @@
{{ trans('common.actions') }}
- @include('partials.view-toggle', ['view' => $view, 'type' => 'book']) @if($currentUser->can('book-create-all')) @icon('add') {{ trans('entities.books_create') }} @endif + + @include('partials.view-toggle', ['view' => $view, 'type' => 'book'])
diff --git a/resources/views/books/show.blade.php b/resources/views/books/show.blade.php index 792d8ecc4..3141f5ab2 100644 --- a/resources/views/books/show.blade.php +++ b/resources/views/books/show.blade.php @@ -80,17 +80,6 @@
{{ trans('common.actions') }}
diff --git a/resources/views/chapters/show.blade.php b/resources/views/chapters/show.blade.php index 8eddd5851..f74c584e5 100644 --- a/resources/views/chapters/show.blade.php +++ b/resources/views/chapters/show.blade.php @@ -87,24 +87,15 @@
{{ trans('common.actions') }}
- - @if(userCan('page-create', $chapter)) @icon('add') {{ trans('entities.pages_new') }} @endif + +
+ @if(userCan('chapter-update', $chapter)) @icon('edit') @@ -129,6 +120,20 @@ {{ trans('common.delete') }} @endif + +
+ +
@stop diff --git a/resources/views/pages/show.blade.php b/resources/views/pages/show.blade.php index 10b001be5..91a90cb00 100644 --- a/resources/views/pages/show.blade.php +++ b/resources/views/pages/show.blade.php @@ -124,18 +124,6 @@
Actions
- {{--Export--}} - {{--User Actions--}} @if(userCan('page-update', $page)) @@ -174,6 +162,21 @@ {{ trans('common.delete') }} @endif + +
+ + {{--Export--}} +
diff --git a/resources/views/shelves/index.blade.php b/resources/views/shelves/index.blade.php index eeb579de6..76f26c694 100644 --- a/resources/views/shelves/index.blade.php +++ b/resources/views/shelves/index.blade.php @@ -9,13 +9,13 @@
{{ trans('common.actions') }}
- @include('partials.view-toggle', ['view' => $view, 'type' => 'shelf']) @if($currentUser->can('bookshelf-create-all')) @icon('add') {{ trans('entities.shelves_create') }} @endif + @include('partials.view-toggle', ['view' => $view, 'type' => 'shelf'])