How do I stop Infinte jumping?

I’m making an player-controller script & it allows you to jump infinitly. Does anyone know how to fix this? This is my code:

float leftRight;
float jump;
public float speed;
public float jumpSpeed;

// Start is called before the first frame update
void Start()
{
    
}

// Update is called once per frame
void Update()
{

    leftRight = Input.GetAxis("Horizontal");
    jump = Input.GetAxis("Jump");

    transform.Translate(Vector3.right * Time.deltaTime * speed * leftRight);
    transform.Translate(Vector3.up * Time.deltaTime * jumpSpeed * jump);

}

}

oh some of the code didn’t show the box. well the things at the top were variables.

you have to do a boolean check.
check is your character on the ground.

Create an imaginary circle underneath the player and check if the circle is colliding with anything