feat: language config for devstar home

This commit is contained in:
Levi Yan
2025-04-22 20:58:09 +08:00
parent 9a05859787
commit b3998f9903
2 changed files with 6 additions and 0 deletions

View File

@@ -45,6 +45,11 @@ export default class DSHome {
// ================= need return ====================
switch (message.command) {
// ----------------- frequent -----------------------
case 'getHomeConfig':
const config = {
language: vscode.env.language
}
panel.webview.postMessage({command: 'getHomeConfig', data: {homeConfig: config}})
case 'getUserToken':
const userToken = this.user.getUserTokenFromLocal()
if (userToken === undefined) {

View File

@@ -16,6 +16,7 @@ export class DevStarExtension {
this.remoteContainer = new RemoteContainer(this.user);
this.dsHome = new DSHome(context, this.user);
// support for open with vscode in web
const handler = vscode.window.registerUriHandler({
handleUri: async (uri: vscode.Uri) => {
const devstarAPIHandler = new DevstarAPIHandler()