@@ -504,6 +504,47 @@ suite('Sessions - Chat View', () => {
504504 } ) ;
505505 } ) ;
506506
507+ test ( 'keeps the request edit input opaque over the chat background' , ( ) => {
508+ const workbench = dom . $ ( '.monaco-workbench.agent-sessions-workbench' ) ;
509+ workbench . style . setProperty ( '--session-view-background' , '#202020' ) ;
510+ workbench . style . setProperty ( '--vscode-chat-requestBubbleBackground' , 'rgba(255, 255, 255, 0.3)' ) ;
511+ const appendEditInput = ( part : HTMLElement ) => {
512+ const chatView = dom . append ( part , dom . $ ( '.chat-view' ) ) ;
513+ const session = dom . append ( chatView , dom . $ ( '.interactive-session' ) ) ;
514+ const request = dom . append ( session , dom . $ ( '.interactive-item-container.interactive-request.editing' ) ) ;
515+ const editContainer = dom . append ( request , dom . $ ( '.chat-edit-input-container' ) ) ;
516+ const inlineInputPart = dom . append ( editContainer , dom . $ ( '.interactive-input-part' ) ) ;
517+ const composerInputPart = dom . append ( session , dom . $ ( '.interactive-input-part.editing' ) ) ;
518+ return {
519+ inline : dom . append ( inlineInputPart , dom . $ ( '.chat-input-container' ) ) ,
520+ composer : dom . append ( composerInputPart , dom . $ ( '.chat-input-container' ) ) ,
521+ } ;
522+ } ;
523+ const background = appendEditInput ( dom . append ( workbench , dom . $ ( '.part.sessionspart.has-chat-background' ) ) ) ;
524+ const plain = appendEditInput ( dom . append ( workbench , dom . $ ( '.part.sessionspart' ) ) ) ;
525+ dom . getWindow ( workbench ) . document . body . appendChild ( workbench ) ;
526+ disposables . add ( toDisposable ( ( ) => workbench . remove ( ) ) ) ;
527+
528+ const inlineStyle = dom . getWindow ( background . inline ) . getComputedStyle ( background . inline ) ;
529+ const composerStyle = dom . getWindow ( background . composer ) . getComputedStyle ( background . composer ) ;
530+ const plainInlineStyle = dom . getWindow ( plain . inline ) . getComputedStyle ( plain . inline ) ;
531+ assert . deepStrictEqual ( {
532+ inlineBackgroundColor : inlineStyle . backgroundColor ,
533+ inlineBackgroundImage : inlineStyle . backgroundImage ,
534+ composerBackgroundColor : composerStyle . backgroundColor ,
535+ composerBackgroundImage : composerStyle . backgroundImage ,
536+ plainInlineBackgroundColor : plainInlineStyle . backgroundColor ,
537+ plainInlineBackgroundImage : plainInlineStyle . backgroundImage ,
538+ } , {
539+ inlineBackgroundColor : 'rgb(32, 32, 32)' ,
540+ inlineBackgroundImage : 'linear-gradient(rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0.3))' ,
541+ composerBackgroundColor : 'rgb(32, 32, 32)' ,
542+ composerBackgroundImage : 'linear-gradient(rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0.3))' ,
543+ plainInlineBackgroundColor : 'rgba(255, 255, 255, 0.3)' ,
544+ plainInlineBackgroundImage : 'none' ,
545+ } ) ;
546+ } ) ;
547+
507548 test ( 'applies a borderless translucent side fade to the complete assistant response' , ( ) => {
508549 const workbench = dom . $ ( '.monaco-workbench.agent-sessions-workbench' ) ;
509550 workbench . style . setProperty ( '--session-view-background' , '#ffffff' ) ;
0 commit comments