fix events and value snap issue