Here is what I would like to input box to look like all the time regardless of screen size.
How can I make the search button stay inside the input. Here is my code for the react component
.input {
width: 400px;
padding: 14px 30px;
border-radius: 50px;
outline: none;
font-size: 18px;
}
.searchBox {
text-align: center;
width: 100%;
position: relative;
}
::-webkit-input-placeholder {
/* Chrome/Opera/Safari */
font-family: Roboto;
text-transform: uppercase;
}
.close-btn {
top: 2px;
left: 57.5%;
position: absolute;
cursor: pointer;
color: #ffffff;
background: #000000;
border: 0px;
width: 120px;
height: 55px;
border-radius: 50px;
outline: none;
text-transform: uppercase;
font-weight: bold;
}
import React from "react";
import "./style.css";
function Search() {
return (
<div class="searchBox mt-5">
<input type="text" class="input" placeholder="Search Error Code" />
<input type="button" value="search" class="close-btn" />
</div>
);
}
export default Search;