Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
水玉婷
ai-wechat
Commits
87299d8a
Commit
87299d8a
authored
Mar 23, 2026
by
水玉婷
Browse files
feat:细节优化
parent
2dcda17f
Changes
3
Hide whitespace changes
Inline
Side-by-side
src/views/Login.vue
View file @
87299d8a
...
@@ -48,11 +48,11 @@ export default {
...
@@ -48,11 +48,11 @@ export default {
onMounted
(()
=>
{
onMounted
(()
=>
{
// 检查是否已登录
// 检查是否已登录
//
const status = wechat.checkLoginStatus()
const
status
=
wechat
.
checkLoginStatus
()
//
if (status.isLoggedIn) {
if
(
status
.
isLoggedIn
)
{
//
router.replace('/')
router
.
replace
(
'
/
'
)
//
return
return
//
}
}
// 执行静默登录
// 执行静默登录
handleLogin
()
handleLogin
()
...
...
src/views/components/style.less
View file @
87299d8a
...
@@ -44,8 +44,6 @@ body {
...
@@ -44,8 +44,6 @@ body {
padding: 0;
padding: 0;
margin: 0;
margin: 0;
box-sizing: border-box;
box-sizing: border-box;
// 跨浏览器滚动条隐藏方案
// Webkit浏览器滚动条样式(Chrome, Safari, Edge)
// Webkit浏览器滚动条样式(Chrome, Safari, Edge)
&::-webkit-scrollbar {
&::-webkit-scrollbar {
...
...
src/views/components/utils/contentTemplateService.ts
View file @
87299d8a
...
@@ -293,33 +293,6 @@ export class ContentTemplateService {
...
@@ -293,33 +293,6 @@ export class ContentTemplateService {
case
3
:
// 图表数据
case
3
:
// 图表数据
if
(
updatedResponse
)
{
if
(
updatedResponse
)
{
switch
(
contentType
)
{
switch
(
contentType
)
{
case
0
:
// 普通文本内容
// 检查最后一个块是否是普通文本块,如果是则合并,否则创建新块
const
isLastText
=
isLastBlockText
(
updatedResponse
.
contentBlocks
);
if
(
isLastText
)
{
// 合并到现有的普通文本块
const
lastTextIndex
=
getLastTextBlockIndex
(
updatedResponse
.
contentBlocks
);
if
(
lastTextIndex
!==
-
1
)
{
updatedResponse
.
contentBlocks
[
lastTextIndex
].
content
=
mergeTextContent
(
updatedResponse
.
contentBlocks
[
lastTextIndex
].
content
,
messageContent
);
}
}
else
{
// 创建新的内容块
updatedBlockIndex
=
updatedResponse
.
contentBlocks
.
length
;
updatedResponse
.
contentBlocks
.
push
({
content
:
this
.
templates
.
text
(
messageContent
),
hasThinkBox
:
false
,
thinkContent
:
''
,
thinkBoxExpanded
:
false
,
});
}
break
;
case
2
:
case
2
:
// 图表数据处理
// 图表数据处理
updatedResponse
.
contentBlocks
.
push
({
updatedResponse
.
contentBlocks
.
push
({
...
@@ -416,6 +389,14 @@ export class ContentTemplateService {
...
@@ -416,6 +389,14 @@ export class ContentTemplateService {
updatedResponse
.
showRecommendations
=
true
;
updatedResponse
.
showRecommendations
=
true
;
}
}
break
;
break
;
default
:
// 默认处理
updatedResponse
.
contentBlocks
.
push
({
content
:
this
.
templates
.
text
(
messageContent
||
''
),
hasThinkBox
:
false
,
thinkContent
:
''
,
thinkBoxExpanded
:
false
,
});
break
;
}
}
}
}
break
;
break
;
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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