Merge pull request #2795 from github/koesie10/switch-mode-loading

Set loading state when switching between modes
This commit is contained in:
Koen Vlaswinkel
2023-09-08 16:54:27 +02:00
committed by GitHub

View File

@@ -277,7 +277,12 @@ export class ModelEditorView extends AbstractWebview<
break;
case "switchMode":
this.mode = msg.mode;
this.methods = [];
await Promise.all([
this.postMessage({
t: "setMethods",
methods: this.methods,
}),
this.setViewState(),
withProgress((progress) => this.loadExternalApiUsages(progress), {
cancellable: false,