feat: new settings and mainpage blocks
This commit is contained in:
7
frontend/admin/src/utils/helpers.js
Normal file
7
frontend/admin/src/utils/helpers.js
Normal file
@@ -0,0 +1,7 @@
|
||||
export function getThumb(imageUrl) {
|
||||
if (!imageUrl) return '/image/cache/no_image-100x100.png';
|
||||
const extIndex = imageUrl.lastIndexOf('.');
|
||||
const ext = imageUrl.substring(extIndex);
|
||||
const filename = imageUrl.substring(0, extIndex);
|
||||
return `/image/cache/${filename}-100x100${ext}`;
|
||||
}
|
||||
Reference in New Issue
Block a user