From 02857bd43c618e616b84b8ad7553ff4e1f37015d Mon Sep 17 00:00:00 2001 From: Matthew Breedlove Date: Wed, 20 Aug 2025 03:20:21 -0400 Subject: [PATCH] Fix display of powerline font installation message --- src/tui/App.tsx | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/src/tui/App.tsx b/src/tui/App.tsx index 76787a6..9197692 100644 --- a/src/tui/App.tsx +++ b/src/tui/App.tsx @@ -441,14 +441,18 @@ export const App: React.FC = () => { }} onInstallFonts={() => { setInstallingFonts(true); - void installPowerlineFonts().then((result) => { - setInstallingFonts(false); - setFontInstallMessage(result.message); - // Refresh font status - void checkPowerlineFontsAsync().then((asyncStatus) => { - setPowerlineFontStatus(asyncStatus); + // Add a small delay to allow React to render the "Installing..." message + // before the blocking execSync calls in installPowerlineFonts + setTimeout(() => { + void installPowerlineFonts().then((result) => { + setInstallingFonts(false); + setFontInstallMessage(result.message); + // Refresh font status + void checkPowerlineFontsAsync().then((asyncStatus) => { + setPowerlineFontStatus(asyncStatus); + }); }); - }); + }, 50); }} installingFonts={installingFonts} fontInstallMessage={fontInstallMessage}