简易聊天室--socket.io实现style样式

 [v-cloak] {
            display: none;
        }

        .container {
            box-sizing: border-box;
            margin: 15px auto;
            padding: 15px;
            font-size: 18px;
            border: 1px dashed #000;
        }

        .title {
            margin: 0;
            padding-bottom: 15px;
            height: 64px;
            line-height: 64px;
            font-weight: 100;
            text-align: center;
            letter-spacing: 12px;
            border-bottom: 1px solid #000;
            text-transform: uppercase;
        }

        .message-wrap {
            height: 60vh;
            overflow-y: auto;
        }

        .message {
            display: flex;
            padding: 15px;
            line-height: 1.6;
        }

        .message .label {
            flex-shrink: 0;
            width: 50px;
            color: #333;
        }

        .message .value {
            flex: 1;
            color: #bbb;
        }

        .message~.message {
            border-top: 1px dashed #bbb;
        }

        /* 有message和self类下的 label 顺序往右 */
        .message.self .label {
            /*  默认为0的 */
            order: 1;
            text-align: right;
        }

        .footer {
            display: flex;
            justify-content: center;
            align-items: center;
            height: 64px;
            margin-left: -15px;
            margin-right: -15px;
            margin-bottom: -15px;
            background-color: greenyellow;
        }

        .footer .input {
            box-sizing: border-box;
            padding: 0 15px;
            width: 360px;
            height: 36px;
            outline: none;
            border: 1px solid #000;
            border-radius: 5px;
        }

        .footer .button {
            margin-left: 15px;
            padding: 0 15px;
            height: 36px;
            font-weight: bold;
        }

        .row {
            display: flex;
            flex-wrap: wrap;
            margin-right: -15px;
            margin-left: -15px;
        }
©著作权归作者所有,转载或内容合作请联系作者
【社区内容提示】社区部分内容疑似由AI辅助生成,浏览时请结合常识与多方信息审慎甄别。
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

相关阅读更多精彩内容

友情链接更多精彩内容