JSFiddle - React, Tailwind, and code Playground
by Qwerty_Wasd
HTML
<div class="windowMessage">
<div class="close">x</div>
<div class="message">
Сайт ещё находится в разработке!
</div>
<script>
let bclose = document.getElementsByClassName('close')[0];
let windMes = document.getElementsByClassName('windowMessage')[0];
function Close(){
windMes.style.display="none";
};
bclose.addEventListener("click",Close);
</script>
</div>
CSS
.windowMessage{
display: inline-block;
position:fixed;
border-width:1px;
border-color:#000;
border-style:solid;
background:#555555;
height:auto;
}
.close{
cursor:pointer;
position: absolute;
top: 10%;
right: 1.5%;
transform: translate(-1.5%, -10%);
width:20px;
height:20px;
font-size:16px;
color:#000000;
background:#ffffff;
text-align:center;
}
.close:hover{
background:#ff0000;
color:#ffffff;
}
.message{
margin:5px;
background:#ffffff;
padding: 20px;
line-height: 20px;
}