原生js实现toast弹出提示效果代码

代码语言:html

所属分类:弹出层

代码描述:原生js实现toast弹出提示效果代码

代码标签: toast 弹出 提示 效果

下面为部分代码预览,完整代码请点击下载或在bfwstudio webide中打开

<!DOCTYPE html>
<html lang="en">

<head>

    <meta charset="UTF-8">



    <style>
        body {
            font-size: 18px;
            line-height: 1.5;
            background: #eee;
            color: #333;
            height: 100vh;
            width: 100vw;
            display: -webkit-box;
            display: flex;
            -webkit-box-orient: vertical;
            -webkit-box-direction: normal;
            flex-flow: column;
            -webkit-box-align: center;
            align-items: center;
            -webkit-box-pack: center;
            justify-content: center;
        }

        h1 {
            box-sizing: border-box;
            width: 100%;
            max-width: 768px;
            margin: 0 auto;
            text-align: center;
            text-transform: uppercase;
            text-decoration: underline;
        }

        .toast {
            cursor: pointer;
            box-sizing: border-box;
            display: none;
            width: 100%;
            max-width: 640px;
            font-size: 0.825em;
            border-top-right-radius: 5px;
            border-top.........完整代码请登录后点击上方下载按钮下载查看

网友评论0