当前位置: 首页 > news >正文

vue 控件的四个角设置 父视图position:relative

父视图relative,子视图 absolute

<div class="bg1">

                            <i class="topL"></i>

                            <i class="topR"></i>

                            <i class="bottomL"></i>

                            <i class="bottomR"></i>

                            <div class="tableTitle">

                                <div style="float: left;;">7日内出库排行</div>

                            </div>

                            <div id="main11" style="width: 100% !important;height:calc(100vh * 340 / 1080) ;"

                                class="echart">

                            </div>

                        </div>

.topL {

    width: 5px;

    height: 5px;

    border-top-width: 2px;

    border-top-color: #26c6f0;

    border-top-style: solid;

    border-left-width: 2px;

    border-left-color: #26c6f0;

    border-left-style: solid;

    position: absolute;//根据父视图决定位置

    top: -2px;

    left: -2px;

}

.topR {

    width: 5px;

    height: 5px;

    border-top-width: 2px;

    border-top-color: #26c6f0;

    border-top-style: solid;

    border-right-width: 2px;

    border-right-color: #26c6f0;

    border-right-style: solid;

    position: absolute;

    top: -2px;

    right: -2px;

}

.bottomL {

    width: 5px;

    height: 5px;

    border-bottom-width: 2px;

    border-bottom-color: #26c6f0;

    border-bottom-style: solid;

    border-left-width: 2px;

    border-left-color: #26c6f0;

    border-left-style: solid;

    position: absolute;

    bottom: -2px;

    left: -2px;

}

.bottomR {

    width: 5px;

    height: 5px;

    border-bottom-width: 2px;

    border-bottom-color: #26c6f0;

    border-bottom-style: solid;

    border-right-width: 2px;

    border-right-color: #26c6f0;

    border-right-style: solid;

    position: absolute;

    bottom: -2px;

    right: -2px;

}

.bg1 {

    height: calc(100vh *385 / 1080);

    width: 100%;

    border-radius: 5px;

    border: 1px solid rgba(25, 186, 139, .17);

    background: rgba(255, 255, 255, .04);

    position: relative;//相对于自身的位置而言

}

http://www.lryc.cn/news/125840.html

相关文章:

  • VM中linux虚拟机配置桥接模式(虚拟机与宿主机网络互通)
  • 7.Eclipse中改变编码方式及解决部分乱码问题
  • grafana 的 ws websocket 连接不上的解决方式
  • 多环境_部署项目
  • go web框架 gin-gonic源码解读02————router
  • 【Java后端封装数据】常见后端封装数据的格式,用于返回给前端使用(109)
  • 无脑入门pytorch系列(三)—— nn.Linear
  • SQL Server用sql语句添加列,添加列注释
  • springBoot中service层查询使用多线程CompletableFuture(有返回值)
  • 畜牧虚拟仿真 | 鱼授精过程VR模拟演练系统
  • 第一百一十四回 局部动态列表
  • 多尺度目标检测【动手学深度学习】
  • elasticsearch 基础
  • 【BUG】docker安装nacos,浏览器却无法访问到页面
  • C#引用Web Service 类型方法,添加搜索本地服务器Web Service 接口调用方法
  • yolov8训练进阶:新增配置参数
  • 轻量级自动化测试框架WebZ
  • 如何实现安全上网
  • Redis心跳检测
  • 【数据库】Sql Server可视化工具SSMS条件和SQL窗格以及版本信息
  • Python SFTP 详细使用
  • MyBatis的XML映射文件
  • UML-类图和对象图
  • 升级指定版本Node.js或npm
  • UE4/5 GAS技能系统入门3 - GameplayEffect
  • Linux交叉编译opencv并移植ARM端
  • TypeScript教程(一)简介与安装
  • 做视频_Style
  • vue3使用pinia和pinia-plugin-persist做持久化存储
  • 数据结构入门指南:二叉树