Function
getItemIndex
(
items: ICheckboxQuickPickItem[],
itemLabel: string,
)
Source from the content-addressed store, hash-verified
| 81 | } |
| 82 | |
| 83 | function getItemIndex( |
| 84 | items: ICheckboxQuickPickItem[], |
| 85 | itemLabel: string, |
| 86 | ): number { |
| 87 | const trimmedLabel = itemLabel.substring(itemLabel.indexOf("]") + 2); |
| 88 | return items.findIndex((item) => item.label === trimmedLabel); |
| 89 | } |
| 90 | |
| 91 | function toggleSelection(item: ICheckboxQuickPickItem): void { |
| 92 | item.isSelected = !item.isSelected; |
Tested by
no test coverage detected