I have a below pop component, the problem in this component is when in the mobile view, when the user clicks on the input field, the modal goes up because the android keypad shows.
since I have the height of the modal to have the mobile keypad also. How can I render the keypad inside the modal, so that the modal sticks as like
App.js
import { useState } from "react";
import Modal from "./Modal";
import "./styles.css";
export default function App() {
const [isModalOpen, setIsModalOpen] = useState(false);
const onToggleModal = () => {
setIsModalOpen((prevState) => !prevState);
};
return (
<div className="App">
<button onClick={onToggleModal}>Click me to open modal</button>
{isModalOpen ? (
<Modal show={isModalOpen} close={onToggleModal}>
<input />
</Modal>
) : null}
</div>
);
}
If you see the sandbox, I think is it because of the CSS of giving border as 0 and position as fixed ?
Any help is appreciated