fix: load png brand assets
This commit is contained in:
1 parent
ffd094d631
commit
11d8b42198
5 files changed
+7
-3
No files matched your search
@@ -45,7 +45,7 @@ function isAllowedAssetPath(assetName: string, isVendorAsset: boolean, isAppAsse
|
||||
}
|
||||
|
||||
if (isAppAsset) {
|
||||
return /^[a-z0-9_.-]+\.svg$/i.test(assetName);
|
||||
return /^[a-z0-9_.-]+\.(svg|png)$/i.test(assetName);
|
||||
}
|
||||
|
||||
if (isVendorAsset) {
|
||||
@@ -68,5 +68,9 @@ function getContentType(assetName: string): string {
|
||||
return "image/svg+xml; charset=utf-8";
|
||||
}
|
||||
|
||||
if (assetName.endsWith(".png")) {
|
||||
return "image/png";
|
||||
}
|
||||
|
||||
return "text/javascript; charset=utf-8";
|
||||
}
|
||||
@@ -52,7 +52,7 @@ ${APP_STYLES}
|
||||
<img
|
||||
class="panel-logo"
|
||||
id="panel-logo"
|
||||
src="/assets/logo-light.svg"
|
||||
src="/assets/logo-light.png"
|
||||
alt="mapix"
|
||||
width="156"
|
||||
height="66"
|
||||
|
||||
Reference in new issue
Block a user