效果:
代码:
弹出框
.icon {
width: 1em;
height: 1em;
vertical-align: -1.17em;
margin-left: 165px;
fill: currentColor;
overflow:服务器托管网 hidden;
}
#main {
width: 100%;
height: 100%;
background-color: rgba(82, 82, 87, 0.5);
display: flex;
justify-content: center;
align-items: center;
position: absolute;
left: 0;
top: 0;
display: none;
}
#box {
width: 474px;
height: 57px;
background: #F0F9EB;
border-radius: 6px;
position: absolute;
/* z-index: 999; */
}
#stopIt {
text-decoration: none;
color: #17BE59;
float: right;
padding-top: 5px;
margin-right: 10px;
}
p {
font-size: 22px;
font-family: Source Han Sans CN;
font-weight: 400;
color: #17BE59;
margin: -21px 190px;
}
#box1 {
width: 496px;
height: 50px;
border: 2px solid black;
}
#box2 {
width: 0px;
height: 50px;
background-color: pink;
}
//对号
//差号
提交成功
let eject = document.getElementById("eject");
let main = document.getElementById("main");
let stopIt = document.getElementById("stopIt");
//点击出现弹框
eject.onclick = function () {
main.style.displ服务器托管网ay = "flex";
}
//点击弹框消失
stopIt.onclick = function () {
main.style.display = "none";
}
字体JS文件:cankao
window._iconfont_svg_string_='',function(n){var t=(t=document.getElementsByTagName("script"))[t.length-1],e=t.getAttribute("data-injectcss"),t=t.getAttribute("data-disable-injectsvg");if(!t){var i,o,c,d,s,a=function(t,e){e.parentNode.insertBefore(t,e)};if(e&&!n.__iconfont__svg__cssinject__){n.__iconfont__svg__cssinject__=!0;try{document.write(".svgfont {display: inline-block;width: 1em;height: 1em;fill: currentColor;vertical-align: -0.1em;font-size:16px;}")}catch(t){console&&console.log(t)}}i=function(){var t,e=document.createElement("div");e.innerHTML=n._iconfont_svg_string_,(e=e.getElementsByTagName("svg")[0])&&(e.setAttribute("aria-hidden","true"),e.style.position="absolute",e.style.width=0,e.style.height=0,e.style.overflow="hidden",e=e,(t=document.body).firstChild?a(e,t.firstChild):t.appendChild(e))},document.addEventListener?~["complete","loaded","interactive"].indexOf(document.readyState)?setTimeout(i,0):(o=function(){document.removeEventListener("DOMContentLoaded",o,!1),i()},document.addEventListener("DOMContentLoaded",o,!1)):document.attachEvent&&(c=i,d=n.document,s=!1,r(),d.onreadystatechange=function(){"complete"==d.readyState&&(d.onreadystatechange=null,l())})}function l(){s||(s=!0,c())}function r(){try{d.documentElement.doScroll("left")}catch(t){return void setTimeout(r,50)}l()}}(window);
参考文档:Js简朴原生实现弹框_原生js弹框_想被带飞的鱼的博客-CSDN博客
服务器托管,北京服务器托管,服务器租用 http://www.fwqtg.net
相关推荐: 美方施压,ASML 取消部分设备向中国大陆出货 | 百能云芯
荷兰半导体制造设备供应商ASML宣布,在新的荷兰禁令生效之前,已根据美国政府的要求,暂停向中国大陆部分客户提供高级芯片制造设备。这一决定涉及到ASML旗下的NXT:2050i和NXT:2100i设备的部分出货许可。 据悉,ASML已经获得了向中国大陆出口三台顶…