]> BookStack Code Mirror - bookstack/blobdiff - app/Uploads/ImageRepo.php
Add the "Create Shelf" resp. "Create Book" to the home view
[bookstack] / app / Uploads / ImageRepo.php
index 16d1bb3d1ff5c4d3cdbf14ffe24f9577f446b0ea..da0b7d379eddd2fb4a227dd071af248c2ba44d07 100644 (file)
@@ -25,8 +25,7 @@ class ImageRepo
         ImageService $imageService,
         PermissionService $permissionService,
         Page $page
-    )
-    {
+    ) {
         $this->image = $image;
         $this->imageService = $imageService;
         $this->restrictionService = $permissionService;
@@ -87,8 +86,7 @@ class ImageRepo
         int $uploadedTo = null,
         string $search = null,
         callable $whereClause = null
-    )
-    {
+    ) {
         $imageQuery = $this->image->newQuery()->where('type', '=', strtolower($type));
 
         if ($uploadedTo !== null) {
@@ -126,13 +124,12 @@ class ImageRepo
         int $pageSize = 24,
         int $uploadedTo = null,
         string $search = null
-    )
-    {
+    ) {
         $contextPage = $this->page->findOrFail($uploadedTo);
         $parentFilter = null;
 
         if ($filterType === 'book' || $filterType === 'page') {
-            $parentFilter = function(Builder $query) use ($filterType, $contextPage) {
+            $parentFilter = function (Builder $query) use ($filterType, $contextPage) {
                 if ($filterType === 'page') {
                     $query->where('uploaded_to', '=', $contextPage->id);
                 } elseif ($filterType === 'book') {
@@ -233,7 +230,7 @@ class ImageRepo
     {
         $image->thumbs = [
             'gallery' => $this->getThumbnail($image, 150, 150, false),
-            'display' => $this->getThumbnail($image, 840, null, true)
+            'display' => $this->getThumbnail($image, 1680, null, true)
         ];
     }