Evolution of X-ray and optical properties of galaxy clusters