Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
sdream-ai-fe
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
侯明涛
sdream-ai-fe
Commits
9512f2b5
Commit
9512f2b5
authored
Aug 15, 2024
by
HoMeTown
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 提交
parent
27110f11
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
55 additions
and
4 deletions
+55
-4
src/components/ConversationModal/index.tsx
+4
-3
src/components/MarkdownDetail/MarkdownDetail.module.less
+35
-0
src/components/MarkdownDetail/MarkdownDetail.module.less.d.ts
+15
-0
src/pages/Chat/components/ChatItem/ChatAnswerParser.tsx
+1
-1
No files found.
src/components/ConversationModal/index.tsx
View file @
9512f2b5
...
...
@@ -24,7 +24,8 @@ export const ConversationModal: React.FC<ConversationModalProps> = ({ isOpen, on
},
]
const
{
currentConversationId
,
conversations
}
=
useAppSelector
(
state
=>
state
.
conversation
)
// currentConversationId
const
{
conversations
}
=
useAppSelector
(
state
=>
state
.
conversation
)
const
[
selectedKeys
,
setSelectedKeys
]
=
React
.
useState
(
new
Set
([]))
const
allItems
=
conversations
.
filter
(
item
=>
item
.
conversationId
)
const
handleClose
=
()
=>
{
...
...
@@ -39,7 +40,7 @@ export const ConversationModal: React.FC<ConversationModalProps> = ({ isOpen, on
showToast
(
'删除成功'
,
'success'
)
}
else
{
showToast
(
'
删除失败
'
,
'error'
)
showToast
(
'
当前会话不允许删除
'
,
'error'
)
}
}
}
...
...
@@ -59,12 +60,12 @@ export const ConversationModal: React.FC<ConversationModalProps> = ({ isOpen, on
</
div
>
</
ModalHeader
>
<
ModalBody
className=
"text-[#27353C]"
>
{
/* disabledKeys={[currentConversationId || '']} */
}
<
Table
removeWrapper
isHeaderSticky
selectionMode=
"multiple"
selectedKeys=
{
selectedKeys
}
disabledKeys=
{
[
currentConversationId
||
''
]
}
onSelectionChange=
{
keys
=>
setSelectedKeys
(
keys
as
any
)
}
aria
-
label=
"table"
classNames=
{
{
...
...
src/components/MarkdownDetail/MarkdownDetail.module.less
0 → 100644
View file @
9512f2b5
.blinking-cursor {
position: relative;
}
.blinking-cursor::after {
content: '|';
position: absolute;
right: -0.1em;
width: 1px;
color: black;
animation: blink 0.7s infinite;
}
@keyframes blink {
0%, 100% {
opacity: 1;
}
50% {
opacity: 0;
}
}
/* 可选:为不同的元素设置不同的光标样式 */
.thin-cursor::after {
content: '|'; /* 使用全角竖线字符 */
}
.block-cursor::after {
content: '▋'; /* 使用块状字符 */
}
/* 可选:改变光标颜色 */
.colored-cursor::after {
color: #007bff;
}
src/components/MarkdownDetail/MarkdownDetail.module.less.d.ts
0 → 100644
View file @
9512f2b5
// This file is automatically generated.
// Please do not change this file!
interface
CssExports
{
'blink'
:
string
'blinking-cursor'
:
string
'blinkingCursor'
:
string
'block-cursor'
:
string
'blockCursor'
:
string
'colored-cursor'
:
string
'coloredCursor'
:
string
'thin-cursor'
:
string
'thinCursor'
:
string
}
declare
const
cssExports
:
CssExports
export
default
cssExports
src/pages/Chat/components/ChatItem/ChatAnswerParser.tsx
View file @
9512f2b5
...
...
@@ -61,7 +61,7 @@ export const ChatAnswerParser: React.FC<ChatAnswerParserProps> = ({ isLastAnswer
},
[
isStopTyping
])
useEffect
(()
=>
{
setHideOperate
(
answer
.
attachmentList
.
some
(
attachment
=>
attachment
.
type
===
'box'
))
setHideOperate
(
(
answer
.
attachmentList
||
[])
.
some
(
attachment
=>
attachment
.
type
===
'box'
))
},
[
answer
.
attachmentList
])
return
(
...
...
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