Forum Discussion

ThilagamSakkara's avatar
ThilagamSakkara
Community Member
2 years ago

change NumericEntry without losing focus

Trying to perform some actions when NumericEntry changes its value when having a focus in it. Found some discussion about changing Text entry without losing focus.  The solution provided in that discussion is: 

document.querySelector('.acc-textinput').addEventListener('keyup', () => {
document.querySelector('.acc-textinput').blur();
document.querySelector('.acc-textinput').focus();
});


I have tried replacing  (.acc-textinput) with  (.acc-numericinput) and document.querySelector('#NumericEntry'). Both not working. Any help would be much appreciated!

  • there is no difference between the selectors of text input and numeric input

    blue = text input
    green = numeric input

    both can be selected with ".acc-textinput"

    perhaps your problem was the search result of "querySelector"

    querySelector: if there are more than one input fields on the slide, the first element for this selector is found