Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
apaas-ui
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
gzga-jzapi
apaas-ui
Commits
3cea5f69
Commit
3cea5f69
authored
Oct 23, 2020
by
张俊
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dev' of
https://cloud.wodcloud.com/git/apaas/apaas-v3-ui
into dev
parents
4c6284ef
95ac7390
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
2 deletions
+17
-2
src/pages/technical-support/doc/detail.vue
src/pages/technical-support/doc/detail.vue
+17
-2
No files found.
src/pages/technical-support/doc/detail.vue
View file @
3cea5f69
...
...
@@ -23,6 +23,7 @@
<div
class=
"part_content doc_content apaas_scroll"
v-html=
"content"
ref=
"docContent"
></div>
</div>
<div
class=
"part nav_part"
>
...
...
@@ -38,9 +39,8 @@
item.id === curNav ? ' current' : '',
]"
:key=
"index"
@
click=
"clickNav(item)"
>
<a
:href=
"'#' + item.id"
v-text=
"item.title
"
></a>
<a
v-text=
"item.title"
@
click=
"clickNav(item)
"
></a>
</li>
</ul>
</div>
...
...
@@ -151,8 +151,22 @@ export default {
successCallback
(
richTextContent
);
},
clickNav
(
item
)
{
let
target
=
document
.
querySelector
(
`#
${
item
.
id
}
`
);
this
.
setScroll
(
target
,
this
.
$refs
.
docContent
);
this
.
curNav
=
item
.
id
;
},
setScroll
(
el
,
parentEl
)
{
let
actualTop
=
el
.
offsetTop
;
let
current
=
el
.
offsetParent
;
while
(
current
!==
null
)
{
actualTop
+=
current
.
offsetTop
;
current
=
current
.
offsetParent
;
}
parentEl
.
scrollTop
=
actualTop
-
parentEl
.
offsetTop
;
},
},
};
</
script
>
...
...
@@ -248,6 +262,7 @@ export default {
line-height
:
30px
;
color
:
#58617a
;
text-decoration
:
none
;
cursor
:
pointer
;
}
.nav_content
>
li
.level_1
>
a
{
color
:
#242c43
;
...
...
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