Merge branch 'master' into release

This commit is contained in:
Dan Brown 2018-05-28 14:19:04 +01:00
commit 9f961f95f8
No known key found for this signature in database
GPG Key ID: 46D9F943C24A2EF9
113 changed files with 1177 additions and 732 deletions

View File

@ -31,6 +31,9 @@ class Attachment extends Ownable
*/
public function getUrl()
{
if ($this->external && strpos($this->path, 'http') !== 0) {
return $this->path;
}
return baseUrl('/attachments/' . $this->id);
}
}

View File

@ -0,0 +1,83 @@
<?php
namespace BookStack\Console\Commands;
use BookStack\Services\ImageService;
use Illuminate\Console\Command;
use Symfony\Component\Console\Output\OutputInterface;
class CleanupImages extends Command
{
/**
* The name and signature of the console command.
*
* @var string
*/
protected $signature = 'bookstack:cleanup-images
{--a|all : Include images that are used in page revisions}
{--f|force : Actually run the deletions}
';
/**
* The console command description.
*
* @var string
*/
protected $description = 'Cleanup images and drawings';
protected $imageService;
/**
* Create a new command instance.
* @param ImageService $imageService
*/
public function __construct(ImageService $imageService)
{
$this->imageService = $imageService;
parent::__construct();
}
/**
* Execute the console command.
*
* @return mixed
*/
public function handle()
{
$checkRevisions = $this->option('all') ? false : true;
$dryRun = $this->option('force') ? false : true;
if (!$dryRun) {
$proceed = $this->confirm("This operation is destructive and is not guaranteed to be fully accurate.\nEnsure you have a backup of your images.\nAre you sure you want to proceed?");
if (!$proceed) {
return;
}
}
$deleted = $this->imageService->deleteUnusedImages($checkRevisions, $dryRun);
$deleteCount = count($deleted);
if ($dryRun) {
$this->comment('Dry run, No images have been deleted');
$this->comment($deleteCount . ' images found that would have been deleted');
$this->showDeletedImages($deleted);
$this->comment('Run with -f or --force to perform deletions');
return;
}
$this->showDeletedImages($deleted);
$this->comment($deleteCount . ' images deleted');
}
protected function showDeletedImages($paths)
{
if ($this->getOutput()->getVerbosity() <= OutputInterface::VERBOSITY_NORMAL) return;
if (count($paths) > 0) {
$this->line('Images to delete:');
}
foreach ($paths as $path) {
$this->line($path);
}
}
}

View File

@ -4,8 +4,6 @@ namespace BookStack\Exceptions;
use Exception;
use Illuminate\Auth\AuthenticationException;
use Illuminate\Http\Request;
use Illuminate\Pipeline\Pipeline;
use Illuminate\Validation\ValidationException;
use Illuminate\Database\Eloquent\ModelNotFoundException;
use Symfony\Component\HttpKernel\Exception\HttpException;
@ -33,6 +31,7 @@ class Handler extends ExceptionHandler
*
* @param \Exception $e
* @return mixed
* @throws Exception
*/
public function report(Exception $e)
{
@ -65,30 +64,12 @@ class Handler extends ExceptionHandler
// Handle 404 errors with a loaded session to enable showing user-specific information
if ($this->isExceptionType($e, NotFoundHttpException::class)) {
return $this->loadErrorMiddleware($request, function ($request) use ($e) {
$message = $e->getMessage() ?: trans('errors.404_page_not_found');
return response()->view('errors/404', ['message' => $message], 404);
});
return \Route::respondWithRoute('fallback');
}
return parent::render($request, $e);
}
/**
* Load the middleware required to show state/session-enabled error pages.
* @param Request $request
* @param $callback
* @return mixed
*/
protected function loadErrorMiddleware(Request $request, $callback)
{
$middleware = (\Route::getMiddlewareGroups()['web_errors']);
return (new Pipeline($this->container))
->send($request)
->through($middleware)
->then($callback);
}
/**
* Check the exception chain to compare against the original exception type.
* @param Exception $e

View File

@ -103,7 +103,7 @@ class AttachmentController extends Controller
$this->validate($request, [
'uploaded_to' => 'required|integer|exists:pages,id',
'name' => 'required|string|min:1|max:255',
'link' => 'url|min:1|max:255'
'link' => 'string|min:1|max:255'
]);
$pageId = $request->get('uploaded_to');
@ -131,7 +131,7 @@ class AttachmentController extends Controller
$this->validate($request, [
'uploaded_to' => 'required|integer|exists:pages,id',
'name' => 'required|string|min:1|max:255',
'link' => 'required|url|min:1|max:255'
'link' => 'required|string|min:1|max:255'
]);
$pageId = $request->get('uploaded_to');
@ -184,6 +184,7 @@ class AttachmentController extends Controller
* @param $attachmentId
* @return \Illuminate\Contracts\Routing\ResponseFactory|\Illuminate\Http\RedirectResponse|\Illuminate\Routing\Redirector|\Symfony\Component\HttpFoundation\Response
* @throws \Illuminate\Contracts\Filesystem\FileNotFoundException
* @throws NotFoundException
*/
public function get($attachmentId)
{

View File

@ -33,22 +33,41 @@ class HomeController extends Controller
$recents = $this->signedIn ? Views::getUserRecentlyViewed(12*$recentFactor, 0) : $this->entityRepo->getRecentlyCreated('book', 12*$recentFactor);
$recentlyUpdatedPages = $this->entityRepo->getRecentlyUpdated('page', 12);
// Custom homepage
$customHomepage = false;
$books = false;
$booksViewType = false;
// Check book homepage
$bookHomepageSetting = setting('app-book-homepage');
if ($bookHomepageSetting) {
$books = $this->entityRepo->getAllPaginated('book', 18);
$booksViewType = setting()->getUser($this->currentUser, 'books_view_type', config('app.views.books', 'list'));
} else {
// Check custom homepage
$homepageSetting = setting('app-homepage');
if ($homepageSetting) {
$id = intval(explode(':', $homepageSetting)[0]);
$customHomepage = $this->entityRepo->getById('page', $id, false, true);
$this->entityRepo->renderPage($customHomepage, true);
}
}
$view = $customHomepage ? 'home-custom' : 'home';
return view($view, [
$view = 'home';
if ($bookHomepageSetting) {
$view = 'home-book';
} else if ($customHomepage) {
$view = 'home-custom';
}
return view('common/' . $view, [
'activity' => $activity,
'recents' => $recents,
'recentlyUpdatedPages' => $recentlyUpdatedPages,
'draftPages' => $draftPages,
'customHomepage' => $customHomepage
'customHomepage' => $customHomepage,
'books' => $books,
'booksViewType' => $booksViewType
]);
}
@ -89,27 +108,6 @@ class HomeController extends Controller
]);
}
/**
* Get an icon via image request.
* Can provide a 'color' parameter with hex value to color the icon.
* @param $iconName
* @param Request $request
* @return \Illuminate\Contracts\Routing\ResponseFactory|\Symfony\Component\HttpFoundation\Response
*/
public function getIcon($iconName, Request $request)
{
$attrs = [];
if ($request->filled('color')) {
$attrs['fill'] = '#' . $request->get('color');
}
$icon = icon($iconName, $attrs);
return response($icon, 200, [
'Content-Type' => 'image/svg+xml',
'Cache-Control' => 'max-age=3600',
]);
}
/**
* Get custom head HTML, Used in ajax calls to show in editor.
* @return \Illuminate\Contracts\View\Factory|\Illuminate\View\View
@ -131,7 +129,15 @@ class HomeController extends Controller
$allowRobots = $sitePublic;
}
return response()
->view('robots', ['allowRobots' => $allowRobots])
->view('common/robots', ['allowRobots' => $allowRobots])
->header('Content-Type', 'text/plain');
}
/**
* Show the route for 404 responses.
*/
public function getNotFound()
{
return response()->view('errors/404', [], 404);
}
}

View File

@ -164,32 +164,6 @@ class ImageController extends Controller
return response()->json($image);
}
/**
* Replace the data content of a drawing.
* @param string $id
* @param Request $request
* @return \Illuminate\Contracts\Routing\ResponseFactory|\Illuminate\Http\JsonResponse|\Symfony\Component\HttpFoundation\Response
*/
public function replaceDrawing(string $id, Request $request)
{
$this->validate($request, [
'image' => 'required|string'
]);
$this->checkPermission('image-create-all');
$imageBase64Data = $request->get('image');
$image = $this->imageRepo->getById($id);
$this->checkOwnablePermission('image-update', $image);
try {
$image = $this->imageRepo->replaceDrawingContent($image, $imageBase64Data);
} catch (ImageUploadException $e) {
return response($e->getMessage(), 500);
}
return response()->json($image);
}
/**
* Get the content of an image based64 encoded.
* @param $id
@ -245,26 +219,29 @@ class ImageController extends Controller
}
/**
* Deletes an image and all thumbnail/image files
* Show the usage of an image on pages.
* @param EntityRepo $entityRepo
* @param Request $request
* @param int $id
* @param $id
* @return \Illuminate\Http\JsonResponse
*/
public function destroy(EntityRepo $entityRepo, Request $request, $id)
public function usage(EntityRepo $entityRepo, $id)
{
$image = $this->imageRepo->getById($id);
$pageSearch = $entityRepo->searchForImage($image->url);
return response()->json($pageSearch);
}
/**
* Deletes an image and all thumbnail/image files
* @param int $id
* @return \Illuminate\Http\JsonResponse
* @throws \Exception
*/
public function destroy($id)
{
$image = $this->imageRepo->getById($id);
$this->checkOwnablePermission('image-delete', $image);
// Check if this image is used on any pages
$isForced = in_array($request->get('force', ''), [true, 'true']);
if (!$isForced) {
$pageSearch = $entityRepo->searchForImage($image->url);
if ($pageSearch !== false) {
return response()->json($pageSearch, 400);
}
}
$this->imageRepo->destroyImage($image);
return response()->json(trans('components.images_deleted'));
}

View File

@ -1,5 +1,6 @@
<?php namespace BookStack\Http\Controllers;
use BookStack\Services\ImageService;
use Illuminate\Http\Request;
use Illuminate\Http\Response;
use Setting;
@ -13,7 +14,7 @@ class SettingController extends Controller
public function index()
{
$this->checkPermission('settings-manage');
$this->setPageTitle('Settings');
$this->setPageTitle(trans('settings.settings'));
// Get application version
$version = trim(file_get_contents(base_path('version')));
@ -43,4 +44,48 @@ class SettingController extends Controller
session()->flash('success', trans('settings.settings_save_success'));
return redirect('/settings');
}
/**
* Show the page for application maintenance.
* @return \Illuminate\Contracts\View\Factory|\Illuminate\View\View
*/
public function showMaintenance()
{
$this->checkPermission('settings-manage');
$this->setPageTitle(trans('settings.maint'));
// Get application version
$version = trim(file_get_contents(base_path('version')));
return view('settings/maintenance', ['version' => $version]);
}
/**
* Action to clean-up images in the system.
* @param Request $request
* @param ImageService $imageService
* @return \Illuminate\Http\RedirectResponse|\Illuminate\Routing\Redirector
*/
public function cleanupImages(Request $request, ImageService $imageService)
{
$this->checkPermission('settings-manage');
$checkRevisions = !($request->get('ignore_revisions', 'false') === 'true');
$dryRun = !($request->has('confirm'));
$imagesToDelete = $imageService->deleteUnusedImages($checkRevisions, $dryRun);
$deleteCount = count($imagesToDelete);
if ($deleteCount === 0) {
session()->flash('warning', trans('settings.maint_image_cleanup_nothing_found'));
return redirect('/settings/maintenance')->withInput();
}
if ($dryRun) {
session()->flash('cleanup-images-warning', trans('settings.maint_image_cleanup_warning', ['count' => $deleteCount]));
} else {
session()->flash('success', trans('settings.maint_image_cleanup_success', ['count' => $deleteCount]));
}
return redirect('/settings/maintenance#image-cleanup')->withInput();
}
}

View File

@ -33,14 +33,6 @@ class Kernel extends HttpKernel
\Illuminate\Routing\Middleware\SubstituteBindings::class,
\BookStack\Http\Middleware\Localization::class
],
'web_errors' => [
\BookStack\Http\Middleware\EncryptCookies::class,
\Illuminate\Cookie\Middleware\AddQueuedCookiesToResponse::class,
\Illuminate\Session\Middleware\StartSession::class,
\Illuminate\View\Middleware\ShareErrorsFromSession::class,
\BookStack\Http\Middleware\VerifyCsrfToken::class,
\BookStack\Http\Middleware\Localization::class
],
'api' => [
'throttle:60,1',
'bindings',

View File

@ -13,9 +13,11 @@ class Image extends Ownable
* @param int $height
* @param bool|false $keepRatio
* @return string
* @throws \Exception
*/
public function getThumb($width, $height, $keepRatio = false)
{
return Images::getThumbnail($this, $width, $height, $keepRatio);
}
}

View File

