Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
VueElementTemplate
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
HireTest
VueElementTemplate
Commits
108b380d
Commit
108b380d
authored
7 years ago
by
Pan
Committed by
花裤衩
7 years ago
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
menu 支持 icon 嵌套
parent
69fc52d4
Changes
4
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
7 additions
and
11 deletions
+7
-11
iconfont.js
src/assets/iconfont/iconfont.js
+1
-1
sidebar.scss
src/styles/sidebar.scss
+4
-5
Layout.vue
src/views/layout/Layout.vue
+0
-3
SidebarItem.vue
src/views/layout/SidebarItem.vue
+2
-2
No files found.
src/assets/iconfont/iconfont.js
View file @
108b380d
This diff is collapsed.
Click to expand it.
src/styles/sidebar.scss
View file @
108b380d
...
...
@@ -7,17 +7,13 @@
margin-right
:
16px
;
}
.hideSidebar
.svg-icon
{
margin-right
:
0
;
}
.hideSidebar
.el-submenu
>
.el-submenu__title
,
.hideSidebar
.submenu-title-noDropdown
{
padding-left
:
10px
!
important
;
}
.hideSidebar
.submenu-title-noDropdown
span
,
.hideSidebar
.el-submenu
>
.el-submenu__title
span
{
.hideSidebar
.el-submenu
>
.el-submenu__title
>
span
{
height
:
0
;
width
:
0
;
overflow
:
hidden
;
...
...
@@ -32,6 +28,7 @@
height
:
auto
;
width
:
auto
;
visibility
:
visible
;
display
:
inline
;
}
.el-submenu__icon-arrow
{
display
:
block
!
important
;
...
...
@@ -65,6 +62,8 @@
visibility
:
visible
;
position
:
absolute
;
right
:
-145px
;
text-align
:
left
;
text-indent
:
20px
;
top
:
0px
;
background-color
:
#1f2d3d
;
opacity
:
1
;
...
...
This diff is collapsed.
Click to expand it.
src/views/layout/Layout.vue
View file @
108b380d
...
...
@@ -51,9 +51,6 @@
left
:
0
;
z-index
:
1001
;
background
:
red
;
// overflow-y: auto;
&
:
:-
webkit-scrollbar
{
display
:none
}
}
.main-container
{
min-height
:
100%
;
...
...
This diff is collapsed.
Click to expand it.
src/views/layout/SidebarItem.vue
View file @
108b380d
...
...
@@ -10,7 +10,7 @@
<el-submenu
:index=
"item.name"
v-if=
"!item.noDropdown&&!item.hidden"
>
<template
slot=
"title"
>
<icon-svg
v-if=
'item.icon'
:icon-class=
"item.icon"
></icon-svg><span
slot=
"title"
>
{{
item
.
name
}}
</span>
<icon-svg
v-if=
'item.icon'
:icon-class=
"item.icon"
></icon-svg><span>
{{
item
.
name
}}
</span>
</
template
>
<
template
v-for=
"child in item.children"
v-if=
'!child.hidden'
>
...
...
@@ -18,7 +18,7 @@
<router-link
v-else
:to=
"item.path+'/'+child.path"
>
<el-menu-item
:index=
"item.path+'/'+child.path"
>
<span
slot=
"title"
>
{{
child
.
name
}}
</span>
<icon-svg
v-if=
'child.icon'
:icon-class=
"child.icon"
></icon-svg><span
>
{{
child
.
name
}}
</span>
</el-menu-item>
</router-link>
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment