mirror of
https://github.com/danswer-ai/danswer.git
synced 2025-09-29 21:37:21 +02:00
k (#4172)
This commit is contained in:
@@ -191,6 +191,7 @@ export const FolderDropdown = forwardRef<HTMLDivElement, FolderDropdownProps>(
|
|||||||
onChange={(e) => setNewFolderName(e.target.value)}
|
onChange={(e) => setNewFolderName(e.target.value)}
|
||||||
className="text-sm font-medium bg-transparent outline-none w-full pb-1 border-b border-background-500 transition-colors duration-200"
|
className="text-sm font-medium bg-transparent outline-none w-full pb-1 border-b border-background-500 transition-colors duration-200"
|
||||||
onKeyDown={(e) => {
|
onKeyDown={(e) => {
|
||||||
|
e.stopPropagation();
|
||||||
if (e.key === "Enter") {
|
if (e.key === "Enter") {
|
||||||
handleEdit();
|
handleEdit();
|
||||||
}
|
}
|
||||||
|
@@ -303,7 +303,6 @@ const FolderItem = ({
|
|||||||
key={chatSession.id}
|
key={chatSession.id}
|
||||||
chatSession={chatSession}
|
chatSession={chatSession}
|
||||||
isSelected={chatSession.id === currentChatId}
|
isSelected={chatSession.id === currentChatId}
|
||||||
skipGradient={isDragOver}
|
|
||||||
showShareModal={showShareModal}
|
showShareModal={showShareModal}
|
||||||
showDeleteModal={showDeleteModal}
|
showDeleteModal={showDeleteModal}
|
||||||
/>
|
/>
|
||||||
|
@@ -32,21 +32,17 @@ export function ChatSessionDisplay({
|
|||||||
chatSession,
|
chatSession,
|
||||||
search,
|
search,
|
||||||
isSelected,
|
isSelected,
|
||||||
skipGradient,
|
|
||||||
closeSidebar,
|
closeSidebar,
|
||||||
showShareModal,
|
showShareModal,
|
||||||
showDeleteModal,
|
showDeleteModal,
|
||||||
foldersExisting,
|
|
||||||
isDragging,
|
isDragging,
|
||||||
}: {
|
}: {
|
||||||
chatSession: ChatSession;
|
chatSession: ChatSession;
|
||||||
isSelected: boolean;
|
isSelected: boolean;
|
||||||
search?: boolean;
|
search?: boolean;
|
||||||
skipGradient?: boolean;
|
|
||||||
closeSidebar?: () => void;
|
closeSidebar?: () => void;
|
||||||
showShareModal?: (chatSession: ChatSession) => void;
|
showShareModal?: (chatSession: ChatSession) => void;
|
||||||
showDeleteModal?: (chatSession: ChatSession) => void;
|
showDeleteModal?: (chatSession: ChatSession) => void;
|
||||||
foldersExisting?: boolean;
|
|
||||||
isDragging?: boolean;
|
isDragging?: boolean;
|
||||||
}) {
|
}) {
|
||||||
const router = useRouter();
|
const router = useRouter();
|
||||||
@@ -238,8 +234,12 @@ export function ChatSessionDisplay({
|
|||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
e.stopPropagation();
|
e.stopPropagation();
|
||||||
}}
|
}}
|
||||||
onChange={(e) => setChatName(e.target.value)}
|
onChange={(e) => {
|
||||||
|
setChatName(e.target.value);
|
||||||
|
}}
|
||||||
onKeyDown={(event) => {
|
onKeyDown={(event) => {
|
||||||
|
event.stopPropagation();
|
||||||
|
|
||||||
if (event.key === "Enter") {
|
if (event.key === "Enter") {
|
||||||
onRename();
|
onRename();
|
||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
|
@@ -264,7 +264,6 @@ export function PagesTab({
|
|||||||
>
|
>
|
||||||
<ChatSessionDisplay
|
<ChatSessionDisplay
|
||||||
chatSession={chat}
|
chatSession={chat}
|
||||||
foldersExisting={foldersExisting}
|
|
||||||
isSelected={currentChatId === chat.id}
|
isSelected={currentChatId === chat.id}
|
||||||
showShareModal={showShareModal}
|
showShareModal={showShareModal}
|
||||||
showDeleteModal={showDeleteModal}
|
showDeleteModal={showDeleteModal}
|
||||||
|
Reference in New Issue
Block a user