### Prerequisites - [X] I have read the [Contributing Guidelines](https://github.com/ionic-team/ionic-framework/blob/main/.github/CONTRIBUTING.md#creating-an-issue). - [X] I agree to follow the [Code of Conduct](https://ionicframework.com/code-of-conduct). - [X] I have searched for [existing issues](https://github.com/ionic-team/ionic-framework/issues) that already report this problem, without success. ### Ionic Framework Version - [ ] v4.x - [X] v5.x - [x] v6.x ### Current Behavior When overlay is set to be closed by Escape key, overlay element is always focused in present() method, even if its descendant is already focused. ### Expected Behavior When overlay's descendant is already focused do not call focus on overlay's element. ### Steps to Reproduce 1. Create a component, that will be opened within modal 2. Create render() and add ion-input 3. Add componentDidLoad or listener for ionViewDidEnter and focus ion-input Input will be focused for a moment, but will be blured just after that as the focus is shifted to overlay's element. ### Code Reproduction URL _No response_ ### Ionic Info _No response_ ### Additional Information _No response_