forked from Blendman974/faceclaw
Refactor dashboard cards
This commit is contained in:
1 parent
7afb98f7f7
commit
8d99ea97b5
5 files changed
+179
-153
No files matched your search
@@ -0,0 +1,16 @@
|
||||
import { GrayImage } from "./image";
|
||||
import { loadPngAsGrayImage } from "./imagefile";
|
||||
|
||||
let cachedDashboardLogo: GrayImage | null | undefined;
|
||||
|
||||
export function getDashboardLogo(): GrayImage | null {
|
||||
if (cachedDashboardLogo !== undefined) {
|
||||
return cachedDashboardLogo;
|
||||
}
|
||||
try {
|
||||
cachedDashboardLogo = loadPngAsGrayImage("images/faceclaw-logo-dashboard.png");
|
||||
} catch {
|
||||
cachedDashboardLogo = null;
|
||||
}
|
||||
return cachedDashboardLogo;
|
||||
}
|
||||
Reference in new issue
Block a user