mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-22 10:21:36 +03:00
0bdaa216e5
- Ghost has a set of core packages that it is safe to require directly in any file - tpl is one of them! - This keeps the DI signature smaller and easier to reason about
16 lines
710 B
JavaScript
16 lines
710 B
JavaScript
const BlogIcon = require('./blog-icon');
|
|
const CachedImageSizeFromUrl = require('./cached-image-size-from-url');
|
|
const Gravatar = require('./gravatar');
|
|
const ImageSize = require('./image-size');
|
|
|
|
class ImageUtils {
|
|
constructor({config, logging, urlUtils, settingsCache, storageUtils, storage, validator, request}) {
|
|
this.blogIcon = new BlogIcon({config, urlUtils, settingsCache, storageUtils});
|
|
this.imageSize = new ImageSize({config, storage, storageUtils, validator, urlUtils, request});
|
|
this.cachedImageSizeFromUrl = new CachedImageSizeFromUrl({logging, imageSize: this.imageSize});
|
|
this.gravatar = new Gravatar({config, request});
|
|
}
|
|
}
|
|
|
|
module.exports = ImageUtils;
|