Make Controller shortcuts settings controller-friendly

This commit is contained in:
redphx
2024-07-16 17:59:21 +07:00
parent b66cb448ec
commit 2a0af5d0ab
4 changed files with 49 additions and 27 deletions

View File

@@ -54,7 +54,8 @@ export class BxSelectElement {
}
const getOptionAtIndex = (index: number): HTMLOptionElement | undefined => {
return $select.querySelector(`option:nth-of-type(${visibleIndex + 1})`) as HTMLOptionElement;
const options = Array.from($select.querySelectorAll('option'));
return options[index];
}
const render = () => {