1
0
Fork 0
mirror of https://github.com/muerwre/vault-frontend.git synced 2025-04-24 20:36:40 +07:00

fixed flow hero appearance

This commit is contained in:
Fedor Katurov 2023-10-27 11:21:04 +06:00
parent 4f89abda26
commit 291c3421bf
3 changed files with 26 additions and 12 deletions

View file

@ -70,15 +70,15 @@ export const describeArc = (
].join(' ');
};
export const getURLFromString = (url?: string, size?: ImagePreset): string => {
if (size) {
return (url || '').replace(
'REMOTE_CURRENT://',
`${CONFIG.remoteCurrent}cache/${size}/`,
);
export const getURLFromString = (url = '', size?: ImagePreset): string => {
if (!size) {
return url.replace('REMOTE_CURRENT://', CONFIG.remoteCurrent);
}
return (url || '').replace('REMOTE_CURRENT://', CONFIG.remoteCurrent);
return url.replace(
'REMOTE_CURRENT://',
`${CONFIG.remoteCurrent}cache/${size}/`,
);
};
export const getURL = (