diff --git a/components/pwa-install-prompt.tsx b/components/pwa-install-prompt.tsx index c5ac68c9..cb21f7e1 100644 --- a/components/pwa-install-prompt.tsx +++ b/components/pwa-install-prompt.tsx @@ -2,6 +2,7 @@ import { useEffect, useState } from "react"; import { X, Download } from "lucide-react"; +import { useConfig } from "@/hooks/use-config"; interface BeforeInstallPromptEvent extends Event { prompt: () => Promise; @@ -14,6 +15,7 @@ export function PWAInstallPrompt() { const [deferredPrompt, setDeferredPrompt] = useState(null); const [showPrompt, setShowPrompt] = useState(false); + const { appName, faviconUrl, appLogoLightUrl, appLogoDarkUrl } = useConfig(); useEffect(() => { if (localStorage.getItem(DISMISSED_KEY)) return; @@ -56,14 +58,31 @@ export function PWAInstallPrompt() { return null; } + const logoSrc = appLogoLightUrl || faviconUrl; + return (
- + {logoSrc ? ( + {appName} + ) : ( + + )} + {logoSrc && ( + {appName} + )}

- Install Bulwark + Install {appName}

Install our app for quick access and offline support.