@@ -58,6 +58,17 @@ const UIStrings = {
5858 *@example {AI assistance in Settings} PH1
5959 */
6060 turnOnForStylesAndRequests : 'Turn on {PH1} to get help with styles and network requests' ,
61+ /**
62+ *@description Text for asking the user to turn the AI assistance feature in settings first before they are able to use it.
63+ *@example {AI assistance in Settings} PH1
64+ */
65+ turnOnForStylesRequestsAndFiles : 'Turn on {PH1} to get help with styles, network requests, and files' ,
66+ /**
67+ *@description Text for asking the user to turn the AI assistance feature in settings first before they are able to use it.
68+ *@example {AI assistance in Settings} PH1
69+ */
70+ turnOnForStylesRequestsPerformanceAndFiles :
71+ 'Turn on {PH1} to get help with styles, network requests, performance, and files' ,
6172 /**
6273 *@description The footer disclaimer that links to more information about the AI feature.
6374 */
@@ -1060,11 +1071,21 @@ export class FreestylerChatUi extends HTMLElement {
10601071 void UI . ViewManager . ViewManager . instance ( ) . showView ( 'chrome-ai' ) ;
10611072 } ) ;
10621073 settingsLink . setAttribute ( 'jslog' , `${ VisualLogging . action ( 'open-ai-settings' ) . track ( { click : true } ) } ` ) ;
1074+ return html `${ i18n . i18n . getFormatLocalizedString ( str_ , this . #getStringForConsentView( ) , { PH1 : settingsLink } ) } ` ;
1075+ }
1076+
1077+ #getStringForConsentView( ) : string {
10631078 const config = Common . Settings . Settings . instance ( ) . getHostConfig ( ) ;
1064- return html `${
1065- config . devToolsExplainThisResourceDogfood ?. enabled ?
1066- i18n . i18n . getFormatLocalizedString ( str_ , UIStrings . turnOnForStylesAndRequests , { PH1 : settingsLink } ) :
1067- i18n . i18n . getFormatLocalizedString ( str_ , UIStrings . turnOnForStyles , { PH1 : settingsLink } ) } `;
1079+ if ( config . devToolsAiAssistancePerformanceAgentDogfood ?. enabled ) {
1080+ return UIStrings . turnOnForStylesRequestsPerformanceAndFiles ;
1081+ }
1082+ if ( config . devToolsAiAssistanceFileAgentDogfood ?. enabled ) {
1083+ return UIStrings . turnOnForStylesRequestsAndFiles ;
1084+ }
1085+ if ( config . devToolsExplainThisResourceDogfood ?. enabled ) {
1086+ return UIStrings . turnOnForStylesAndRequests ;
1087+ }
1088+ return UIStrings . turnOnForStyles ;
10681089 }
10691090
10701091 #getUnavailableAidaAvailabilityContents(
0 commit comments