mirror of
https://github.com/CherryHQ/cherry-studio.git
synced 2026-01-07 05:39:05 +08:00
feat: Show all topics on drag start
- Enforce the drag and drop functionality to show all topics on drag start.
This commit is contained in:
parent
4d57f624b3
commit
475290a204
@ -100,9 +100,12 @@ const Topics: FC<Props> = ({ assistant: _assistant, activeTopic, setActiveTopic
|
|||||||
return (
|
return (
|
||||||
<Container>
|
<Container>
|
||||||
<DragableList
|
<DragableList
|
||||||
list={take(assistant.topics, showAll ? assistant.topics.length : 15)}
|
list={take(assistant.topics, showAll ? assistant.topics.length : 14)}
|
||||||
onUpdate={updateTopics}
|
onUpdate={updateTopics}
|
||||||
onDragStart={() => setDraging(true)}
|
onDragStart={() => {
|
||||||
|
setShowAll(true)
|
||||||
|
setDraging(true)
|
||||||
|
}}
|
||||||
onDragEnd={() => setDraging(false)}>
|
onDragEnd={() => setDraging(false)}>
|
||||||
{(topic) => {
|
{(topic) => {
|
||||||
const isActive = topic.id === activeTopic?.id
|
const isActive = topic.id === activeTopic?.id
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user