From 0ce3820acfc7777bba2f728f42afd99bc26bf19c Mon Sep 17 00:00:00 2001 From: YANGDL <114714267@qq.com> Date: 星期六, 13 三月 2021 21:29:44 +0800 Subject: [PATCH] 修改了界面自适应 --- src/components/panel/LegendPanel.vue | 47 ++++++++++++++++++++++------------------------- 1 files changed, 22 insertions(+), 25 deletions(-) diff --git a/src/components/panel/LegendPanel.vue b/src/components/panel/LegendPanel.vue index afd7d70..f7329bc 100644 --- a/src/components/panel/LegendPanel.vue +++ b/src/components/panel/LegendPanel.vue @@ -1,34 +1,27 @@ <template> <div class="legend-panel"> - <transition name="fade"> <div :class="'legend-content map-background'" v-show="legendControl"> <div class="legend-content-box" v-for="(item,index) in legendContents" :key="index"> <p><span>{{ item.title }}</span></p> <div :class="index === 5 ? '':'map-under-line'"></div> - <ul > - <!-- <div >--> + <ul> <li v-for="(ite,inde) in item.items" :key="inde"> <img :src='ite.legendImage' alt=''> <span>{{ ite.legendContent }}</span> </li> - - <!-- </div>--> </ul> - </div> </div> </transition> <el-tooltip :popper-class="'map-tooltip'" effect="dark" content="鍥句緥" placement="left"> - <div :class="this.legendControl?'legend-btn map-btn-active':'legend-btn map-btn-unactive'" @click="legendChange()"> + <div :class="this.legendControl?'legend-btn map-btn-active':'legend-btn map-btn-unactive'" + @click="legendChange()"> <i class="el-icon-more-outline"></i> -<!-- <span>鍥句緥</span>--> </div> </el-tooltip> - </div> </template> - <script> export default { name: 'LegendPanel', @@ -151,7 +144,7 @@ } </script> -<style lang="less" > +<style lang="less"> @import '@assets/css/map/_map-variable'; .legend-panel { position: absolute; @@ -165,6 +158,7 @@ -ms-flex-align: end; //align-items: flex-end; transition: all .5s; + .legend-btn { width: .2rem; height: .2rem; @@ -234,6 +228,7 @@ font-size: 0.07292rem; padding: .10417rem; border-left: .00521rem solid @background-color-split; + p { text-align: center; margin: 0 !important; @@ -244,6 +239,7 @@ -webkit-margin-after: 0.2rem; margin-block-end: 0.2rem; margin-bottom: 0.05208rem !important; + span { color: @color-title; font-size: .08333rem; @@ -259,22 +255,23 @@ padding-inline: 0; font-size: .08333rem; - li { - list-style: none; - display: flex; - -webkit-box-align: center; - align-items: center; - margin: 0.05208rem 0; - img { - width: .08333rem; - height: .08333rem; - margin-right: .01042rem; - } + li { + list-style: none; + display: flex; + -webkit-box-align: center; + align-items: center; + margin: 0.05208rem 0; - span { - color: @color; - } + img { + width: .08333rem; + height: .08333rem; + margin-right: .01042rem; } + + span { + color: @color; + } + } } } -- Gitblit v1.8.0