@teodorruskvi/chat-core 0.1.37 → 0.1.39

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -41,7 +41,6 @@ export declare function useChatSession<TValues = Record<string, any>>(options?:
41
41
  createThread: any;
42
42
  deleteThread: any;
43
43
  renameThread: any;
44
- shareThread: any;
45
44
  threads: import("../../../types").ThreadSummary[];
46
45
  isThreadsLoading: boolean;
47
46
  };
@@ -1,7 +1,7 @@
1
1
  import { type MutableRefObject } from 'react';
2
2
  import type { ChatApi } from "@/shared/core";
3
3
  import type { ThreadInfoEvent } from '@/features/streaming';
4
- import type { ProjectInfo, SharedThreadSummary, ThreadSummary } from '@/types';
4
+ import type { ProjectInfo, ThreadSummary } from '@/types';
5
5
  interface ThreadActions {
6
6
  createThread: (title?: string, project?: {
7
7
  id: string;
@@ -10,9 +10,6 @@ interface ThreadActions {
10
10
  deleteThread: (threadId: string) => Promise<void>;
11
11
  renameThread: (threadId: string, title: string) => Promise<void>;
12
12
  refreshThreads: () => Promise<void>;
13
- refreshSharedThreads: () => Promise<void>;
14
- shareThread: (threadId: string, sharedWithUserId: string) => Promise<void>;
15
- unshareThread: (threadId: string, shareId: string) => Promise<void>;
16
13
  }
17
14
  interface UseThreadsStateOptions {
18
15
  api: ChatApi;
@@ -28,13 +25,8 @@ export interface UseThreadsStateResult {
28
25
  setCurrentThreadId: (id: string | null) => void;
29
26
  isLoadingThreads: boolean;
30
27
  threadsError: string | null;
31
- sharedThreads: SharedThreadSummary[];
32
- isLoadingSharedThreads: boolean;
33
28
  actions: ThreadActions;
34
29
  addThreadFromEvent: (threadInfo: ThreadInfoEvent) => void;
35
- shareInFlight: boolean;
36
- shareStatus: string | null;
37
- clearShareStatus: () => void;
38
30
  }
39
31
  export declare function useThreadsState({ api, initialThreadId, onError, onThreadChange, onCurrentThreadDeleted, }: UseThreadsStateOptions): UseThreadsStateResult;
40
32
  export {};
@@ -11,8 +11,6 @@ export interface ThreadsContextValue {
11
11
  currentThreadIdRef: MutableRefObject<string | null>;
12
12
  isLoading: boolean;
13
13
  error: string | null;
14
- sharedThreads: ThreadSummary[];
15
- isLoadingSharedThreads: boolean;
16
14
  actions: {
17
15
  createThread: (title?: string, project?: ({
18
16
  id: string;
@@ -21,13 +19,7 @@ export interface ThreadsContextValue {
21
19
  deleteThread: (threadId: string) => Promise<void>;
22
20
  renameThread: (threadId: string, title: string) => Promise<void>;
23
21
  refreshThreads: () => Promise<void>;
24
- refreshSharedThreads: () => Promise<void>;
25
- shareThread: (threadId: string, sharedWithUserId: string) => Promise<void>;
26
- unshareThread: (threadId: string, shareId: string) => Promise<void>;
27
22
  };
28
- shareInFlight: boolean;
29
- shareStatus: string | null;
30
- clearShareStatus: () => void;
31
23
  addThreadFromEvent: (threadInfo: ThreadInfoEvent) => void;
32
24
  }
33
25
  export interface ThreadStateContextValue {