Skip to content

Commit 8696518

Browse files
fix(webview): normalize nullish chatFontSize in context value (#157)
1 parent 3d4e297 commit 8696518

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

webview-ui/src/context/ExtensionStateContext.tsx

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -488,6 +488,9 @@ export const ExtensionStateContextProvider: React.FC<{ children: React.ReactNode
488488

489489
const contextValue: ExtensionStateContextType = {
490490
...state,
491+
// `chatFontSize` is persisted as nullish (null on reset); normalize null to
492+
// undefined so it matches the context type and means "use VS Code default".
493+
chatFontSize: state.chatFontSize ?? undefined,
491494
reasoningBlockCollapsed: state.reasoningBlockCollapsed ?? true,
492495
didHydrateState,
493496
showWelcome,

0 commit comments

Comments
 (0)