Add decoration in settings when setting, variable, input, or runner is selected but not set

Signed-off-by: Sanjula Ganepola <sanjulagane@gmail.com>
This commit is contained in:
Sanjula Ganepola
2024-11-25 23:06:45 -05:00
parent 0e125ad2fd
commit 14fdc55230
8 changed files with 51 additions and 20 deletions

View File

@@ -1,4 +1,4 @@
import { ThemeIcon, TreeItem, TreeItemCollapsibleState, WorkspaceFolder } from "vscode";
import { ThemeIcon, TreeItem, TreeItemCollapsibleState, Uri, WorkspaceFolder } from "vscode";
import { act } from "../../extension";
import { Setting, SettingFile } from "../../settingsManager";
import { StorageKey } from "../../storageManager";
@@ -17,6 +17,8 @@ export default class InputsTreeItem extends TreeItem implements GithubLocalActio
(selectedInputFiles.length > 0 ? ` + ${selectedInputFiles[0].name}` : ``);
this.contextValue = InputsTreeItem.contextValue;
this.iconPath = new ThemeIcon('record-keys');
const hasAllValues = inputs.filter(input => input.selected && input.value === '').length === 0;
this.resourceUri = Uri.parse(`${InputsTreeItem.contextValue}:Inputs?hasAllValues=${hasAllValues}`, true);
}
async getChildren(): Promise<GithubLocalActionsTreeItem[]> {