@ -3,6 +3,7 @@
namespace BookStack\Providers;
use BookStack\Activity;
use BookStack\Image;
use BookStack\Services\ImageService;
use BookStack\Services\PermissionService;
use BookStack\Services\ViewService;
@ -57,6 +58,7 @@ class CustomFacadeProvider extends ServiceProvider
$this->app->bind('images', function () {
return new ImageService(
$this->app->make(Image::class),
$this->app->make(ImageManager::class),
$this->app->make(Factory::class),
$this->app->make(Repository::class)

View File

@ -153,17 +153,6 @@ class ImageRepo
return $image;
}
/**
* Replace the image content of a drawing.
* @param Image $image
* @param string $base64Uri
* @return Image
* @throws \BookStack\Exceptions\ImageUploadException
*/
public function replaceDrawingContent(Image $image, string $base64Uri)
{
return $this->imageService->replaceImageDataFromBase64Uri($image, $base64Uri);
}
/**
* Update the details of an image via an array of properties.
@ -183,13 +172,14 @@ class ImageRepo
/**
* Destroys an Image object along with its files and thumbnails.
* Destroys an Image object along with its revisions, files and thumbnails.
* @param Image $image
* @return bool
* @throws \Exception
*/
public function destroyImage(Image $image)
{
$this->imageService->destroyImage($image);
$this->imageService->destroy($image);
return true;
}
@ -200,7 +190,7 @@ class ImageRepo
* @throws \BookStack\Exceptions\ImageUploadException
* @throws \Exception
*/
private function loadThumbs(Image $image)
protected function loadThumbs(Image $image)
{
$image->thumbs = [
'gallery' => $this->getThumbnail($image, 150, 150),
@ -250,7 +240,7 @@ class ImageRepo
*/
public function isValidType($type)
{
$validTypes = ['drawing', 'gallery', 'cover', 'system', 'user'];
$validTypes = ['gallery', 'cover', 'system', 'user'];
return in_array($type, $validTypes);
}
}

View File

@ -166,7 +166,7 @@ class UserRepo
// Delete user profile images
$profileImages = $images = Image::where('type', '=', 'user')->where('created_by', '=', $user->id)->get();
foreach ($profileImages as $image) {
Images::destroyImage($image);
Images::destroy($image);
}
}

View File

@ -3,11 +3,11 @@
use BookStack\Exceptions\ImageUploadException;
use BookStack\Image;
use BookStack\User;
use DB;
use Exception;
use Intervention\Image\Exception\NotSupportedException;
use Intervention\Image\ImageManager;
use Illuminate\Contracts\Filesystem\Factory as FileSystem;
use Illuminate\Contracts\Filesystem\Filesystem as FileSystemInstance;
use Illuminate\Contracts\Cache\Repository as Cache;
use Symfony\Component\HttpFoundation\File\UploadedFile;
@ -17,15 +17,18 @@ class ImageService extends UploadService
protected $imageTool;
protected $cache;
protected $storageUrl;
protected $image;
/**
* ImageService constructor.
* @param $imageTool
* @param $fileSystem
* @param $cache
* @param Image $image
* @param ImageManager $imageTool
* @param FileSystem $fileSystem
* @param Cache $cache
*/
public function __construct(ImageManager $imageTool, FileSystem $fileSystem, Cache $cache)
public function __construct(Image $image, ImageManager $imageTool, FileSystem $fileSystem, Cache $cache)
{
$this->image = $image;
$this->imageTool = $imageTool;
$this->cache = $cache;
parent::__construct($fileSystem);
@ -82,31 +85,6 @@ class ImageService extends UploadService
return $this->saveNew($name, $data, $type, $uploadedTo);
}
/**
* Replace the data for an image via a Base64 encoded string.
* @param Image $image
* @param string $base64Uri
* @return Image
* @throws ImageUploadException
*/
public function replaceImageDataFromBase64Uri(Image $image, string $base64Uri)
{
$splitData = explode(';base64,', $base64Uri);
if (count($splitData) < 2) {
throw new ImageUploadException("Invalid base64 image data provided");
}
$data = base64_decode($splitData[1]);
$storage = $this->getStorage();
try {
$storage->put($image->path, $data);
} catch (Exception $e) {
throw new ImageUploadException(trans('errors.path_not_writable', ['filePath' => $image->path]));
}
return $image;
}
/**
* Gets an image from url and saves it to the database.
* @param $url
@ -140,16 +118,16 @@ class ImageService extends UploadService
$secureUploads = setting('app-secure-images');
$imageName = str_replace(' ', '-', $imageName);
if ($secureUploads) {
$imageName = str_random(16) . '-' . $imageName;
}
$imagePath = '/uploads/images/' . $type . '/' . Date('Y-m-M') . '/';
while ($storage->exists($imagePath . $imageName)) {
$imageName = str_random(3) . $imageName;
}
$fullPath = $imagePath . $imageName;
if ($secureUploads) {
$fullPath = $imagePath . str_random(16) . '-' . $imageName;
}
try {
$storage->put($fullPath, $imageData);
@ -172,20 +150,11 @@ class ImageService extends UploadService
$imageDetails['updated_by'] = $userId;
}
$image = (new Image());
$image = $this->image->newInstance();
$image->forceFill($imageDetails)->save();
return $image;
}
/**
* Get the storage path, Dependant of storage type.
* @param Image $image
* @return mixed|string
*/
protected function getPath(Image $image)
{
return $image->path;
}
/**
* Checks if the image is a gif. Returns true if it is, else false.
@ -194,7 +163,7 @@ class ImageService extends UploadService
*/
protected function isGif(Image $image)
{
return strtolower(pathinfo($this->getPath($image), PATHINFO_EXTENSION)) === 'gif';
return strtolower(pathinfo($image->path, PATHINFO_EXTENSION)) === 'gif';
}
/**
@ -212,11 +181,11 @@ class ImageService extends UploadService
public function getThumbnail(Image $image, $width = 220, $height = 220, $keepRatio = false)
{
if ($keepRatio && $this->isGif($image)) {
return $this->getPublicUrl($this->getPath($image));
return $this->getPublicUrl($image->path);
}
$thumbDirName = '/' . ($keepRatio ? 'scaled-' : 'thumbs-') . $width . '-' . $height . '/';
$imagePath = $this->getPath($image);
$imagePath = $image->path;
$thumbFilePath = dirname($imagePath) . $thumbDirName . basename($imagePath);
if ($this->cache->has('images-' . $image->id . '-' . $thumbFilePath) && $this->cache->get('images-' . $thumbFilePath)) {
@ -262,43 +231,51 @@ class ImageService extends UploadService
*/
public function getImageData(Image $image)
{
$imagePath = $this->getPath($image);
$imagePath = $image->path;
$storage = $this->getStorage();
return $storage->get($imagePath);
}
/**
* Destroys an Image object along with its files and thumbnails.
* Destroy an image along with its revisions, thumbnails and remaining folders.
* @param Image $image
* @return bool
* @throws Exception
*/
public function destroyImage(Image $image)
public function destroy(Image $image)
{
$this->destroyImagesFromPath($image->path);
$image->delete();
}
/**
* Destroys an image at the given path.
* Searches for image thumbnails in addition to main provided path..
* @param string $path
* @return bool
*/
protected function destroyImagesFromPath(string $path)
{
$storage = $this->getStorage();
$imageFolder = dirname($this->getPath($image));
$imageFileName = basename($this->getPath($image));
$imageFolder = dirname($path);
$imageFileName = basename($path);
$allImages = collect($storage->allFiles($imageFolder));
// Delete image files
$imagesToDelete = $allImages->filter(function ($imagePath) use ($imageFileName) {
$expectedIndex = strlen($imagePath) - strlen($imageFileName);
return strpos($imagePath, $imageFileName) === $expectedIndex;
});
$storage->delete($imagesToDelete->all());
// Cleanup of empty folders
foreach ($storage->directories($imageFolder) as $directory) {
$foldersInvolved = array_merge([$imageFolder], $storage->directories($imageFolder));
foreach ($foldersInvolved as $directory) {
if ($this->isFolderEmpty($directory)) {
$storage->deleteDirectory($directory);
}
}
if ($this->isFolderEmpty($imageFolder)) {
$storage->deleteDirectory($imageFolder);
}
$image->delete();
return true;
}
@ -321,6 +298,46 @@ class ImageService extends UploadService
return $image;
}
/**
* Delete gallery and drawings that are not within HTML content of pages or page revisions.
* Checks based off of only the image name.
* Could be much improved to be more specific but kept it generic for now to be safe.
*
* Returns the path of the images that would be/have been deleted.
* @param bool $checkRevisions
* @param bool $dryRun
* @param array $types
* @return array
*/
public function deleteUnusedImages($checkRevisions = true, $dryRun = true, $types = ['gallery', 'drawio'])
{
$types = array_intersect($types, ['gallery', 'drawio']);
$deletedPaths = [];
$this->image->newQuery()->whereIn('type', $types)
->chunk(1000, function($images) use ($types, $checkRevisions, &$deletedPaths, $dryRun) {
foreach ($images as $image) {
$searchQuery = '%' . basename($image->path) . '%';
$inPage = DB::table('pages')
->where('html', 'like', $searchQuery)->count() > 0;
$inRevision = false;
if ($checkRevisions) {
$inRevision = DB::table('page_revisions')
->where('html', 'like', $searchQuery)->count() > 0;
}
if (!$inPage && !$inRevision) {
$deletedPaths[] = $image->path;
if (!$dryRun) {
$this->destroy($image);
}
}
}
});
return $deletedPaths;
}
/**
* Convert a image URI to a Base64 encoded string.
* Attempts to find locally via set storage method first.

View File

@ -6,7 +6,7 @@
"type": "project",
"require": {
"php": ">=7.0.0",
"laravel/framework": "5.5.*",
"laravel/framework": "~5.5.22",
"fideloper/proxy": "~3.3",
"ext-tidy": "*",
"intervention/image": "^2.4",

237
composer.lock generated
View File

@ -4,20 +4,20 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file",
"This file is @generated automatically"
],
"content-hash": "ed85d10e69b1071020178cb400a80e48",
"content-hash": "3bf33ab103b15b06ca06c85fd8ae3b78",
"packages": [
{
"name": "aws/aws-sdk-php",
"version": "3.52.6",
"version": "3.56.4",
"source": {
"type": "git",
"url": "https://github.com/aws/aws-sdk-php.git",
"reference": "c9af7657eddc0267cc7ac4f969c10d5c18459992"
"reference": "03273bb5c1d8098ff6c23b3fa9ee444c4cc1dcee"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/aws/aws-sdk-php/zipball/c9af7657eddc0267cc7ac4f969c10d5c18459992",
"reference": "c9af7657eddc0267cc7ac4f969c10d5c18459992",
"url": "https://api.github.com/repos/aws/aws-sdk-php/zipball/03273bb5c1d8098ff6c23b3fa9ee444c4cc1dcee",
"reference": "03273bb5c1d8098ff6c23b3fa9ee444c4cc1dcee",
"shasum": ""
},
"require": {
@ -84,7 +84,7 @@
"s3",
"sdk"
],
"time": "2018-02-09T22:53:37+00:00"
"time": "2018-05-18T19:53:15+00:00"
},
{
"name": "barryvdh/laravel-dompdf",
@ -439,16 +439,16 @@
},
{
"name": "egulias/email-validator",
"version": "2.1.3",
"version": "2.1.4",
"source": {
"type": "git",
"url": "https://github.com/egulias/EmailValidator.git",
"reference": "1bec00a10039b823cc94eef4eddd47dcd3b2ca04"
"reference": "8790f594151ca6a2010c6218e09d96df67173ad3"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/egulias/EmailValidator/zipball/1bec00a10039b823cc94eef4eddd47dcd3b2ca04",
"reference": "1bec00a10039b823cc94eef4eddd47dcd3b2ca04",
"url": "https://api.github.com/repos/egulias/EmailValidator/zipball/8790f594151ca6a2010c6218e09d96df67173ad3",
"reference": "8790f594151ca6a2010c6218e09d96df67173ad3",
"shasum": ""
},
"require": {
@ -457,7 +457,7 @@
},
"require-dev": {
"dominicsayers/isemail": "dev-master",
"phpunit/phpunit": "^4.8.35",
"phpunit/phpunit": "^4.8.35||^5.7||^6.0",
"satooshi/php-coveralls": "^1.0.1"
},
"suggest": {
@ -492,23 +492,24 @@
"validation",
"validator"
],
"time": "2017-11-15T23:40:40+00:00"
"time": "2018-04-10T10:11:19+00:00"
},
{
"name": "erusev/parsedown",
"version": "1.6.4",
"version": "1.7.1",
"source": {
"type": "git",
"url": "https://github.com/erusev/parsedown.git",
"reference": "fbe3fe878f4fe69048bb8a52783a09802004f548"
"reference": "92e9c27ba0e74b8b028b111d1b6f956a15c01fc1"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/erusev/parsedown/zipball/fbe3fe878f4fe69048bb8a52783a09802004f548",
"reference": "fbe3fe878f4fe69048bb8a52783a09802004f548",
"url": "https://api.github.com/repos/erusev/parsedown/zipball/92e9c27ba0e74b8b028b111d1b6f956a15c01fc1",
"reference": "92e9c27ba0e74b8b028b111d1b6f956a15c01fc1",
"shasum": ""
},
"require": {
"ext-mbstring": "*",
"php": ">=5.3.0"
},
"require-dev": {
@ -537,7 +538,7 @@
"markdown",
"parser"
],
"time": "2017-11-14T20:44:03+00:00"
"time": "2018-03-08T01:11:30+00:00"
},
{
"name": "fideloper/proxy",
@ -647,16 +648,16 @@
},
{
"name": "guzzlehttp/guzzle",
"version": "6.3.0",
"version": "6.3.3",
"source": {
"type": "git",
"url": "https://github.com/guzzle/guzzle.git",
"reference": "f4db5a78a5ea468d4831de7f0bf9d9415e348699"
"reference": "407b0cb880ace85c9b63c5f9551db498cb2d50ba"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/guzzle/guzzle/zipball/f4db5a78a5ea468d4831de7f0bf9d9415e348699",
"reference": "f4db5a78a5ea468d4831de7f0bf9d9415e348699",
"url": "https://api.github.com/repos/guzzle/guzzle/zipball/407b0cb880ace85c9b63c5f9551db498cb2d50ba",
"reference": "407b0cb880ace85c9b63c5f9551db498cb2d50ba",
"shasum": ""
},
"require": {
@ -666,7 +667,7 @@
},
"require-dev": {
"ext-curl": "*",
"phpunit/phpunit": "^4.0 || ^5.0",
"phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.4 || ^7.0",
"psr/log": "^1.0"
},
"suggest": {
@ -675,7 +676,7 @@
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "6.2-dev"
"dev-master": "6.3-dev"
}
},
"autoload": {
@ -708,7 +709,7 @@
"rest",
"web service"
],
"time": "2017-06-22T18:50:49+00:00"
"time": "2018-04-22T15:46:56+00:00"
},
{
"name": "guzzlehttp/promises",
@ -964,27 +965,27 @@
},
{
"name": "laravel/framework",
"version": "v5.5.34",
"version": "v5.5.40",
"source": {
"type": "git",
"url": "https://github.com/laravel/framework.git",
"reference": "1de7c0aec13eadbdddc2d1ba4019b064b2c6b966"
"reference": "d724ce0aa61bbd9adf658215eec484f5dd6711d6"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/laravel/framework/zipball/1de7c0aec13eadbdddc2d1ba4019b064b2c6b966",
"reference": "1de7c0aec13eadbdddc2d1ba4019b064b2c6b966",
"url": "https://api.github.com/repos/laravel/framework/zipball/d724ce0aa61bbd9adf658215eec484f5dd6711d6",
"reference": "d724ce0aa61bbd9adf658215eec484f5dd6711d6",
"shasum": ""
},
"require": {
"doctrine/inflector": "~1.1",
"erusev/parsedown": "~1.6",
"erusev/parsedown": "~1.7",
"ext-mbstring": "*",
"ext-openssl": "*",
"league/flysystem": "~1.0",
"league/flysystem": "^1.0.8",
"monolog/monolog": "~1.12",
"mtdowling/cron-expression": "~1.0",
"nesbot/carbon": "~1.20",
"nesbot/carbon": "^1.24.1",
"php": ">=7.0",
"psr/container": "~1.0",
"psr/simple-cache": "^1.0",
@ -1030,7 +1031,7 @@
"illuminate/translation": "self.version",
"illuminate/validation": "self.version",
"illuminate/view": "self.version",
"tightenco/collect": "self.version"
"tightenco/collect": "<5.5.33"
},
"require-dev": {
"aws/aws-sdk-php": "~3.0",
@ -1094,20 +1095,20 @@
"framework",
"laravel"
],
"time": "2018-02-06T15:36:55+00:00"
"time": "2018-03-30T13:29:30+00:00"
},
{
"name": "laravel/socialite",
"version": "v3.0.9",
"version": "v3.0.11",
"source": {
"type": "git",
"url": "https://github.com/laravel/socialite.git",
"reference": "fc1c8d415699e502f3e61cbc61e3250d5bd942eb"
"reference": "4d29ba66fdb38ec994b778e5e51657555cc10511"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/laravel/socialite/zipball/fc1c8d415699e502f3e61cbc61e3250d5bd942eb",
"reference": "fc1c8d415699e502f3e61cbc61e3250d5bd942eb",
"url": "https://api.github.com/repos/laravel/socialite/zipball/4d29ba66fdb38ec994b778e5e51657555cc10511",
"reference": "4d29ba66fdb38ec994b778e5e51657555cc10511",
"shasum": ""
},
"require": {
@ -1156,20 +1157,20 @@
"laravel",
"oauth"
],
"time": "2017-11-06T16:02:48+00:00"
"time": "2018-05-12T17:44:53+00:00"
},
{
"name": "league/flysystem",
"version": "1.0.42",
"version": "1.0.45",
"source": {
"type": "git",
"url": "https://github.com/thephpleague/flysystem.git",
"reference": "09eabc54e199950041aef258a85847676496fe8e"
"reference": "a99f94e63b512d75f851b181afcdf0ee9ebef7e6"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/thephpleague/flysystem/zipball/09eabc54e199950041aef258a85847676496fe8e",
"reference": "09eabc54e199950041aef258a85847676496fe8e",
"url": "https://api.github.com/repos/thephpleague/flysystem/zipball/a99f94e63b512d75f851b181afcdf0ee9ebef7e6",
"reference": "a99f94e63b512d75f851b181afcdf0ee9ebef7e6",
"shasum": ""
},
"require": {
@ -1240,20 +1241,20 @@
"sftp",
"storage"
],
"time": "2018-01-27T16:03:56+00:00"
"time": "2018-05-07T08:44:23+00:00"
},
{
"name": "league/flysystem-aws-s3-v3",
"version": "1.0.18",
"version": "1.0.19",
"source": {
"type": "git",
"url": "https://github.com/thephpleague/flysystem-aws-s3-v3.git",
"reference": "dc09b19f455750663b922ed52dcc0ff215bed284"
"reference": "f135691ef6761542af301b7c9880f140fb12dc74"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/thephpleague/flysystem-aws-s3-v3/zipball/dc09b19f455750663b922ed52dcc0ff215bed284",
"reference": "dc09b19f455750663b922ed52dcc0ff215bed284",
"url": "https://api.github.com/repos/thephpleague/flysystem-aws-s3-v3/zipball/f135691ef6761542af301b7c9880f140fb12dc74",
"reference": "f135691ef6761542af301b7c9880f140fb12dc74",
"shasum": ""
},
"require": {
@ -1287,7 +1288,7 @@
}
],
"description": "Flysystem adapter for the AWS S3 SDK v3.x",
"time": "2017-06-30T06:29:25+00:00"
"time": "2018-03-27T20:33:59+00:00"
},
{
"name": "league/oauth1-client",
@ -1531,35 +1532,30 @@
},
{
"name": "nesbot/carbon",
"version": "1.22.1",
"version": "1.27.0",
"source": {
"type": "git",
"url": "https://github.com/briannesbitt/Carbon.git",
"reference": "7cdf42c0b1cc763ab7e4c33c47a24e27c66bfccc"
"reference": "ef81c39b67200dcd7401c24363dcac05ac3a4fe9"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/7cdf42c0b1cc763ab7e4c33c47a24e27c66bfccc",
"reference": "7cdf42c0b1cc763ab7e4c33c47a24e27c66bfccc",
"url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/ef81c39b67200dcd7401c24363dcac05ac3a4fe9",
"reference": "ef81c39b67200dcd7401c24363dcac05ac3a4fe9",
"shasum": ""
},
"require": {
"php": ">=5.3.0",
"symfony/translation": "~2.6 || ~3.0"
"php": ">=5.3.9",
"symfony/translation": "~2.6 || ~3.0 || ~4.0"
},
"require-dev": {
"friendsofphp/php-cs-fixer": "~2",
"phpunit/phpunit": "~4.0 || ~5.0"
"phpunit/phpunit": "^4.8.35 || ^5.7"
},
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "1.23-dev"
}
},
"autoload": {
"psr-4": {
"Carbon\\": "src/Carbon/"
"": "src/"
}
},
"notification-url": "https://packagist.org/downloads/",
@ -1580,20 +1576,20 @@
"datetime",
"time"
],
"time": "2017-01-16T07:55:07+00:00"
"time": "2018-04-23T09:02:57+00:00"
},
{
"name": "paragonie/random_compat",
"version": "v2.0.11",
"version": "v2.0.12",
"source": {
"type": "git",
"url": "https://github.com/paragonie/random_compat.git",
"reference": "5da4d3c796c275c55f057af5a643ae297d96b4d8"
"reference": "258c89a6b97de7dfaf5b8c7607d0478e236b04fb"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/paragonie/random_compat/zipball/5da4d3c796c275c55f057af5a643ae297d96b4d8",
"reference": "5da4d3c796c275c55f057af5a643ae297d96b4d8",
"url": "https://api.github.com/repos/paragonie/random_compat/zipball/258c89a6b97de7dfaf5b8c7607d0478e236b04fb",
"reference": "258c89a6b97de7dfaf5b8c7607d0478e236b04fb",
"shasum": ""
},
"require": {
@ -1628,7 +1624,7 @@
"pseudorandom",
"random"
],
"time": "2017-09-27T21:40:39+00:00"
"time": "2018-04-04T21:24:14+00:00"
},
{
"name": "phenx/php-font-lib",
@ -1905,16 +1901,16 @@
},
{
"name": "psr/simple-cache",
"version": "1.0.0",
"version": "1.0.1",
"source": {
"type": "git",
"url": "https://github.com/php-fig/simple-cache.git",
"reference": "753fa598e8f3b9966c886fe13f370baa45ef0e24"
"reference": "408d5eafb83c57f6365a3ca330ff23aa4a5fa39b"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/php-fig/simple-cache/zipball/753fa598e8f3b9966c886fe13f370baa45ef0e24",
"reference": "753fa598e8f3b9966c886fe13f370baa45ef0e24",
"url": "https://api.github.com/repos/php-fig/simple-cache/zipball/408d5eafb83c57f6365a3ca330ff23aa4a5fa39b",
"reference": "408d5eafb83c57f6365a3ca330ff23aa4a5fa39b",
"shasum": ""
},
"require": {
@ -1949,7 +1945,7 @@
"psr-16",
"simple-cache"
],
"time": "2017-01-02T13:31:39+00:00"
"time": "2017-10-23T01:57:42+00:00"
},
{
"name": "ramsey/uuid",
@ -2077,21 +2073,21 @@
},
{
"name": "socialiteproviders/gitlab",
"version": "v3.0.1",
"version": "v3.0.2",
"source": {
"type": "git",
"url": "https://github.com/SocialiteProviders/GitLab.git",
"reference": "c96dc004563a3caf157608fe9aa9e45c79065d00"
"reference": "bab80e8e16853e062c58013b1c1f474bd5a5c49a"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/SocialiteProviders/GitLab/zipball/c96dc004563a3caf157608fe9aa9e45c79065d00",
"reference": "c96dc004563a3caf157608fe9aa9e45c79065d00",
"url": "https://api.github.com/repos/SocialiteProviders/GitLab/zipball/bab80e8e16853e062c58013b1c1f474bd5a5c49a",
"reference": "bab80e8e16853e062c58013b1c1f474bd5a5c49a",
"shasum": ""
},
"require": {
"php": "^5.6 || ^7.0",
"socialiteproviders/manager": "~3.0"
"socialiteproviders/manager": "~2.0 || ~3.0"
},
"type": "library",
"autoload": {
@ -2110,7 +2106,7 @@
}
],
"description": "GitLab OAuth2 Provider for Laravel Socialite",
"time": "2017-01-31T05:06:13+00:00"
"time": "2018-05-11T03:10:27+00:00"
},
{
"name": "socialiteproviders/manager",
@ -2795,16 +2791,16 @@
},
{
"name": "symfony/polyfill-mbstring",
"version": "v1.7.0",
"version": "v1.8.0",
"source": {
"type": "git",
"url": "https://github.com/symfony/polyfill-mbstring.git",
"reference": "78be803ce01e55d3491c1397cf1c64beb9c1b63b"
"reference": "3296adf6a6454a050679cde90f95350ad604b171"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/78be803ce01e55d3491c1397cf1c64beb9c1b63b",
"reference": "78be803ce01e55d3491c1397cf1c64beb9c1b63b",
"url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/3296adf6a6454a050679cde90f95350ad604b171",
"reference": "3296adf6a6454a050679cde90f95350ad604b171",
"shasum": ""
},
"require": {
@ -2816,7 +2812,7 @@
"type": "library",
"extra": {
"branch-alias": {
"dev-master": "1.7-dev"
"dev-master": "1.8-dev"
}
},
"autoload": {
@ -2850,7 +2846,7 @@
"portable",
"shim"
],
"time": "2018-01-30T19:27:44+00:00"
"time": "2018-04-26T10:06:28+00:00"
},
{
"name": "symfony/process",
@ -3213,16 +3209,16 @@
"packages-dev": [
{
"name": "barryvdh/laravel-debugbar",
"version": "v3.1.1",
"version": "v3.1.4",
"source": {
"type": "git",
"url": "https://github.com/barryvdh/laravel-debugbar.git",
"reference": "f0018d359a2ad6968ad11b283283a925e017f3c9"
"reference": "7a91480cc6e597caed5117a3c5d685f06d35c5a1"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/barryvdh/laravel-debugbar/zipball/f0018d359a2ad6968ad11b283283a925e017f3c9",
"reference": "f0018d359a2ad6968ad11b283283a925e017f3c9",
"url": "https://api.github.com/repos/barryvdh/laravel-debugbar/zipball/7a91480cc6e597caed5117a3c5d685f06d35c5a1",
"reference": "7a91480cc6e597caed5117a3c5d685f06d35c5a1",
"shasum": ""
},
"require": {
@ -3277,7 +3273,7 @@
"profiler",
"webprofiler"
],
"time": "2018-02-07T08:29:09+00:00"
"time": "2018-03-06T08:35:31+00:00"
},
{
"name": "barryvdh/laravel-ide-helper",
@ -3725,16 +3721,16 @@
},
{
"name": "mockery/mockery",
"version": "1.0",
"version": "1.1.0",
"source": {
"type": "git",
"url": "https://github.com/mockery/mockery.git",
"reference": "1bac8c362b12f522fdd1f1fa3556284c91affa38"
"reference": "99e29d3596b16dabe4982548527d5ddf90232e99"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/mockery/mockery/zipball/1bac8c362b12f522fdd1f1fa3556284c91affa38",
"reference": "1bac8c362b12f522fdd1f1fa3556284c91affa38",
"url": "https://api.github.com/repos/mockery/mockery/zipball/99e29d3596b16dabe4982548527d5ddf90232e99",
"reference": "99e29d3596b16dabe4982548527d5ddf90232e99",
"shasum": ""
},
"require": {
@ -3743,7 +3739,8 @@
"php": ">=5.6.0"
},
"require-dev": {
"phpunit/phpunit": "~5.7|~6.1"
"phpdocumentor/phpdocumentor": "^2.9",
"phpunit/phpunit": "~5.7.10|~6.5"
},
"type": "library",
"extra": {
@ -3772,8 +3769,8 @@
"homepage": "http://davedevelopment.co.uk"
}
],
"description": "Mockery is a simple yet flexible PHP mock object framework for use in unit testing with PHPUnit, PHPSpec or any other testing framework. Its core goal is to offer a test double framework with a succinct API capable of clearly defining all possible object operations and interactions using a human readable Domain Specific Language (DSL). Designed as a drop in alternative to PHPUnit's phpunit-mock-objects library, Mockery is easy to integrate with PHPUnit and can operate alongside phpunit-mock-objects without the World ending.",
"homepage": "http://github.com/mockery/mockery",
"description": "Mockery is a simple yet flexible PHP mock object framework",
"homepage": "https://github.com/mockery/mockery",
"keywords": [
"BDD",
"TDD",
@ -3786,7 +3783,7 @@
"test double",
"testing"
],
"time": "2017-10-06T16:20:43+00:00"
"time": "2018-05-08T08:54:48+00:00"
},
{
"name": "myclabs/deep-copy",
@ -4089,28 +4086,28 @@
},
{
"name": "phpspec/prophecy",
"version": "1.7.3",
"version": "1.7.6",
"source": {
"type": "git",
"url": "https://github.com/phpspec/prophecy.git",
"reference": "e4ed002c67da8eceb0eb8ddb8b3847bb53c5c2bf"
"reference": "33a7e3c4fda54e912ff6338c48823bd5c0f0b712"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/phpspec/prophecy/zipball/e4ed002c67da8eceb0eb8ddb8b3847bb53c5c2bf",
"reference": "e4ed002c67da8eceb0eb8ddb8b3847bb53c5c2bf",
"url": "https://api.github.com/repos/phpspec/prophecy/zipball/33a7e3c4fda54e912ff6338c48823bd5c0f0b712",
"reference": "33a7e3c4fda54e912ff6338c48823bd5c0f0b712",
"shasum": ""
},
"require": {
"doctrine/instantiator": "^1.0.2",
"php": "^5.3|^7.0",
"phpdocumentor/reflection-docblock": "^2.0|^3.0.2|^4.0",
"sebastian/comparator": "^1.1|^2.0",
"sebastian/comparator": "^1.1|^2.0|^3.0",
"sebastian/recursion-context": "^1.0|^2.0|^3.0"
},
"require-dev": {
"phpspec/phpspec": "^2.5|^3.2",
"phpunit/phpunit": "^4.8.35 || ^5.7"
"phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.5"
},
"type": "library",
"extra": {
@ -4148,20 +4145,20 @@
"spy",
"stub"
],
"time": "2017-11-24T13:59:53+00:00"
"time": "2018-04-18T13:57:24+00:00"
},
{
"name": "phpunit/php-code-coverage",
"version": "5.3.0",
"version": "5.3.2",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/php-code-coverage.git",
"reference": "661f34d0bd3f1a7225ef491a70a020ad23a057a1"
"reference": "c89677919c5dd6d3b3852f230a663118762218ac"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/661f34d0bd3f1a7225ef491a70a020ad23a057a1",
"reference": "661f34d0bd3f1a7225ef491a70a020ad23a057a1",
"url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/c89677919c5dd6d3b3852f230a663118762218ac",
"reference": "c89677919c5dd6d3b3852f230a663118762218ac",
"shasum": ""
},
"require": {
@ -4211,7 +4208,7 @@
"testing",
"xunit"
],
"time": "2017-12-06T09:29:45+00:00"
"time": "2018-04-06T15:36:58+00:00"
},
{
"name": "phpunit/php-file-iterator",
@ -4401,16 +4398,16 @@
},
{
"name": "phpunit/phpunit",
"version": "6.5.6",
"version": "6.5.8",
"source": {
"type": "git",
"url": "https://github.com/sebastianbergmann/phpunit.git",
"reference": "3330ef26ade05359d006041316ed0fa9e8e3cefe"
"reference": "4f21a3c6b97c42952fd5c2837bb354ec0199b97b"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/3330ef26ade05359d006041316ed0fa9e8e3cefe",
"reference": "3330ef26ade05359d006041316ed0fa9e8e3cefe",
"url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/4f21a3c6b97c42952fd5c2837bb354ec0199b97b",
"reference": "4f21a3c6b97c42952fd5c2837bb354ec0199b97b",
"shasum": ""
},
"require": {
@ -4481,7 +4478,7 @@
"testing",
"xunit"
],
"time": "2018-02-01T05:57:37+00:00"
"time": "2018-04-10T11:38:34+00:00"
},
{
"name": "phpunit/phpunit-mock-objects",
@ -5103,16 +5100,16 @@
},
{
"name": "squizlabs/php_codesniffer",
"version": "3.2.2",
"version": "3.2.3",
"source": {
"type": "git",
"url": "https://github.com/squizlabs/PHP_CodeSniffer.git",
"reference": "d7c00c3000ac0ce79c96fcbfef86b49a71158cd1"
"reference": "4842476c434e375f9d3182ff7b89059583aa8b27"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/d7c00c3000ac0ce79c96fcbfef86b49a71158cd1",
"reference": "d7c00c3000ac0ce79c96fcbfef86b49a71158cd1",
"url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/4842476c434e375f9d3182ff7b89059583aa8b27",
"reference": "4842476c434e375f9d3182ff7b89059583aa8b27",
"shasum": ""
},
"require": {
@ -5122,7 +5119,7 @@
"php": ">=5.4.0"
},
"require-dev": {
"phpunit/phpunit": "^4.0 || ^5.0 || ^6.0"
"phpunit/phpunit": "^4.0 || ^5.0 || ^6.0 || ^7.0"
},
"bin": [
"bin/phpcs",
@ -5150,7 +5147,7 @@
"phpcs",
"standards"
],
"time": "2017-12-19T21:44:46+00:00"
"time": "2018-02-20T21:35:23+00:00"
},
{
"name": "symfony/class-loader",

View File

@ -135,7 +135,7 @@ return [
|
*/
'domain' => null,
'domain' => env('SESSION_DOMAIN', null),
/*
|--------------------------------------------------------------------------
@ -148,6 +148,34 @@ return [
|
*/
'secure' => false,
'secure' => env('SESSION_SECURE_COOKIE', false),
/*
|--------------------------------------------------------------------------
| HTTP Access Only
|--------------------------------------------------------------------------
|
| Setting this value to true will prevent JavaScript from accessing the
| value of the cookie and the cookie will only be accessible through
| the HTTP protocol. You are free to modify this option if needed.
|
*/
'http_only' => true,
/*
|--------------------------------------------------------------------------
| Same-Site Cookies
|--------------------------------------------------------------------------
|
| This option determines how your cookies behave when cross-site requests
| take place, and can be used to mitigate CSRF attacks. By default, we
| do not enable this as other CSRF protection services are in place.
|
| Supported: "lax", "strict"
|
*/
'same_site' => null,
];

53
package-lock.json generated
View File

@ -693,6 +693,30 @@
}
}
},
"@babel/polyfill": {
"version": "7.0.0-beta.46",
"resolved": "https://registry.npmjs.org/@babel/polyfill/-/polyfill-7.0.0-beta.46.tgz",
"integrity": "sha512-eFFWNiI3Os7bBkIA10ZGBUMywK+1/OTVg+qsrlaXRBTpAN0n1g1pXCkNN4rcGpgLPNyfZHQEj+aVAyWPGerSIQ==",
"dev": true,
"requires": {
"core-js": "2.5.5",
"regenerator-runtime": "0.11.1"
},
"dependencies": {
"core-js": {
"version": "2.5.5",
"resolved": "https://registry.npmjs.org/core-js/-/core-js-2.5.5.tgz",
"integrity": "sha1-sU3ek2xkDAV5prUMq8wTLdYSfjs=",
"dev": true
},
"regenerator-runtime": {
"version": "0.11.1",
"resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.11.1.tgz",
"integrity": "sha512-MguG95oij0fC3QV3URf4V2SDYGJhJnJGqvIIgdECeODCT98wSWDAJ94SSuVpYQUoTcGUIL6L4yNB7j1DFFHSBg==",
"dev": true
}
}
},
"@babel/preset-env": {
"version": "7.0.0-beta.40",
"resolved": "https://registry.npmjs.org/@babel/preset-env/-/preset-env-7.0.0-beta.40.tgz",
@ -1888,17 +1912,6 @@
"babel-types": "6.26.0"
}
},
"babel-polyfill": {
"version": "6.26.0",
"resolved": "https://registry.npmjs.org/babel-polyfill/-/babel-polyfill-6.26.0.tgz",
"integrity": "sha1-N5k3q8Z9eJWXCtxiHyhM2WbPIVM=",
"dev": true,
"requires": {
"babel-runtime": "6.26.0",
"core-js": "2.5.1",
"regenerator-runtime": "0.10.5"
}
},
"babel-preset-es2015": {
"version": "6.24.1",
"resolved": "https://registry.npmjs.org/babel-preset-es2015/-/babel-preset-es2015-6.24.1.tgz",
@ -8765,12 +8778,6 @@
"regenerate": "1.3.3"
}
},
"regenerator-runtime": {
"version": "0.10.5",
"resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.10.5.tgz",
"integrity": "sha1-M2w+/BIgrc7dosn6tntaeVWjNlg=",
"dev": true
},
"regenerator-transform": {
"version": "0.10.1",
"resolved": "https://registry.npmjs.org/regenerator-transform/-/regenerator-transform-0.10.1.tgz",
@ -9079,9 +9086,9 @@
}
},
"sass-loader": {
"version": "6.0.7",
"resolved": "https://registry.npmjs.org/sass-loader/-/sass-loader-6.0.7.tgz",
"integrity": "sha512-JoiyD00Yo1o61OJsoP2s2kb19L1/Y2p3QFcCdWdF6oomBGKVYuZyqHWemRBfQ2uGYsk+CH3eCguXNfpjzlcpaA==",
"version": "7.0.1",
"resolved": "https://registry.npmjs.org/sass-loader/-/sass-loader-7.0.1.tgz",
"integrity": "sha512-MeVVJFejJELlAbA7jrRchi88PGP6U9yIfqyiG+bBC4a9s2PX+ulJB9h8bbEohtPBfZmlLhNZ0opQM9hovRXvlw==",
"dev": true,
"requires": {
"clone-deep": "2.0.2",
@ -9851,9 +9858,9 @@
}
},
"style-loader": {
"version": "0.20.3",
"resolved": "https://registry.npmjs.org/style-loader/-/style-loader-0.20.3.tgz",
"integrity": "sha512-2I7AVP73MvK33U7B9TKlYZAqdROyMXDYSMvHLX43qy3GCOaJNiV6i0v/sv9idWIaQ42Yn2dNv79Q5mKXbKhAZg==",
"version": "0.21.0",
"resolved": "https://registry.npmjs.org/style-loader/-/style-loader-0.21.0.tgz",
"integrity": "sha512-T+UNsAcl3Yg+BsPKs1vd22Fr8sVT+CJMtzqc6LEw9bbJZb43lm9GoeIfUcDEefBSWC0BhYbcdupV1GtI4DGzxg==",
"dev": true,
"requires": {
"loader-utils": "1.1.0",

View File

@ -14,15 +14,15 @@
"@babel/preset-env": "^7.0.0-beta.40",
"autoprefixer": "^8.1.0",
"babel-loader": "^8.0.0-beta.0",
"babel-polyfill": "^6.26.0",
"@babel/polyfill": "^7.0.0-beta.40",
"css-loader": "^0.28.10",
"extract-text-webpack-plugin": "^4.0.0-beta.0",
"livereload": "^0.7.0",
"node-sass": "^4.7.2",
"npm-run-all": "^4.1.2",
"postcss-loader": "^2.1.1",
"sass-loader": "^6.0.7",
"style-loader": "^0.20.3",
"sass-loader": "^7.0.1",
"style-loader": "^0.21.0",
"uglifyjs-webpack-plugin": "^1.2.3",
"webpack": "^4.1.1",
"webpack-cli": "^2.0.11"

View File

@ -0,0 +1,4 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
<path clip-rule="evenodd" fill="none" d="M0 0h24v24H0z"/>
<path d="M22.7 19l-9.1-9.1c.9-2.3.4-5-1.5-6.9-2-2-5-2.4-7.4-1.3L9 6 6 9 1.6 4.7C.4 7.1.9 10.1 2.9 12.1c1.9 1.9 4.6 2.4 6.9 1.5l9.1 9.1c.4.4 1 .4 1.4 0l2.3-2.3c.5-.4.5-1.1.1-1.4z"/>
</svg>

After

Width:  |  Height:  |  Size: 315 B

View File

@ -0,0 +1,5 @@
<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
<path d="M0 0h24v24H0z" fill="none"/>
<path d="M12 17.27L18.18 21l-1.64-7.03L22 9.24l-7.19-.61L12 2 9.19 8.63 2 9.24l5.46 4.73L5.82 21z"/>
<path d="M0 0h24v24H0z" fill="none"/>
</svg>

After

Width:  |  Height:  |  Size: 256 B

View File

@ -1,4 +1,4 @@
<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
<svg viewBox="0 0 24 24" fill="#b6531c" xmlns="http://www.w3.org/2000/svg">
<path d="M0 0h24v24H0z" fill="none"/>
<path d="M1 21h22L12 2 1 21zm12-3h-2v-2h2v2zm0-4h-2v-4h2v4z"/>
</svg>

Before

Width:  |  Height:  |  Size: 176 B

After

Width:  |  Height:  |  Size: 191 B

View File

@ -6,6 +6,12 @@ class BackToTop {
this.targetElem = document.getElementById('header');
this.showing = false;
this.breakPoint = 1200;
if (document.body.classList.contains('flexbox')) {
this.elem.style.display = 'none';
return;
}
this.elem.addEventListener('click', this.scrollToTop.bind(this));
window.addEventListener('scroll', this.onPageScroll.bind(this));
}

View File

@ -52,6 +52,10 @@ class MarkdownEditor {
let action = button.getAttribute('data-action');
if (action === 'insertImage') this.actionInsertImage();
if (action === 'insertLink') this.actionShowLinkSelector();
if (action === 'insertDrawing' && event.ctrlKey) {
this.actionShowImageManager();
return;
}
if (action === 'insertDrawing') this.actionStartDrawing();
});
@ -293,7 +297,14 @@ class MarkdownEditor {
this.cm.focus();
this.cm.replaceSelection(newText);
this.cm.setCursor(cursorPos.line, cursorPos.ch + newText.length);
});
}, 'gallery');
}
actionShowImageManager() {
let cursorPos = this.cm.getCursor('from');
window.ImageManager.show(image => {
this.insertDrawing(image, cursorPos);
}, 'drawio');
}
// Show the popup link selector and insert a link when finished
@ -324,10 +335,7 @@ class MarkdownEditor {
};
window.$http.post(window.baseUrl('/images/drawing/upload'), data).then(resp => {
let newText = `<div drawio-diagram="${resp.data.id}"><img src="${resp.data.url}"></div>`;
this.cm.focus();
this.cm.replaceSelection(newText);
this.cm.setCursor(cursorPos.line, cursorPos.ch + newText.length);
this.insertDrawing(resp.data, cursorPos);
DrawIO.close();
}).catch(err => {
window.$events.emit('error', trans('errors.image_upload_error'));
@ -336,6 +344,13 @@ class MarkdownEditor {
});
}
insertDrawing(image, originalCursor) {
let newText = `<div drawio-diagram="${image.id}"><img src="${image.url}"></div>`;
this.cm.focus();
this.cm.replaceSelection(newText);
this.cm.setCursor(originalCursor.line, originalCursor.ch + newText.length);
}
// Show draw.io if enabled and handle save.
actionEditDrawing(imgContainer) {
if (document.querySelector('[drawio-enabled]').getAttribute('drawio-enabled') !== 'true') return;
@ -353,8 +368,8 @@ class MarkdownEditor {
uploaded_to: Number(document.getElementById('page-editor').getAttribute('page-id'))
};
window.$http.put(window.baseUrl(`/images/drawing/upload/${drawingId}`), data).then(resp => {
let newText = `<div drawio-diagram="${resp.data.id}"><img src="${resp.data.url + `?updated=${Date.now()}`}"></div>`;
window.$http.post(window.baseUrl(`/images/drawing/upload`), data).then(resp => {
let newText = `<div drawio-diagram="${resp.data.id}"><img src="${resp.data.url}"></div>`;
let newContent = this.cm.getValue().split('\n').map(line => {
if (line.indexOf(`drawio-diagram="${drawingId}"`) !== -1) {
return newText;

View File

@ -35,6 +35,7 @@ class PageDisplay {
}
setupPointer() {
if (document.getElementById('pointer') === null) return;
// Set up pointer
let $pointer = $('#pointer').detach();
let pointerShowing = false;

View File

@ -221,8 +221,6 @@ function codePlugin() {
function drawIoPlugin() {
const drawIoUrl = 'https://www.draw.io/?embed=1&ui=atlas&spin=1&proto=json';
let iframe = null;
let pageEditor = null;
let currentNode = null;
@ -230,6 +228,22 @@ function drawIoPlugin() {
return node.hasAttribute('drawio-diagram');
}
function showDrawingManager(mceEditor, selectedNode = null) {
pageEditor = mceEditor;
currentNode = selectedNode;
// Show image manager
window.ImageManager.show(function (image) {
if (selectedNode) {
let imgElem = selectedNode.querySelector('img');
pageEditor.dom.setAttrib(imgElem, 'src', image.url);
pageEditor.dom.setAttrib(selectedNode, 'drawio-diagram', image.id);
} else {
let imgHTML = `<div drawio-diagram="${image.id}" contenteditable="false"><img src="${image.url}"></div>`;
pageEditor.insertContent(imgHTML);
}
}, 'drawio');
}
function showDrawingEditor(mceEditor, selectedNode = null) {
pageEditor = mceEditor;
currentNode = selectedNode;
@ -248,9 +262,9 @@ function drawIoPlugin() {
if (currentNode) {
DrawIO.close();
let imgElem = currentNode.querySelector('img');
let drawingId = currentNode.getAttribute('drawio-diagram');
window.$http.put(window.baseUrl(`/images/drawing/upload/${drawingId}`), data).then(resp => {
pageEditor.dom.setAttrib(imgElem, 'src', `${resp.data.url}?updated=${Date.now()}`);
window.$http.post(window.baseUrl(`/images/drawing/upload`), data).then(resp => {
pageEditor.dom.setAttrib(imgElem, 'src', resp.data.url);
pageEditor.dom.setAttrib(currentNode, 'drawio-diagram', resp.data.id);
}).catch(err => {
window.$events.emit('error', trans('errors.image_upload_error'));
console.log(err);
@ -287,13 +301,24 @@ function drawIoPlugin() {
window.tinymce.PluginManager.add('drawio', function(editor, url) {
editor.addCommand('drawio', () => {
showDrawingEditor(editor);
let selectedNode = editor.selection.getNode();
showDrawingEditor(editor, isDrawing(selectedNode) ? selectedNode : null);
});
editor.addButton('drawio', {
type: 'splitbutton',
tooltip: 'Drawing',
image: window.baseUrl('/icon/drawing.svg?color=000000'),
cmd: 'drawio'
image: `data:image/svg+xml;base64,PHN2ZyB2aWV3Qm94PSIwIDAgMjQgMjQiIGZpbGw9IiMwMDAwMDAiICB4bWxucz0iaHR0cDovL3d3 dy53My5vcmcvMjAwMC9zdmciPgogICAgPHBhdGggZD0iTTIzIDdWMWgtNnYySDdWMUgxdjZoMnYx MEgxdjZoNnYtMmgxMHYyaDZ2LTZoLTJWN2gyek0zIDNoMnYySDNWM3ptMiAxOEgzdi0yaDJ2Mnpt MTItMkg3di0ySDVWN2gyVjVoMTB2MmgydjEwaC0ydjJ6bTQgMmgtMnYtMmgydjJ6TTE5IDVWM2gy djJoLTJ6bS01LjI3IDloLTMuNDlsLS43MyAySDcuODlsMy40LTloMS40bDMuNDEgOWgtMS42M2wt Ljc0LTJ6bS0zLjA0LTEuMjZoMi42MUwxMiA4LjkxbC0xLjMxIDMuODN6Ii8+CiAgICA8cGF0aCBk PSJNMCAwaDI0djI0SDB6IiBmaWxsPSJub25lIi8+Cjwvc3ZnPg==`,
cmd: 'drawio',
menu: [
{
text: 'Drawing Manager',
onclick() {
let selectedNode = editor.selection.getNode();
showDrawingManager(editor, isDrawing(selectedNode) ? selectedNode : null);
}
}
]
});
editor.on('dblclick', event => {
@ -443,7 +468,7 @@ class WysiwygEditor {
html += `<img src="${image.thumbs.display}" alt="${image.name}">`;
html += '</a>';
win.tinyMCE.activeEditor.execCommand('mceInsertContent', false, html);
});
}, 'gallery');
}
},
@ -522,7 +547,7 @@ class WysiwygEditor {
html += `<img src="${image.thumbs.display}" alt="${image.name}">`;
html += '</a>';
editor.execCommand('mceInsertContent', false, html);
});
}, 'gallery');
}
});

View File

@ -1,5 +1,5 @@
// Global Polyfills
import "babel-polyfill"
import "@babel/polyfill"
import "./services/dom-polyfills"
// Url retrieval function

View File

@ -20,13 +20,13 @@ const CodeMirror = require('codemirror');
const modeMap = {
css: 'css',
c: 'clike',
java: 'clike',
scala: 'clike',
kotlin: 'clike',
'c++': 'clike',
'c#': 'clike',
csharp: 'clike',
c: 'text/x-csrc',
java: 'text/x-java',
scala: 'text/x-scala',
kotlin: 'text/x-kotlin',
'c++': 'text/x-c++src',
'c#': 'text/x-csharp',
csharp: 'text/x-csharp',
diff: 'diff',
go: 'go',
html: 'htmlmixed',

View File

@ -31,6 +31,9 @@ let methods = {
},
getFileUrl(file) {
if (file.external && file.path.indexOf('http') !== 0) {
return file.path;
}
return window.baseUrl(`/attachments/${file.id}`);
},
@ -79,10 +82,8 @@ let methods = {
},
checkValidationErrors(groupName, err) {
console.error(err);
if (typeof err.response.data === "undefined" && typeof err.response.data.validation === "undefined") return;
this.errors[groupName] = err.response.data.validation;
console.log(this.errors[groupName]);
if (typeof err.response.data === "undefined" && typeof err.response.data === "undefined") return;
this.errors[groupName] = err.response.data;
},
getUploadUrl(file) {
@ -97,6 +98,7 @@ let methods = {
attachNewLink(file) {
file.uploaded_to = this.pageId;
this.errors.link = {};
this.$http.post(window.baseUrl('/attachments/link'), file).then(resp => {
this.files.push(resp.data);
this.file = this.newFile();

View File

@ -26,25 +26,32 @@ const data = {
imageUpdateSuccess: false,
imageDeleteSuccess: false,
deleteConfirm: false,
};
const methods = {
show(providedCallback) {
show(providedCallback, imageType = null) {
callback = providedCallback;
this.showing = true;
this.$el.children[0].components.overlay.show();
// Get initial images if they have not yet been loaded in.
if (dataLoaded) return;
if (dataLoaded && imageType === this.imageType) return;
if (imageType) {
this.imageType = imageType;
this.resetState();
}
this.fetchData();
dataLoaded = true;
},
hide() {
if (this.$refs.dropzone) {
this.$refs.dropzone.onClose();
}
this.showing = false;
this.selectedImage = false;
this.$refs.dropzone.onClose();
this.$el.children[0].components.overlay.hide();
},
@ -62,13 +69,18 @@ const methods = {
},
setView(viewName) {
this.view = viewName;
this.resetState();
this.fetchData();
},
resetState() {
this.cancelSearch();
this.images = [];
this.hasMore = false;
this.deleteConfirm = false;
page = 0;
this.view = viewName;
baseUrl = window.baseUrl(`/images/${this.imageType}/${viewName}/`);
this.fetchData();
baseUrl = window.baseUrl(`/images/${this.imageType}/${this.view}/`);
},
searchImages() {
@ -89,6 +101,7 @@ const methods = {
},
cancelSearch() {
if (!this.searching) return;
this.searching = false;
this.searchTerm = '';
this.images = preSearchImages;
@ -105,6 +118,7 @@ const methods = {
this.callbackAndHide(image);
} else {
this.selectedImage = image;
this.deleteConfirm = false;
this.dependantPages = false;
}
@ -134,17 +148,22 @@ const methods = {
},
deleteImage() {
let force = this.dependantPages !== false;
let url = window.baseUrl('/images/' + this.selectedImage.id);
if (force) url += '?force=true';
this.$http.delete(url).then(response => {
if (!this.deleteConfirm) {
let url = window.baseUrl(`/images/usage/${this.selectedImage.id}`);
this.$http.get(url).then(resp => {
this.dependantPages = resp.data;
}).catch(console.error).then(() => {
this.deleteConfirm = true;
});
return;
}
this.$http.delete(`/images/${this.selectedImage.id}`).then(resp => {
this.images.splice(this.images.indexOf(this.selectedImage), 1);
this.selectedImage = false;
this.$events.emit('success', trans('components.image_delete_success'));
}).catch(error=> {
if (error.response.status === 400) {
this.dependantPages = error.response.data;
}
this.deleteConfirm = false;
});
},

View File

@ -99,7 +99,7 @@ let methods = {
lastSave = Date.now();
}, errorRes => {
if (draftErroring) return;
window.$events('error', trans('errors.page_draft_autosave_fail'));
window.$events.emit('error', trans('errors.page_draft_autosave_fail'));
draftErroring = true;
});
},

View File

@ -138,7 +138,7 @@
display: block;
position: relative;
&:before {
background-image: url("/icon/info-filled.svg?color=015380");
background-image: url('data:image/svg+xml;base64,PHN2ZyB2aWV3Qm94PSIwIDAgMjQgMjQiIGZpbGw9IiMwMTUzODAiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+ICAgIDxwYXRoIGQ9Ik0wIDBoMjR2MjRIMHoiIGZpbGw9Im5vbmUiLz4gICAgPHBhdGggZD0iTTEyIDJDNi40OCAyIDIgNi40OCAyIDEyczQuNDggMTAgMTAgMTAgMTAtNC40OCAxMC0xMFMxNy41MiAyIDEyIDJ6bTEgMTVoLTJ2LTZoMnY2em0wLThoLTJWN2gydjJ6Ii8+PC9zdmc+');
background-repeat: no-repeat;
content: '';
width: 1.2em;
@ -157,7 +157,7 @@
color: darken($positive, 16%);
}
&.success:before {
background-image: url("/icon/check-circle.svg?color=376c39");
background-image: url("data:image/svg+xml;base64,PHN2ZyB2aWV3Qm94PSIwIDAgMjQgMjQiIGZpbGw9IiMzNzZjMzkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+ICAgIDxwYXRoIGQ9Ik0wIDBoMjR2MjRIMHoiIGZpbGw9Im5vbmUiLz4gICAgPHBhdGggZD0iTTEyIDJDNi40OCAyIDIgNi40OCAyIDEyczQuNDggMTAgMTAgMTAgMTAtNC40OCAxMC0xMFMxNy41MiAyIDEyIDJ6bS0yIDE1bC01LTUgMS40MS0xLjQxTDEwIDE0LjE3bDcuNTktNy41OUwxOSA4bC05IDl6Ii8+PC9zdmc+");
}
&.danger {
border-left-color: $negative;
@ -165,7 +165,7 @@
color: darken($negative, 20%);
}
&.danger:before {
background-image: url("/icon/danger.svg?color=b91818");
background-image: url("data:image/svg+xml;base64,PHN2ZyB2aWV3Qm94PSIwIDAgMjQgMjQiIGZpbGw9IiNiOTE4MTgiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+ICAgIDxwYXRoIGQ9Ik0xNS43MyAzSDguMjdMMyA4LjI3djcuNDZMOC4yNyAyMWg3LjQ2TDIxIDE1LjczVjguMjdMMTUuNzMgM3pNMTIgMTcuM2MtLjcyIDAtMS4zLS41OC0xLjMtMS4zIDAtLjcyLjU4LTEuMyAxLjMtMS4zLjcyIDAgMS4zLjU4IDEuMyAxLjMgMCAuNzItLjU4IDEuMy0xLjMgMS4zem0xLTQuM2gtMlY3aDJ2NnoiLz4gICAgPHBhdGggZD0iTTAgMGgyNHYyNEgweiIgZmlsbD0ibm9uZSIvPjwvc3ZnPg==");
}
&.info {
border-left-color: $info;
@ -178,7 +178,7 @@
color: darken($warning, 16%);
}
&.warning:before {
background-image: url("/icon/warning.svg?color=b6531c");
background-image: url("data:image/svg+xml;base64,PHN2ZyB2aWV3Qm94PSIwIDAgMjQgMjQiIGZpbGw9IiNiNjUzMWMiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+ICAgIDxwYXRoIGQ9Ik0wIDBoMjR2MjRIMHoiIGZpbGw9Im5vbmUiLz4gICAgPHBhdGggZD0iTTEgMjFoMjJMMTIgMiAxIDIxem0xMi0zaC0ydi0yaDJ2MnptMC00aC0ydi00aDJ2NHoiLz48L3N2Zz4=");
}
}
@ -208,6 +208,12 @@
}
}
.sidebar .card {
h3, .body, .empty-text {
padding: $-s $-m;
}
}
.card.drag-card {
border: 1px solid #DDD;
border-radius: 4px;
@ -262,3 +268,33 @@
padding: $-m;
border: 1px solid #DDD;
}
.tag-item {
display: inline-flex;
margin-bottom: $-xs;
margin-right: $-xs;
border-radius: 4px;
border: 1px solid #CCC;
overflow: hidden;
font-size: 0.85em;
a, a:hover, a:active {
padding: 4px 8px;
color: #777;
transition: background-color ease-in-out 80ms;
text-decoration: none;
}
a:hover {
background-color: rgba(255, 255, 255, 0.7);
}
svg {
fill: #888;
}
.tag-value {
border-left: 1px solid #DDD;
background-color: rgba(255, 255, 255, 0.5);
}
}
.tag-list div:last-child .tag-item {
margin-bottom: 0;
}

View File

@ -146,7 +146,8 @@ body.flexbox-support #entity-selector-wrap .popup-body .form-group {
.dropzone-container {
position: relative;
border: 3px dashed #DDD;
background-color: #EEE;
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='4' height='4' viewBox='0 0 4 4'%3E%3Cpath fill='%23a9a9a9' fill-opacity='0.52' d='M1 3h1v1H1V3zm2-2h1v1H3V1z'%3E%3C/path%3E%3C/svg%3E");
}
.image-manager-list .image {
@ -163,8 +164,10 @@ body.flexbox-support #entity-selector-wrap .popup-body .form-group {
transition: all cubic-bezier(.4, 0, 1, 1) 160ms;
overflow: hidden;
&.selected {
transform: scale3d(0.92, 0.92, 0.92);
border: 1px solid #444;
//transform: scale3d(0.92, 0.92, 0.92);
border: 4px solid #FFF;
overflow: hidden;
border-radius: 8px;
box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.2);
}
img {
@ -210,12 +213,30 @@ body.flexbox-support #entity-selector-wrap .popup-body .form-group {
.image-manager-sidebar {
width: 300px;
margin-left: 1px;
padding: $-m $-l;
overflow-y: auto;
overflow-x: hidden;
border-left: 1px solid #DDD;
.inner {
padding: $-m;
}
img {
max-width: 100%;
max-height: 180px;
display: block;
margin: 0 auto $-m auto;
box-shadow: 0 1px 21px 1px rgba(76, 76, 76, 0.3);
}
.image-manager-viewer {
height: 196px;
display: flex;
align-items: center;
justify-content: center;
a {
display: inline-block;
}
}
.dropzone-container {
margin-top: $-m;
border-bottom: 1px solid #DDD;
}
}
@ -242,10 +263,10 @@ body.flexbox-support #entity-selector-wrap .popup-body .form-group {
* Copyright (c) 2012 Matias Meno <m@tias.me>
*/
.dz-message {
font-size: 1.2em;
line-height: 1.1;
font-size: 1em;
line-height: 2.35;
font-style: italic;
color: #aaa;
color: #888;
text-align: center;
cursor: pointer;
padding: $-l $-m;
@ -565,6 +586,7 @@ body.flexbox-support #entity-selector-wrap .popup-body .form-group {
}
.comment-box {
clear: left;
border: 1px solid #DDD;
margin-bottom: $-s;
border-radius: 3px;

View File

@ -9,6 +9,7 @@
color: #666;
width: 250px;
max-width: 100%;
&.neg, &.invalid {
border: 1px solid $negative;
}

View File

@ -55,6 +55,9 @@ body.flexbox {
background-color: #F2F2F2;
max-width: 360px;
min-height: 90vh;
section {
margin: $-m;
}
}
.flex.sidebar + .flex.content {
flex: 3;

View File

@ -16,21 +16,25 @@ header {
.links {
display: inline-block;
vertical-align: top;
margin-right: $-xl;
@include smaller-than($screen-md) {
margin-right: $-m;
}
margin-left: $-m;
}
.links a {
display: inline-block;
padding: $-m $-l;
padding: $-m;
color: #FFF;
fill: #FFF;
&:last-child {
}
.dropdown-container {
padding-left: $-m;
padding-right: 0;
}
@include smaller-than($screen-md) {
padding: $-m $-s;
.links a {
padding-left: $-s;
padding-right: $-s;
}
.dropdown-container {
padding-left: $-s;
}
}
.avatar, .user-name {
@ -90,10 +94,14 @@ header .search-box {
background-color: rgba(0, 0, 0, 0.2);
border: 1px solid rgba(255, 255, 255, 0.3);
color: #EEE;
z-index: 2;
}
button {
color: #EEE;
fill: #EEE;
z-index: 1;
svg {
margin-right: 0;
}
}
::-webkit-input-placeholder { /* Chrome/Opera/Safari */
color: #DDD;

View File

@ -35,10 +35,14 @@
}
.page-content {
width: 100%;
max-width: 840px;
margin: 0 auto;
margin-top: $-xxl;
overflow-wrap: break-word;
&.flex {
margin-top: $-m;
}
.align-left {
text-align: left;
}
@ -315,6 +319,18 @@
}
}
.comments-container {
width: 100%;
border-top: 1px solid #DDD;
margin-top: $-xl;
margin-bottom: $-m;
h5 {
color: #888;
font-weight: normal;
margin-top: 0.5em;
}
}
.comment-editor .CodeMirror, .comment-editor .CodeMirror-scroll {
min-height: 175px;
}

View File

@ -101,6 +101,13 @@ a, .link {
}
}
.blended-links a {
color: inherit;
svg {
fill: currentColor;
}
}
/*
* Other HTML Text Elements
*/

View File

@ -154,6 +154,7 @@ $btt-size: 40px;
}
input {
flex: 5;
padding: $-xs $-s;
&:focus, &:active {
outline: 0;
}

View File

@ -31,6 +31,7 @@ return [
'edit' => 'Bearbeiten',
'sort' => 'Sortieren',
'move' => 'Verschieben',
'copy' => 'Kopieren',
'reply' => 'Antworten',
'delete' => 'Löschen',
'search' => 'Suchen',

View File

@ -12,7 +12,8 @@ return [
'image_uploaded' => 'Hochgeladen am :uploadedDate',
'image_load_more' => 'Mehr',
'image_image_name' => 'Bildname',
'image_delete_confirm' => 'Dieses Bild wird auf den folgenden Seiten benutzt. Bitte klicken Sie erneut auf löschen, wenn Sie dieses Bild wirklich entfernen möchten.',
'image_delete_used' => 'Dieses Bild wird auf den folgenden Seiten benutzt. ',
'image_delete_confirm' => 'Bitte klicken Sie erneut auf löschen, wenn Sie dieses Bild wirklich entfernen möchten.',
'image_select_image' => 'Bild auswählen',
'image_dropzone' => 'Ziehen Sie Bilder hierher oder klicken Sie, um ein Bild auszuwählen',
'images_deleted' => 'Bilder gelöscht',

View File

@ -114,6 +114,9 @@ return [
'chapters_move' => 'Kapitel verschieben',
'chapters_move_named' => 'Kapitel ":chapterName" verschieben',
'chapter_move_success' => 'Das Kapitel wurde in das Buch ":bookName" verschoben.',
'pages_copy' => 'Seite kopieren',
'pages_copy_desination' => 'Ziel',
'pages_copy_success' => 'Seite erfolgreich kopiert',
'chapters_permissions' => 'Kapitel-Berechtigungen',
'chapters_empty' => 'Aktuell sind keine Kapitel diesem Buch hinzugefügt worden.',
'chapters_permissions_active' => 'Kapitel-Berechtigungen aktiv',

View File

@ -13,7 +13,8 @@ return [
'image_uploaded' => 'Uploaded :uploadedDate',
'image_load_more' => 'Load More',
'image_image_name' => 'Image Name',
'image_delete_confirm' => 'This image is used in the pages below, Click delete again to confirm you want to delete this image.',
'image_delete_used' => 'This image is used in the pages below.',
'image_delete_confirm' => 'Click delete again to confirm you want to delete this image.',
'image_select_image' => 'Select Image',
'image_dropzone' => 'Drop images or click here to upload',
'images_deleted' => 'Images Deleted',

View File

@ -34,6 +34,7 @@ return [
'app_homepage' => 'Application Homepage',
'app_homepage_desc' => 'Select a page to show on the homepage instead of the default view. Page permissions are ignored for selected pages.',
'app_homepage_default' => 'Default homepage view chosen',
'app_homepage_books' => 'Or select the books page as your homepage. This will override any page selected as your homepage.',
'app_disable_comments' => 'Disable comments',
'app_disable_comments_desc' => 'Disable comments across all pages in the application. Existing comments are not shown.',
@ -50,6 +51,19 @@ return [
'reg_confirm_restrict_domain_desc' => 'Enter a comma separated list of email domains you would like to restrict registration to. Users will be sent an email to confirm their address before being allowed to interact with the application. <br> Note that users will be able to change their email addresses after successful registration.',
'reg_confirm_restrict_domain_placeholder' => 'No restriction set',
/**
* Maintenance settings
*/
'maint' => 'Maintenance',
'maint_image_cleanup' => 'Cleanup Images',
'maint_image_cleanup_desc' => "Scans page & revision content to check which images and drawings are currently in use and which images are redundant. Ensure you create a full database and image backup before running this.",
'maint_image_cleanup_ignore_revisions' => 'Ignore images in revisions',
'maint_image_cleanup_run' => 'Run Cleanup',
'maint_image_cleanup_warning' => ':count potentially unused images were found. Are you sure you want to delete these images?',
'maint_image_cleanup_success' => ':count potentially unused images found and deleted!',
'maint_image_cleanup_nothing_found' => 'No unused images found, Nothing deleted!',
/**
* Role settings
*/

View File

@ -13,7 +13,8 @@ return [
'image_uploaded' => 'Subido el :uploadedDate',
'image_load_more' => 'Cargar más',
'image_image_name' => 'Nombre de imagen',
'image_delete_confirm' => 'Esta imagen está siendo utilizada en las páginas mostradas a continuación, haga click de nuevo para confirmar que quiere borrar esta imagen.',
'image_delete_used' => 'Esta imagen está siendo utilizada en las páginas mostradas a continuación.',
'image_delete_confirm' => 'Haga click de nuevo para confirmar que quiere borrar esta imagen.',
'image_select_image' => 'Seleccionar Imagen',
'image_dropzone' => 'Arrastre las imágenes o hacer click aquí para Subir',
'images_deleted' => 'Imágenes borradas',

View File

@ -61,7 +61,7 @@ return [
'search_updated_after' => 'Actualizadas después de',
'search_created_before' => 'Creadas antes de',
'search_created_after' => 'Creadas después de',
'search_set_date' => 'Ajustar Fecha',
'search_set_date' => 'fecha',
'search_update' => 'Actualizar Búsqueda',
/**

View File

@ -13,7 +13,8 @@ return [
'image_uploaded' => 'Subido el :uploadedDate',
'image_load_more' => 'Cargar más',
'image_image_name' => 'Nombre de imagen',
'image_delete_confirm' => 'Esta imagen esta siendo utilizada en las páginas a continuación, haga click de nuevo para confirmar que quiere borrar esta imagen.',
'image_delete_used' => 'Esta imagen esta siendo utilizada en las páginas a continuación.',
'image_delete_confirm' => 'Haga click de nuevo para confirmar que quiere borrar esta imagen.',
'image_select_image' => 'Seleccionar Imagen',
'image_dropzone' => 'Arrastre las imágenes o hacer click aquí para Subir',
'images_deleted' => 'Imágenes borradas',

View File

@ -13,7 +13,8 @@ return [
'image_uploaded' => 'Ajoutée le :uploadedDate',
'image_load_more' => 'Charger plus',
'image_image_name' => 'Nom de l\'image',
'image_delete_confirm' => 'Cette image est utilisée dans les pages ci-dessous. Confirmez que vous souhaitez bien supprimer cette image.',
'image_delete_used' => 'Cette image est utilisée dans les pages ci-dessous.',
'image_delete_confirm' => 'Confirmez que vous souhaitez bien supprimer cette image.',
'image_select_image' => 'Selectionner l\'image',
'image_dropzone' => 'Glissez les images ici ou cliquez pour les ajouter',
'images_deleted' => 'Images supprimées',

View File

@ -13,7 +13,8 @@ return [
'image_uploaded' => 'Uploaded :uploadedDate',
'image_load_more' => 'Carica Altre',
'image_image_name' => 'Nome Immagine',
'image_delete_confirm' => 'Questa immagine è usata nelle pagine elencate, clicca elimina nuovamente per confermare.',
'image_delete_used' => 'Questa immagine è usata nelle pagine elencate.',
'image_delete_confirm' => 'Clicca elimina nuovamente per confermare.',
'image_select_image' => 'Seleziona Immagine',
'image_dropzone' => 'Rilascia immagini o clicca qui per caricarle',
'images_deleted' => 'Immagini Eliminate',

View File

@ -13,7 +13,8 @@ return [
'image_uploaded' => 'アップロード日時: :uploadedDate',
'image_load_more' => 'さらに読み込む',
'image_image_name' => '画像名',
'image_delete_confirm' => 'この画像は以下のページで利用されています。削除してもよろしければ、再度ボタンを押して下さい。',
'image_delete_used' => 'この画像は以下のページで利用されています。',
'image_delete_confirm' => '削除してもよろしければ、再度ボタンを押して下さい。',
'image_select_image' => '選択',
'image_dropzone' => '画像をドロップするか、クリックしてアップロード',
'images_deleted' => '画像を削除しました',

View File

@ -13,7 +13,8 @@ return [
'image_uploaded' => 'Uploaded :uploadedDate',
'image_load_more' => 'Meer Laden',
'image_image_name' => 'Afbeeldingsnaam',
'image_delete_confirm' => 'Deze afbeeldingen is op onderstaande pagina\'s in gebruik, Klik opnieuw op verwijderen om de afbeelding echt te verwijderen.',
'image_delete_used' => 'Deze afbeeldingen is op onderstaande pagina\'s in gebruik.',
'image_delete_confirm' => 'Klik opnieuw op verwijderen om de afbeelding echt te verwijderen.',
'image_select_image' => 'Kies Afbeelding',
'image_dropzone' => 'Sleep afbeeldingen hier of klik hier om te uploaden',
'images_deleted' => 'Verwijderde Afbeeldingen',

View File

@ -13,7 +13,8 @@ return [
'image_uploaded' => 'Udostępniono :uploadedDate',
'image_load_more' => 'Wczytaj więcej',
'image_image_name' => 'Nazwa obrazka',
'image_delete_confirm' => 'Ten obrazek jest używany na stronach poniżej, kliknij ponownie Usuń by potwierdzić usunięcie obrazka.',
'image_delete_used' => 'Ten obrazek jest używany na stronach poniżej.',
'image_delete_confirm' => 'Kliknij ponownie Usuń by potwierdzić usunięcie obrazka.',
'image_select_image' => 'Wybierz obrazek',
'image_dropzone' => 'Upuść obrazki tutaj lub kliknij by wybrać obrazki do udostępnienia',
'images_deleted' => 'Usunięte obrazki',

View File

@ -13,7 +13,8 @@ return [
'image_uploaded' => 'Carregado :uploadedDate',
'image_load_more' => 'Carregar Mais',
'image_image_name' => 'Nome da Imagem',
'image_delete_confirm' => 'Essa imagem é usada nas páginas abaixo. Clique em Excluir novamente para confirmar que você deseja mesmo eliminar a imagem.',
'image_delete_used' => 'Essa imagem é usada nas páginas abaixo.',
'image_delete_confirm' => 'Clique em Excluir novamente para confirmar que você deseja mesmo eliminar a imagem.',
'image_select_image' => 'Selecionar Imagem',
'image_dropzone' => 'Arraste imagens ou clique aqui para fazer upload',
'images_deleted' => 'Imagens excluídas',

View File

@ -13,7 +13,8 @@ return [
'image_uploaded' => 'Загруженно :uploadedDate',
'image_load_more' => 'Загрузить ещё',
'image_image_name' => 'Имя изображения',
'image_delete_confirm' => 'Это изображение используется на странице ниже. Снова кликните удалить для подтверждения того что вы хотите удалить.',
'image_delete_used' => 'Это изображение используется на странице ниже.',
'image_delete_confirm' => 'Снова кликните удалить для подтверждения того что вы хотите удалить.',
'image_select_image' => 'Выбрать изображение',
'image_dropzone' => 'Перетащите изображение или кликните для загрузки',
'images_deleted' => 'Изображения удалены',

View File

@ -13,7 +13,8 @@ return [
'image_uploaded' => 'Nahrané :uploadedDate',
'image_load_more' => 'Načítať viac',
'image_image_name' => 'Názov obrázka',
'image_delete_confirm' => 'Tento obrázok je použitý na stránkach uvedených nižšie, kliknite znova na zmazať pre potvrdenie zmazania tohto obrázka.',
'image_delete_used' => 'Tento obrázok je použitý na stránkach uvedených nižšie.',
'image_delete_confirm' => 'Kliknite znova na zmazať pre potvrdenie zmazania tohto obrázka.',
'image_select_image' => 'Vybrať obrázok',
'image_dropzone' => 'Presuňte obrázky sem alebo kliknite sem pre nahranie',
'images_deleted' => 'Obrázky zmazané',

View File

@ -13,7 +13,8 @@ return [
'image_uploaded' => 'Laddades upp :uploadedDate',
'image_load_more' => 'Ladda fler',
'image_image_name' => 'Bildnamn',
'image_delete_confirm' => 'Den här bilden används på nedanstående sidor, klicka på "ta bort" en gång till för att bekräfta att du vill ta bort bilden.',
'image_delete_used' => 'Den här bilden används på nedanstående sidor.',
'image_delete_confirm' => 'Klicka på "ta bort" en gång till för att bekräfta att du vill ta bort bilden.',
'image_select_image' => 'Välj bild',
'image_dropzone' => 'Släpp bilder här eller klicka för att ladda upp',
'images_deleted' => 'Bilder borttagna',
@ -21,6 +22,7 @@ return [
'image_upload_success' => 'Bilden har laddats upp',
'image_update_success' => 'Bildens uppgifter har ändrats',
'image_delete_success' => 'Bilden har tagits bort',
'image_upload_remove' => 'Radera',
/**
* Code editor

View File

@ -160,8 +160,9 @@ return [
'pages_name' => 'Sidans namn',
'pages_md_editor' => 'Redigerare',
'pages_md_preview' => 'Förhandsvisa',
'pages_md_insert_image' => 'Inoga bild',
'pages_md_insert_image' => 'Infoga bild',
'pages_md_insert_link' => 'Infoga länk',
'pages_md_insert_drawing' => 'Infoga teckning',
'pages_not_in_chapter' => 'Sidan ligger inte i något kapitel',
'pages_move' => 'Flytta sida',
'pages_move_success' => 'Sidan har flyttats till ":parentName"',
@ -199,8 +200,10 @@ return [
* Editor sidebar
*/
'page_tags' => 'Sidtaggar',
'chapter_tags' => 'Kapiteltaggar',
'book_tags' => 'Boktaggar',
'tag' => 'Tagg',
'tags' => '',
'tags' => 'Taggar',
'tag_value' => 'Taggvärde (Frivilligt)',
'tags_explain' => "Lägg till taggar för att kategorisera ditt innehåll bättre. \n Du kan tilldela ett värde till en tagg för ännu bättre organisering.",
'tags_add' => 'Lägg till ännu en tagg',
@ -244,6 +247,7 @@ return [
*/
'comment' => 'Kommentar',
'comments' => 'Kommentarer',
'comment_add' => 'Lägg till kommentar',
'comment_placeholder' => 'Lämna en kommentar här',
'comment_count' => '{0} Inga kommentarer|{1} 1 kommentar|[2,*] :count kommentarer',
'comment_save' => 'Spara kommentar',

View File

@ -35,10 +35,13 @@ return [
'cannot_get_image_from_url' => 'Kan inte hämta bild från :url',
'cannot_create_thumbs' => 'Servern kan inte skapa miniatyrer. Kontrollera att du har PHPs GD-tillägg aktiverat.',
'server_upload_limit' => 'Servern tillåter inte så här stora filer. Prova en mindre fil.',
'uploaded' => 'Servern tillåter inte så här stora filer. Prova en mindre fil.',
'image_upload_error' => 'Ett fel inträffade vid uppladdningen',
'image_upload_type_error' => 'Filtypen du försöker ladda upp är ogiltig',
// Attachments
'attachment_page_mismatch' => 'Fel i sidmatchning vid uppdatering av bilaga',
'attachment_not_found' => 'Bilagan hittades ej',
// Pages
'page_draft_autosave_fail' => 'Kunde inte spara utkastet. Kontrollera att du är ansluten till internet.',

View File

@ -13,7 +13,8 @@ return [
'image_uploaded' => '上传于 :uploadedDate',
'image_load_more' => '显示更多',
'image_image_name' => '图片名称',
'image_delete_confirm' => '该图像用于以下页面,如果你想删除它,请再次按下按钮。',
'image_delete_used' => '该图像用于以下页面。',
'image_delete_confirm' => '如果你想删除它,请再次按下按钮。',
'image_select_image' => '选择图片',
'image_dropzone' => '拖放图片或点击此处上传',
'images_deleted' => '图片已删除',

View File

@ -13,7 +13,8 @@ return [
'image_uploaded' => '上傳於 :uploadedDate',
'image_load_more' => '載入更多',
'image_image_name' => '圖片名稱',
'image_delete_confirm' => '所使用圖片目前用於以下頁面,如果你想刪除它,請再次按下按鈕。',
'image_delete_used' => '所使用圖片目前用於以下頁面。',
'image_delete_confirm' => '如果你想刪除它,請再次按下按鈕。',
'image_select_image' => '選擇圖片',
'image_dropzone' => '拖曳圖片或點選這裡上傳',
'images_deleted' => '圖片已刪除',

View File

@ -33,7 +33,7 @@
<header id="header">
<div class="container fluid">
<div class="row">
<div class="col-sm-4" ng-non-bindable>
<div class="col-sm-4">
<a href="{{ baseUrl('/') }}" class="logo">
@if(setting('app-logo', '') !== 'none')
<img class="logo-image" src="{{ setting('app-logo', '') === '' ? baseUrl('/logo.png') : baseUrl(setting('app-logo', '')) }}" alt="Logo">

View File

@ -12,7 +12,7 @@
@section('body')
<div ng-non-bindable class="container small">
<div class="container small">
<p>&nbsp;</p>
<div class="card">
<h3>@icon('add') {{ trans('entities.books_create') }}</h3>

View File

@ -8,7 +8,7 @@
@section('body')
<div class="container small" ng-non-bindable>
<div class="container small">
<p>&nbsp;</p>
<div class="card">
<h3>@icon('delete') {{ trans('entities.books_delete') }}</h3>

View File

@ -8,7 +8,7 @@
@section('body')
<div class="container small" ng-non-bindable>
<div class="container small">
<p>&nbsp;</p>
<div class="card">
<h3>@icon('edit') {{ trans('entities.books_edit') }}</h3>

View File

@ -12,7 +12,7 @@
<p >{{ $book->getExcerpt(130) }}</p>
@endif
</div>
<div class="grid-card-footer">
<div class="grid-card-footer text-muted text-small">
<span>@include('partials.entity-meta', ['entity' => $book])</span>
</div>
</div>

View File

@ -3,16 +3,7 @@
@section('toolbar')
<div class="col-xs-6">
<div class="action-buttons text-left">
<form action="{{ baseUrl("/settings/users/{$currentUser->id}/switch-book-view") }}" method="POST" class="inline">
{!! csrf_field() !!}
{!! method_field('PATCH') !!}
<input type="hidden" value="{{ $booksViewType === 'list'? 'grid' : 'list' }}" name="book_view_type">
@if ($booksViewType === 'list')
<button type="submit" class="text-pos text-button">@icon('grid'){{ trans('common.grid_view') }}</button>
@else
<button type="submit" class="text-pos text-button">@icon('list'){{ trans('common.list_view') }}</button>
@endif
</form>
@include('books/view-toggle', ['booksViewType' => $booksViewType])
</div>
</div>
<div class="col-xs-6 faded">
@ -52,34 +43,5 @@
@stop
@section('body')
@if($booksViewType === 'list')
<div class="container small" ng-non-bindable>
@else
<div class="container" ng-non-bindable>
@endif
<h1>{{ trans('entities.books') }}</h1>
@if(count($books) > 0)
@if($booksViewType === 'list')
@foreach($books as $book)
@include('books/list-item', ['book' => $book])
<hr>
@endforeach
{!! $books->render() !!}
@else
<div class="grid third">
@foreach($books as $key => $book)
@include('books/grid-item', ['book' => $book])
@endforeach
</div>
<div>
{!! $books->render() !!}
</div>
@endif
@else
<p class="text-muted">{{ trans('entities.books_empty') }}</p>
@if(userCan('books-create-all'))
<a href="{{ baseUrl("/create-book") }}" class="text-pos">@icon('edit'){{ trans('entities.create_one_now') }}</a>
@endif
@endif
</div>
@include('books/list', ['books' => $books, 'bookViewType' => $booksViewType])
@stop

View File

@ -0,0 +1,31 @@
@if($booksViewType === 'list')
<div class="container small">
@else
<div class="container">
@endif
<h1>{{ trans('entities.books') }}</h1>
@if(count($books) > 0)
@if($booksViewType === 'list')
@foreach($books as $book)
@include('books/list-item', ['book' => $book])
<hr>
@endforeach
{!! $books->render() !!}
@else
<div class="grid third">
@foreach($books as $key => $book)
@include('books/grid-item', ['book' => $book])
@endforeach
</div>
<div>
{!! $books->render() !!}
</div>
@endif
@else
<p class="text-muted">{{ trans('entities.books_empty') }}</p>
@if(userCan('books-create-all'))
<a href="{{ baseUrl("/create-book") }}" class="text-pos">@icon('edit'){{ trans('entities.create_one_now') }}</a>
@endif
@endif
</div>

View File

@ -8,7 +8,7 @@
@section('body')
<div class="container" ng-non-bindable>
<div class="container">
<p>&nbsp;</p>
<div class="card">
<h3>@icon('lock') {{ trans('entities.books_permissions') }}</h3>

View File

@ -43,6 +43,12 @@
@section('sidebar')
@if($book->tags->count() > 0)
<section>
@include('components.tag-list', ['entity' => $book])
</section>
@endif
<div class="card">
<div class="body">
<form v-on:submit.prevent="searchBook" class="search-box">
@ -53,35 +59,19 @@
</div>
</div>
<div class="card entity-details">
<h3>@icon('info') {{ trans('common.details') }}</h3>
<div class="body text-small text-muted blended-links">
@include('partials.entity-meta', ['entity' => $book])
@if($book->restricted)
<div class="card">
<h3>@icon('permission') {{ trans('entities.permissions') }}</h3>
<div class="body">
<p class="text-muted">
<div class="active-restriction">
@if(userCan('restrictions-manage', $book))
<a href="{{ $book->getUrl('/permissions') }}">@icon('lock'){{ trans('entities.books_permissions_active') }}</a>
@else
@icon('lock'){{ trans('entities.books_permissions_active') }}
@endif
</p>
</div>
</div>
@endif
@if($book->tags->count() > 0)
<div class="card tag-display">
<h3>@icon('tag') {{ trans('entities.book_tags') }}</h3>
<div class="body">
@include('components.tag-list', ['entity' => $book])
</div>
</div>
@endif
<div class="card">
<h3>@icon('info') {{ trans('common.details') }}</h3>
<div class="body">
@include('partials.entity-meta', ['entity' => $book])
</div>
</div>

View File

@ -1,4 +1,4 @@
<div class="sort-box" data-type="book" data-id="{{ $book->id }}" ng-non-bindable>
<div class="sort-box" data-type="book" data-id="{{ $book->id }}">
<h3 class="text-book">@icon('book'){{ $book->name }}</h3>
<ul class="sortable-page-list sort-list">
@foreach($bookChildren as $bookChild)

View File

@ -8,7 +8,7 @@
@section('body')
<div class="container" ng-non-bindable>
<div class="container">
<div class="row">
<div class="col-md-8">

View File

@ -0,0 +1,10 @@
<form action="{{ baseUrl("/settings/users/{$currentUser->id}/switch-book-view") }}" method="POST" class="inline">
{!! csrf_field() !!}
{!! method_field('PATCH') !!}
<input type="hidden" value="{{ $booksViewType === 'list'? 'grid' : 'list' }}" name="book_view_type">
@if ($booksViewType === 'list')
<button type="submit" class="text-pos text-button">@icon('grid'){{ trans('common.grid_view') }}</button>
@else
<button type="submit" class="text-pos text-button">@icon('list'){{ trans('common.list_view') }}</button>
@endif
</form>

View File

@ -12,7 +12,7 @@
@section('body')
<div class="container small" ng-non-bindable>
<div class="container small">
<div class="card">
<h3>@icon('add') {{ trans('entities.chapters_create') }}</h3>
<div class="body">

View File

@ -8,7 +8,7 @@
@section('body')
<div class="container small" ng-non-bindable>
<div class="container small">
<p>&nbsp;</p>
<div class="card">
<h3>@icon('delete') {{ trans('entities.chapters_delete') }}</h3>

View File

@ -8,7 +8,7 @@
@section('body')
<div class="container small" ng-non-bindable>
<div class="container small">
<p>&nbsp;</p>
<div class="card">
<h3>@icon('edit') {{ trans('entities.chapters_edit') }}</h3>

View File

@ -8,7 +8,7 @@
@section('body')
<div class="container" ng-non-bindable>
<div class="container">
<p>&nbsp;</p>
<div class="card">
<h3>@icon('lock') {{ trans('entities.chapters_permissions') }}</h3>

View File

@ -47,6 +47,13 @@
@stop
@section('sidebar')
@if($chapter->tags->count() > 0)
<section>
@include('components.tag-list', ['entity' => $chapter])
</section>
@endif
<div class="card">
<div class="body">
<form @submit.prevent="searchBook" class="search-box">
@ -57,47 +64,30 @@
</div>
</div>
@if($book->restricted || $chapter->restricted)
<div class="card">
<h3>@icon('permission') {{ trans('entities.permissions') }}</h3>
<div class="body">
<div class="card entity-details">
<h3>@icon('info') {{ trans('common.details') }}</h3>
<div class="body blended-links text-small text-muted">
@include('partials.entity-meta', ['entity' => $chapter])
@if($book->restricted)
<p class="text-muted">
<div class="active-restriction">
@if(userCan('restrictions-manage', $book))
<a href="{{ $book->getUrl('/permissions') }}">@icon('lock'){{ trans('entities.books_permissions_active') }}</a>
@else
@icon('lock'){{ trans('entities.books_permissions_active') }}
@endif
</p>
</div>
@endif
@if($chapter->restricted)
<p class="text-muted">
<div class="active-restriction">
@if(userCan('restrictions-manage', $chapter))
<a href="{{ $chapter->getUrl('/permissions') }}">@icon('lock'){{ trans('entities.chapters_permissions_active') }}</a>
@else
@icon('lock'){{ trans('entities.chapters_permissions_active') }}
@endif
</p>
@endif
</div>
</div>
@endif
@if($chapter->tags->count() > 0)
<div class="card tag-display">
<h3>@icon('tag') {{ trans('entities.chapter_tags') }}</h3>
<div class="body">
@include('components.tag-list', ['entity' => $chapter])
</div>
</div>
@endif
<div class="card">
<h3>@icon('info') {{ trans('common.details') }}</h3>
<div class="body">
@include('partials.entity-meta', ['entity' => $chapter])
</div>
</div>

View File

@ -1,5 +1,5 @@
<div page-comments page-id="{{ $page->id }}" ng-non-bindable class="comments-list">
<h3 comments-title>{{ trans_choice('entities.comment_count', count($page->comments), ['count' => count($page->comments)]) }}</h3>
<div page-comments page-id="{{ $page->id }}" class="comments-list">
<h5 comments-title class="float left">{{ trans_choice('entities.comment_count', count($page->comments), ['count' => count($page->comments)]) }}</h5>
<div class="comment-container" comment-container>
@foreach($page->comments as $comment)
@ -7,7 +7,6 @@
@endforeach
</div>
@if(userCan('comment-create-all'))
<div class="comment-box" comment-box style="display:none;">
@ -33,7 +32,7 @@
</div>
<div class="form-group" comment-add-button>
<button type="button" action="addComment" class="button outline">{{ trans('entities.comment_add') }}</button>
<button type="button" action="addComment" class="button outline float right">{{ trans('entities.comment_add') }}</button>
</div>
@endif

View File

@ -0,0 +1,18 @@
@extends('sidebar-layout')
@section('toolbar')
<div class="col-sm-6 faded">
<div class="action-buttons text-left">
<a expand-toggle=".entity-list.compact .entity-item-snippet" class="text-primary text-button">@icon('expand-text'){{ trans('common.toggle_details') }}</a>
@include('books/view-toggle', ['booksViewType' => $booksViewType])
</div>
</div>
@stop
@section('sidebar')
@include('common/home-sidebar')
@stop
@section('body')
@include('books/list', ['books' => $books, 'bookViewType' => $booksViewType])
@stop

View File

@ -0,0 +1,19 @@
@extends('sidebar-layout')
@section('toolbar')
<div class="col-sm-6 faded">
<div class="action-buttons text-left">
<a expand-toggle=".entity-list.compact .entity-item-snippet" class="text-primary text-button">@icon('expand-text'){{ trans('common.toggle_details') }}</a>
</div>
</div>
@stop
@section('sidebar')
@include('common/home-sidebar')
@stop
@section('body')
<div class="page-content" page-display="{{ $customHomepage->id }}">
@include('pages/page-display', ['page' => $customHomepage])
</div>
@stop

View File

@ -0,0 +1,31 @@
@if(count($draftPages) > 0)
<div id="recent-drafts" class="card">
<h3>@icon('edit') {{ trans('entities.my_recent_drafts') }}</h3>
@include('partials/entity-list', ['entities' => $draftPages, 'style' => 'compact'])
</div>
@endif
<div class="card">
<h3>@icon($signedIn ? 'view' : 'star-circle') {{ trans('entities.' . ($signedIn ? 'my_recently_viewed' : 'books_recent')) }}</h3>
@include('partials/entity-list', [
'entities' => $recents,
'style' => 'compact',
'emptyText' => $signedIn ? trans('entities.no_pages_viewed') : trans('entities.books_empty')
])
</div>
<div class="card">
<h3>@icon('file') <a class="no-color" href="{{ baseUrl("/pages/recently-updated") }}">{{ trans('entities.recently_updated_pages') }}</a></h3>
<div id="recently-updated-pages">
@include('partials/entity-list', [
'entities' => $recentlyUpdatedPages,
'style' => 'compact',
'emptyText' => trans('entities.no_pages_recently_updated')
])
</div>
</div>
<div id="recent-activity" class="card">
<h3>@icon('time') {{ trans('entities.recent_activity') }}</h3>
@include('partials/activity-list', ['activity' => $activity])
</div>

View File

@ -10,7 +10,7 @@
@section('body')
<div class="container" ng-non-bindable>
<div class="container">
<div class="row">
<div class="col-sm-4">

View File

@ -1,5 +1,5 @@
<div id="image-manager" image-type="{{ $imageType }}" uploaded-to="{{ $uploaded_to or 0 }}">
<div overlay v-cloak @click="hide()">
<div overlay v-cloak @click="hide">
<div class="popup-body" @click.stop="">
<div class="popup-header primary-background">
@ -40,26 +40,38 @@
</div>
<div class="image-manager-sidebar">
<dropzone v-if="imageType !== 'drawio'" ref="dropzone" placeholder="{{ trans('components.image_dropzone') }}" :upload-url="uploadUrl" :uploaded-to="uploadedTo" @success="uploadSuccess"></dropzone>
<div class="inner">
<div class="image-manager-details anim fadeIn" v-if="selectedImage">
<form @submit.prevent="saveImageDetails">
<div>
<div class="image-manager-viewer">
<a :href="selectedImage.url" target="_blank" style="display: block;">
<img :src="selectedImage.thumbs.gallery" :alt="selectedImage.title"
<img :src="selectedImage.thumbs.display" :alt="selectedImage.name"
:title="selectedImage.name">
</a>
</div>
<div class="form-group">
<label for="name">{{ trans('components.image_image_name') }}</label>
<input id="name" name="name" v-model="selectedImage.name">
<input id="name" class="input-base" name="name" v-model="selectedImage.name">
</div>
</form>
<div class="clearfix">
<div class="float left">
<button type="button" class="button icon outline" @click="deleteImage">@icon('delete')</button>
</div>
<button class="button anim fadeIn float right" v-show="selectedImage" @click="callbackAndHide(selectedImage)">
{{ trans('components.image_select_image') }}
</button>
<div class="clearfix"></div>
<div v-show="dependantPages">
<p class="text-neg text-small">
{{ trans('components.image_delete_confirm') }}
{{ trans('components.image_delete_used') }}
</p>
<ul class="text-neg">
<li v-for="page in dependantPages">
@ -67,19 +79,14 @@
</li>
</ul>
</div>
<div class="clearfix">
<form class="float left" @submit.prevent="deleteImage">
<button class="button icon neg">@icon('delete')</button>
</form>
<button class="button pos anim fadeIn float right" v-show="selectedImage" @click="callbackAndHide(selectedImage)">
{{ trans('components.image_select_image') }}
</button>
<div v-show="deleteConfirm" class="text-neg text-small">
{{ trans('components.image_delete_confirm') }}
</div>
</div>
</div>
<dropzone ref="dropzone" placeholder="{{ trans('components.image_dropzone') }}" :upload-url="uploadUrl" :uploaded-to="uploadedTo" @success="uploadSuccess"></dropzone>
</div>
</div>

View File

@ -1,10 +1,6 @@
<table>
<tbody>
@foreach($entity->tags as $tag)
<tr class="tag">
<td @if(!$tag->value) colspan="2" @endif><a href="{{ baseUrl('/search?term=%5B' . urlencode($tag->name) .'%5D') }}">{{ $tag->name }}</a></td>
@if($tag->value) <td class="tag-value"><a href="{{ baseUrl('/search?term=%5B' . urlencode($tag->name) .'%3D' . urlencode($tag->value) . '%5D') }}">{{$tag->value}}</a></td> @endif
</tr>
<div class="tag-item primary-background-light">
<div class="tag-name"><a href="{{ baseUrl('/search?term=%5B' . urlencode($tag->name) .'%5D') }}">@icon('tag'){{ $tag->name }}</a></div>
@if($tag->value) <div class="tag-value"><a href="{{ baseUrl('/search?term=%5B' . urlencode($tag->name) .'%3D' . urlencode($tag->value) . '%5D') }}">{{$tag->value}}</a></div> @endif
</div>
@endforeach
</tbody>
</table>

View File

@ -1,56 +0,0 @@
@extends('sidebar-layout')
@section('toolbar')
<div class="col-sm-6 faded">
<div class="action-buttons text-left">
<a expand-toggle=".entity-list.compact .entity-item-snippet" class="text-primary text-button">@icon('expand-text'){{ trans('common.toggle_details') }}</a>
</div>
</div>
@stop
@section('sidebar')
@if(count($draftPages) > 0)
<div id="recent-drafts" class="card">
<h3>@icon('edit') {{ trans('entities.my_recent_drafts') }}</h3>
@include('partials/entity-list', ['entities' => $draftPages, 'style' => 'compact'])
</div>
@endif
<div class="card">
<h3>@icon($signedIn ? 'view' : 'star-circle') {{ trans('entities.' . ($signedIn ? 'my_recently_viewed' : 'books_recent')) }}</h3>
@include('partials/entity-list', [
'entities' => $recents,
'style' => 'compact',
'emptyText' => $signedIn ? trans('entities.no_pages_viewed') : trans('entities.books_empty')
])
</div>
<div class="card">
<h3>@icon('file') <a class="no-color" href="{{ baseUrl("/pages/recently-updated") }}">{{ trans('entities.recently_updated_pages') }}</a></h3>
<div id="recently-updated-pages">
@include('partials/entity-list', [
'entities' => $recentlyUpdatedPages,
'style' => 'compact',
'emptyText' => trans('entities.no_pages_recently_updated')
])
</div>
</div>
<div id="recent-activity" class="card">
<h3>@icon('time') {{ trans('entities.recent_activity') }}</h3>
@include('partials/activity-list', ['activity' => $activity])
</div>
@stop
@section('body')
<div class="page-content" ng-non-bindable>
@include('pages/page-display', ['page' => $customHomepage])
</div>
@stop
@section('scripts')
<script>
setupPageShow({{$customHomepage->id}});
</script>
@stop

View File

@ -8,7 +8,7 @@
@section('body')
<div class="container small" ng-non-bindable>
<div class="container small">
<p>&nbsp;</p>
<div class="card">
<h3>@icon('delete') {{ $page->draft ? trans('entities.pages_delete_draft') : trans('entities.pages_delete') }}</h3>

View File

@ -21,7 +21,9 @@
<hr>
<div class="text-muted text-small">
@include('partials.entity-meta', ['entity' => $page])
</div>
</div>
</div>

View File

@ -2,7 +2,7 @@
@section('content')
<div class="container small" ng-non-bindable>
<div class="container small">
<h1>{{ trans('entities.pages_new') }}</h1>
<form action="{{ $parent->getUrl('/create-guest-page') }}" method="POST">

View File

@ -1,4 +1,4 @@
<div ng-non-bindable>
<div>
<h1 class="break-text" v-pre id="bkmrk-page-title">{{$page->name}}</h1>

View File

@ -7,7 +7,7 @@
@stop
@section('body')
<div class="container" ng-non-bindable>
<div class="container">
<p>&nbsp;</p>
<div class="card">
<h3>@icon('lock') {{ trans('entities.pages_permissions') }}</h3>

View File

@ -3,7 +3,7 @@
@section('sidebar')
<div class="card">
<h3>@icon('info') {{ trans('common.details') }}</h3>
<div class="body">
<div class="body text-small text-muted">
@include('partials.entity-meta', ['entity' => $revision])
</div>
</div>
@ -11,7 +11,7 @@
@section('body')
<div class="container" ng-non-bindable>
<div class="container">
<div class="row">
<div class="col-md-9">
<div class="page-content">

View File

@ -7,7 +7,7 @@
@stop
@section('body')
<div class="container" ng-non-bindable>
<div class="container">
<p>&nbsp;</p>
<div class="card">

View File

@ -41,50 +41,11 @@
@stop
@section('sidebar')
@if($book->restricted || ($page->chapter && $page->chapter->restricted) || $page->restricted)
<div class="card">
<h3>@icon('permission') {{ trans('entities.permissions') }}</h3>
<div class="body">
<div class="text-muted">
@if($book->restricted)
@if(userCan('restrictions-manage', $book))
<a href="{{ $book->getUrl('/permissions') }}">@icon('lock'){{ trans('entities.books_permissions_active') }}</a>
@else
@icon('lock'){{ trans('entities.books_permissions_active') }}
@endif
<br>
@endif
@if($page->chapter && $page->chapter->restricted)
@if(userCan('restrictions-manage', $page->chapter))
<a href="{{ $page->chapter->getUrl('/permissions') }}">@icon('lock'){{ trans('entities.chapters_permissions_active') }}</a>
@else
@icon('lock'){{ trans('entities.chapters_permissions_active') }}
@endif
<br>
@endif
@if($page->restricted)
@if(userCan('restrictions-manage', $page))
<a href="{{ $page->getUrl('/permissions') }}">@icon('lock'){{ trans('entities.pages_permissions_active') }}</a>
@else
@icon('lock'){{ trans('entities.pages_permissions_active') }}
@endif
<br>
@endif
</div>
</div>
</div>
@endif
@if($page->tags->count() > 0)
<div class="card tag-display">
<h3>@icon('tag') {{ trans('entities.page_tags') }}</h3>
<div class="body">
<section>
@include('components.tag-list', ['entity' => $page])
</div>
</div>
</section>
@endif
@if ($page->attachments->count() > 0)
@ -115,10 +76,40 @@
</div>
@endif
<div class="card">
<div class="card entity-details">
<h3>@icon('info') {{ trans('common.details') }}</h3>
<div class="body">
<div class="body text-muted text-small blended-links">
@include('partials.entity-meta', ['entity' => $page])
@if($book->restricted)
<div class="active-restriction">
@if(userCan('restrictions-manage', $book))
<a href="{{ $book->getUrl('/permissions') }}">@icon('lock'){{ trans('entities.books_permissions_active') }}</a>
@else
@icon('lock'){{ trans('entities.books_permissions_active') }}
@endif
</div>
@endif
@if($page->chapter && $page->chapter->restricted)
<div class="active-restriction">
@if(userCan('restrictions-manage', $page->chapter))
<a href="{{ $page->chapter->getUrl('/permissions') }}">@icon('lock'){{ trans('entities.chapters_permissions_active') }}</a>
@else
@icon('lock'){{ trans('entities.chapters_permissions_active') }}
@endif
</div>
@endif
@if($page->restricted)
<div class="active-restriction">
@if(userCan('restrictions-manage', $page))
<a href="{{ $page->getUrl('/permissions') }}">@icon('lock'){{ trans('entities.pages_permissions_active') }}</a>
@else
@icon('lock'){{ trans('entities.pages_permissions_active') }}
@endif
</div>
@endif
</div>
</div>
@ -126,8 +117,11 @@
@stop
@section('body-wrap-classes', 'flex-fill columns')
@section('body')
<div class="page-content" page-display="{{ $page->id }}" ng-non-bindable>
<div class="page-content flex" page-display="{{ $page->id }}">
<div class="pointer-container" id="pointer">
<div class="pointer anim" >
@ -138,10 +132,10 @@
</div>
@include('pages/page-display')
</div>
@if ($commentsEnabled)
<div class="container small nopad">
<div class="container small nopad comments-container">
@include('comments/comments', ['page' => $page])
</div>
@endif

View File

@ -1,7 +1,7 @@
<div class="dropdown-container" dropdown>
<span class="user-name" dropdown-toggle>
<img class="avatar" src="{{$currentUser->getAvatar(30)}}" alt="{{ $currentUser->name }}">
<span class="name" ng-non-bindable>{{ $currentUser->getShortName(9) }}</span> @icon('caret-down')
<span class="name">{{ $currentUser->getShortName(9) }}</span> @icon('caret-down')
</span>
<ul>
<li>

View File

@ -1,5 +1,5 @@
<div class="entity-list @if(isset($style)){{ $style }}@endif" ng-non-bindable>
<div class="entity-list @if(isset($style)){{ $style }}@endif">
@if(count($entities) > 0)
@foreach($entities as $index => $entity)
@if($entity->isA('page'))

View File

@ -1,25 +1,34 @@
<p class="text-muted small">
<div class="entity-meta">
@if($entity->isA('revision'))
{{ trans('entities.pages_revision') }}
@icon('history'){{ trans('entities.pages_revision') }}
{{ trans('entities.pages_revisions_number') }}{{ $entity->revision_number == 0 ? '' : $entity->revision_number }}
<br>
@endif
@if ($entity->isA('page')) {{ trans('entities.meta_revision', ['revisionCount' => $entity->revision_count]) }} <br> @endif
@if ($entity->isA('page'))
@if (userCan('page-update', $entity)) <a href="{{ $entity->getUrl('/revisions') }}"> @endif
@icon('history'){{ trans('entities.meta_revision', ['revisionCount' => $entity->revision_count]) }} <br>
@if (userCan('page-update', $entity))</a>@endif
@endif
@if ($entity->createdBy)
{!! trans('entities.meta_created_name', [
@icon('star'){!! trans('entities.meta_created_name', [
'timeLength' => '<span title="'.$entity->created_at->toDayDateTimeString().'">'.$entity->created_at->diffForHumans() . '</span>',
'user' => "<a href='{$entity->createdBy->getProfileUrl()}'>".htmlentities($entity->createdBy->name). "</a>"
]) !!}
@else
<span title="{{$entity->created_at->toDayDateTimeString()}}">{{ trans('entities.meta_created', ['timeLength' => $entity->created_at->diffForHumans()]) }}</span>
@icon('star')<span title="{{$entity->created_at->toDayDateTimeString()}}">{{ trans('entities.meta_created', ['timeLength' => $entity->created_at->diffForHumans()]) }}</span>
@endif
<br>
@if ($entity->updatedBy)
{!! trans('entities.meta_updated_name', [
@icon('edit'){!! trans('entities.meta_updated_name', [
'timeLength' => '<span title="' . $entity->updated_at->toDayDateTimeString() .'">' . $entity->updated_at->diffForHumans() .'</span>',
'user' => "<a href='{$entity->updatedBy->getProfileUrl()}'>".htmlentities($entity->updatedBy->name). "</a>"
]) !!}
@elseif (!$entity->isA('revision'))
<span title="{{ $entity->updated_at->toDayDateTimeString() }}">{{ trans('entities.meta_updated', ['timeLength' => $entity->updated_at->diffForHumans()]) }}</span>
@icon('edit')<span title="{{ $entity->updated_at->toDayDateTimeString() }}">{{ trans('entities.meta_updated', ['timeLength' => $entity->updated_at->diffForHumans()]) }}</span>
@endif
</p>
</div>

View File

@ -10,7 +10,6 @@
@section('container-attrs')
id="search-system"
ng-non-bindable=""
@stop
@section('sidebar')

View File

@ -1,4 +1,4 @@
<div class="entity-list @if(isset($style)){{ $style }}@endif" ng-non-bindable>
<div class="entity-list @if(isset($style)){{ $style }}@endif">
@if(count($entities) > 0)
@foreach($entities as $index => $entity)
@if($entity->isA('page'))

View File

@ -80,6 +80,8 @@
<label for="setting-app-homepage">{{ trans('settings.app_homepage') }}</label>
<p class="small">{{ trans('settings.app_homepage_desc') }}</p>
@include('components.page-picker', ['name' => 'setting-app-homepage', 'placeholder' => trans('settings.app_homepage_default'), 'value' => setting('app-homepage')])
<p class="small">{{ trans('settings.app_homepage_books') }}</p>
@include('components.toggle-switch', ['name' => 'setting-app-book-homepage', 'value' => setting('app-book-homepage')])
</div>
</div>

View File

@ -0,0 +1,49 @@
@extends('simple-layout')
@section('toolbar')
@include('settings/navbar', ['selected' => 'maintenance'])
@stop
@section('body')
<div class="container small">
<div class="text-right text-muted container">
<br>
BookStack @if(strpos($version, 'v') !== 0) version @endif {{ $version }}
</div>
<div class="card" id="image-cleanup">
<h3>@icon('images') {{ trans('settings.maint_image_cleanup') }}</h3>
<div class="body">
<div class="row">
<div class="col-sm-6">
<p class="small muted">{{ trans('settings.maint_image_cleanup_desc') }}</p>
</div>
<div class="col-sm-6">
<form method="POST" action="{{ baseUrl('/settings/maintenance/cleanup-images') }}">
{!! csrf_field() !!}
<input type="hidden" name="_method" value="DELETE">
<div>
@if(session()->has('cleanup-images-warning'))
<p class="text neg">
{{ session()->get('cleanup-images-warning') }}
</p>
<input type="hidden" name="ignore_revisions" value="{{ session()->getOldInput('ignore_revisions', 'false') }}">
<input type="hidden" name="confirm" value="true">
@else
<label>
<input type="checkbox" name="ignore_revisions" value="true">
{{ trans('settings.maint_image_cleanup_ignore_revisions') }}
</label>
@endif
</div>
<button class="button outline">{{ trans('settings.maint_image_cleanup_run') }}</button>
</form>
</div>
</div>
</div>
</div>
</div>
@stop

Some files were not shown because too many files have changed in this diff Show More