(choices: Choices, values: string[])
| 16 | * Restore selected values on a Choices instance. |
| 17 | */ |
| 18 | export function setChoicesValues(choices: Choices, values: string[]): void { |
| 19 | // Clear any existing active items so that the final selection matches `values` |
| 20 | choices.removeActiveItems(); |
| 21 | // Set all provided values as the current selection |
| 22 | choices.setChoiceByValue(values); |
| 23 | } |
| 24 | |
| 25 | /** |
| 26 | * Create a new Choices instance with sensible defaults |
no outgoing calls
no test coverage detected