From 63d47b0fae7078f41d6e9cd0966d6f5cd0195b44 Mon Sep 17 00:00:00 2001 From: toesbieya <1647775459@qq.com> Date: Thu, 27 Aug 2020 19:50:52 +0800 Subject: [PATCH] =?UTF-8?q?=E5=BD=93=E5=90=AF=E7=94=A8=E4=BA=86'=E4=BE=A7?= =?UTF-8?q?=E8=BE=B9=E6=A0=8F=E8=87=AA=E5=8A=A8=E9=9A=90=E8=97=8F'?= =?UTF-8?q?=E6=97=B6=EF=BC=8C=E4=B8=8D=E6=B8=B2=E6=9F=93=E4=BE=A7=E8=BE=B9?= =?UTF-8?q?=E6=A0=8F=E6=8A=98=E5=8F=A0=E6=8C=89=E9=92=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../layout/component/Navbar/component/Hamburger.vue | 5 +++-- vue/src/layout/component/Navbar/index.vue | 10 ++++++++-- vue/src/layout/component/Sidebar/index.vue | 4 ++-- 3 files changed, 13 insertions(+), 6 deletions(-) diff --git a/vue/src/layout/component/Navbar/component/Hamburger.vue b/vue/src/layout/component/Navbar/component/Hamburger.vue index fc879ba..e43d35f 100644 --- a/vue/src/layout/component/Navbar/component/Hamburger.vue +++ b/vue/src/layout/component/Navbar/component/Hamburger.vue @@ -4,10 +4,11 @@ export default { functional: true, - props: {active: Boolean}, + props: {render: Boolean, active: Boolean}, render(h, context) { - const {active} = context.props + const {render, active} = context.props + if (!render) return const className = `navbar-icon el-icon-s-unfold hamburger ${active ? 'is-active' : ''}` return (
diff --git a/vue/src/layout/component/Navbar/index.vue b/vue/src/layout/component/Navbar/index.vue index 7382360..af38833 100644 --- a/vue/src/layout/component/Navbar/index.vue +++ b/vue/src/layout/component/Navbar/index.vue @@ -1,7 +1,7 @@