We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent d6141dc commit 2285f32Copy full SHA for 2285f32
webview-ui/src/context/ExtensionStateContext.tsx
@@ -8,6 +8,7 @@ import {
8
glamaDefaultModelInfo,
9
openRouterDefaultModelId,
10
openRouterDefaultModelInfo,
11
+ PEARAI_URL,
12
} from "../../../src/shared/api"
13
import { vscode } from "../utils/vscode"
14
import { convertTextMateToHljs } from "../utils/textMateToHljs"
@@ -162,6 +163,15 @@ export const ExtensionStateContextProvider: React.FC<{ children: React.ReactNode
162
163
}))
164
const config = newState.apiConfiguration
165
const hasKey = checkExistKey(config)
166
+ if (!hasKey) {
167
+ vscode.postMessage({
168
+ type: "apiConfiguration",
169
+ apiConfiguration: {
170
+ apiProvider: "pearai",
171
+ pearaiBaseUrl: PEARAI_URL,
172
+ },
173
+ })
174
+ }
175
setShowWelcome(!hasKey)
176
setDidHydrateState(true)
177
break
0 commit comments