feat(picker): add ability to use picker inline (#26336)

This commit is contained in:
Liam DeBeasi
2022-11-22 15:33:47 -05:00
committed by GitHub
parent f23fb342b2
commit c0a8501657
17 changed files with 480 additions and 35 deletions

View File

@ -171,14 +171,16 @@ export class PickerColumnCmp implements ComponentInterface {
}
button.style.transform = transform;
// Update selected item
if (selected !== opt.selected) {
opt.selected = selected;
if (selected) {
button.classList.add(PICKER_OPT_SELECTED);
} else {
button.classList.remove(PICKER_OPT_SELECTED);
}
/**
* Ensure that the select column
* item has the selected class
*/
opt.selected = selected;
if (selected) {
button.classList.add(PICKER_OPT_SELECTED);
} else {
button.classList.remove(PICKER_OPT_SELECTED);
}
}
this.col.prevSelected = selectedIndex;