fix smooth transition