Add onChange event for input