菜单图标样式

pull/1/head
LiuJiaNan 2024-02-05 17:18:17 +08:00
parent b74bc37a4a
commit a88c748046
1 changed files with 22 additions and 17 deletions

View File

@ -156,13 +156,13 @@
title="设置图标"
width="40%"
@close="iconDialog.visible = false">
<div>
<div class="link">
<a href="https://iconpark.oceanengine.com/official" target="_blank">
点击此处
</a>
查看所有图标
</div>
<div class="mt">
<div>
<el-form label-width="80px">
<el-row>
<el-col :span="12">
@ -179,8 +179,8 @@
</el-form>
</div>
<div class="icon_container">
<div v-for="(item, index) in iconDialog.svgList" :key="index">
<el-tooltip :content="item.title">
<template v-for="(item, index) in iconDialog.svgList">
<el-tooltip :content="item.title" :key="index">
<div
:class="{ active: iconDialog.iconIndex === index }"
class="item"
@ -190,14 +190,13 @@
:is="'icon-' + item.name"
:stroke-width="3"
theme="outline"
fill="#fff"
fill="#a5b2c2"
size="38"
/>
</div>
</el-tooltip>
</template>
</div>
</div>
<div class="mt flex-end">
<pagination
:total="iconDialog.pagination.total"
:page.sync="iconDialog.pagination.currentPage"
@ -205,7 +204,6 @@
small
layout="total, sizes, prev, pager, next, jumper"
@pagination="fnSearchIcon" />
</div>
<template #footer>
<el-button type="primary" @click="confirmIcon"></el-button>
<el-button @click="iconDialog.visible = false">关闭</el-button>
@ -566,13 +564,20 @@ export default {
}
</script>
<style lang="scss" scoped>
.link{
margin-bottom: 10px;
a{
color: #409EFF;
}
}
.icon_container {
display: flex;
flex-wrap: wrap;
margin-bottom: 10px;
.item {
flex-basis: calc(5% - 10px);
border: 1px solid #fff;
flex-basis: calc(10% - 13px);
border: 1px solid #ccc;
display: flex;
justify-content: center;
align-items: center;