Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
corporate-culture-qd
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
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
王立鹏
corporate-culture-qd
Commits
7a5c0576
Commit
7a5c0576
authored
Mar 30, 2026
by
王立鹏
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch '线上优化/问吧详情页优化' into 'master'
【线上优化】 fix: 修复问吧详情【展开全部/收起】的bug See merge request
!16
parents
6f582a53
94341282
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
5 deletions
+2
-5
index.vue
src/views/questionDetail/index.vue
+2
-5
No files found.
src/views/questionDetail/index.vue
View file @
7a5c0576
...
...
@@ -451,20 +451,17 @@ const questionContentRef = useTemplateRef<HTMLElement>('questionContentRef')
const
isExpand
=
ref
(
false
)
// 检测当前是否超过三行 要用到具体的dom
const
isOverThreeLine
=
ref
(
false
)
const
checkIsOverThreeLine
=
()
=>
{
const
isOverThreeLine
=
computed
(()
=>
{
if
(
!
questionContentRef
.
value
||
!
questionDetail
.
value
.
content
)
return
false
const
lineHeight
=
parseFloat
(
getComputedStyle
(
questionContentRef
.
value
).
lineHeight
)
const
height
=
questionContentRef
.
value
!
.
scrollHeight
const
maxHeight
=
lineHeight
*
3
return
height
>
maxHeight
}
}
)
const
getQuestionDetail
=
async
()
=>
{
const
{
data
}
=
await
getArticleDetail
(
questionId
)
questionDetail
.
value
=
data
await
nextTick
()
isOverThreeLine
.
value
=
checkIsOverThreeLine
()
}
const
{
list
,
total
,
searchParams
,
goToPage
,
refresh
}
=
usePageSearch
(
getCommentList
,
{
...
...
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