@@ -28,9 +28,19 @@ interface InputFooterProps {
2828 sessionId ?: string | null
2929 onNewChat ?: ( ) => void
3030 inputContainerRef ?: RefObject < HTMLDivElement | null >
31+ /** 阻塞中的后台任务(非空时显示「移到后台」入口,官方 BackgroundMoveHint 同款克制呈现) */
32+ backgroundTasks ?: Array < { label : string } >
33+ onMoveToBackground ?: ( ) => void
34+ backgroundMoving ?: boolean
3135}
3236
33- export const InputFooter = memo ( function InputFooter ( { paneId, onNewChat } : InputFooterProps ) {
37+ export const InputFooter = memo ( function InputFooter ( {
38+ paneId,
39+ onNewChat,
40+ backgroundTasks,
41+ onMoveToBackground,
42+ backgroundMoving,
43+ } : InputFooterProps ) {
3444 const { t } = useTranslation ( [ 'chat' , 'common' ] )
3545 const fullAutoMode = useFullAutoMode ( paneId )
3646
@@ -65,6 +75,21 @@ export const InputFooter = memo(function InputFooter({ paneId, onNewChat }: Inpu
6575 < button onClick = { onNewChat } className = "hover:text-text-300 transition-colors" >
6676 { t ( 'inputFooter.pleaseVerify' ) }
6777 </ button >
78+
79+ { /* 移到后台(官方 BackgroundMoveHint 同款位置与重量:页脚一行的小字入口) */ }
80+ { backgroundTasks && backgroundTasks . length > 0 && onMoveToBackground && (
81+ < >
82+ < span className = "text-text-500/30 shrink-0" > ·</ span >
83+ < button
84+ onClick = { onMoveToBackground }
85+ disabled = { backgroundMoving }
86+ className = "hover:text-text-300 transition-colors disabled:opacity-50"
87+ title = { backgroundTasks . map ( task => task . label ) . join ( '、' ) }
88+ >
89+ { t ( 'chat:sessionBackground.move' , { count : backgroundTasks . length } ) }
90+ </ button >
91+ </ >
92+ ) }
6893 </ div >
6994 )
7095} )
0 commit comments