added callback for change and input event