From 56cac05818955aeae7e86d7b4abaed98f27fdb48 Mon Sep 17 00:00:00 2001 From: xing Date: Wed, 17 Jun 2020 10:38:05 +0800 Subject: [PATCH] =?UTF-8?q?=E8=8F=9C=E5=8D=95=E5=9B=BE=E6=A0=87?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/assets/fonts/demo_fontclass.html | 23 +++++++++++------------ src/components/Home.vue | 18 ++++++++++++++---- 2 files changed, 25 insertions(+), 16 deletions(-) diff --git a/src/assets/fonts/demo_fontclass.html b/src/assets/fonts/demo_fontclass.html index a4cab35..bbbbf0b 100755 --- a/src/assets/fonts/demo_fontclass.html +++ b/src/assets/fonts/demo_fontclass.html @@ -11,67 +11,67 @@

IconFont 图标

font-class引用

@@ -88,7 +88,6 @@

使用步骤如下:

第一步:引入项目下面生成的fontclass代码:

-
<link rel="stylesheet" type="text/css" href="./iconfont.css">

第二步:挑选相应图标并获取类名,应用于页面:

<i class="iconfont icon-xxx"></i>
diff --git a/src/components/Home.vue b/src/components/Home.vue index 312805a..cac44b2 100644 --- a/src/components/Home.vue +++ b/src/components/Home.vue @@ -12,19 +12,19 @@ + active-text-color="#3497FF"> - + {{subitem.authName}} @@ -42,7 +42,14 @@ export default { name: 'Home', data () { return { - menuList: [] + menuList: [], + iconsObjs: { + 125: 'iconfont icon-user', + 103: 'iconfont icon-tijikongjian', + 101: 'iconfont icon-shangpin', + 102: 'iconfont icon-danju', + 145: 'iconfont icon-baobiao' + } } }, methods: { @@ -94,4 +101,7 @@ export default { .el-main{ background-color: #E9EDF1; } + .iconfont { + margin-right: 10px; + }