File tree Expand file tree Collapse file tree
browser/components/ChatContext Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -39,7 +39,7 @@ export const ChatContext = memo(() => {
3939 50 ,
4040 ) ( ( files ) => {
4141 if ( files ) {
42- updateAddedFiles ( files . attached ) ;
42+ updateAddedFiles ( [ ... files . attached ] ) ;
4343 }
4444 } , contextService ) ;
4545
@@ -57,7 +57,7 @@ export const ChatContext = memo(() => {
5757 } , [ ] ) ;
5858
5959 const onDidDeselect = useCallback ( ( uri : URI ) => {
60- contextService . removeFileFromContext ( uri ) ;
60+ contextService . removeFileFromContext ( uri , true ) ;
6161 } , [ ] ) ;
6262
6363 const onDidClickFile = useCallback ( ( uri : URI ) => {
Original file line number Diff line number Diff line change @@ -21,7 +21,7 @@ export interface LLMContextService {
2121 * 从 context 中移除文件
2222 * @param uri URI
2323 */
24- removeFileFromContext ( uri : URI ) : void ;
24+ removeFileFromContext ( uri : URI , isManual ?: boolean ) : void ;
2525
2626 /** 导出为可序列化格式 */
2727 serialize ( ) : SerializedContext ;
You can’t perform that action at this time.
0 commit comments