JSFiddle - React, Tailwind, and code Playground

HTML

<div ng-controller="Test">
        <input type="text" class="message-input" id="testId" placeholder="Enter message" ng-model="textMessage" ng-disabled="isDisabled" autofocus />
        <br><br>
        
        <button type="submit" value="Submit" ng-click="enteredMessage(textMessage)">Submit</button>
     </div>

JavaScript

var app = angular.module('app',[]);

app.controller('Test',function($scope, $window){
	$scope.enteredMessage = function(msg){
   	alert("Entered Message is: " + msg);
    var inputBox = $window.document.getElementById('testId');
    inputBox.focus();
    console.log("your input should now be in focus");
  }
});