how to use input field unity

Code Example - how to use input field unity

                
                        public string theName;
    public GameObject inputField;
    public GameObject textDisplay;
    
    public void StoreName()
    {
        theName = inputField.GetComponent<Text>().text;
        textDisplay.GetComponent<Text>().text = theName;
    }
                    
                
 

unity input system

                        
                                private void OnEnable()
{
	playerInput = GetComponent<PlayerInput>();
    playerInput.actions["Action"].performed += HandleAction
}

private void Update() {
	value = playerInput.actions["Value"].ReadValue<Vector2>();
}

private void HandleAction(InputAction.CallbackContext context)
{
	HandleJump();
}
                            
                        
 

unity input tastiera

                        
                                unity input tastiera