judge inputfield is editing

I want to do a key check that is valid only when that inputfile is editing

use the property(InputField.isOnFcous)

    public void Enter2send()
            {
                if (Input.GetKeyDown(KeyCode.LeftControl)&&chatMessage.c)
                {
                    OnSend();
    
                }
            }