mirror of
https://github.com/BookStackApp/BookStack.git
synced 2025-07-31 15:24:31 +03:00
Started work on drawing revisions
Improved sidebar and selection styling of image manager. Allowed image manager imageType to be changed on open. Created models for image revisions.
This commit is contained in:
@ -9,13 +9,23 @@ class Image extends Ownable
|
||||
|
||||
/**
|
||||
* Get a thumbnail for this image.
|
||||
* @param int $width
|
||||
* @param int $height
|
||||
* @param int $width
|
||||
* @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);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the revisions for this image.
|
||||
* @return \Illuminate\Database\Eloquent\Relations\HasMany
|
||||
*/
|
||||
public function revisions()
|
||||
{
|
||||
return $this->hasMany(ImageRevision::class);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user