@@ -41,7 +41,6 @@ type ExtensionWorkspaceRecommendationsNotificationClassification = {
41
41
42
42
const ignoreImportantExtensionRecommendationStorageKey = 'extensionsAssistant/importantRecommendationsIgnore' ;
43
43
const donotShowWorkspaceRecommendationsStorageKey = 'extensionsAssistant/workspaceRecommendationsIgnore' ;
44
- const choiceNever = localize ( 'neverShowAgain' , "Don't Show Again" ) ;
45
44
46
45
type RecommendationsNotificationActions = {
47
46
onDidInstallRecommendedExtensions ( extensions : IExtension [ ] ) : void ;
@@ -258,14 +257,17 @@ export class ExtensionRecommendationNotificationService extends Disposable imple
258
257
searchValue = source === RecommendationSource . WORKSPACE ? '@recommended' : extensions . map ( extensionId => `@id:${ extensionId . identifier . id } ` ) . join ( ' ' ) ;
259
258
}
260
259
260
+ const donotShowAgainLabel = source === RecommendationSource . WORKSPACE ? localize ( 'donotShowAgain' , "Don't Show Again for this Repository" )
261
+ : extensions . length > 1 ? localize ( 'donotShowAgainExtension' , "Don't Show Again for these Extensions" ) : localize ( 'donotShowAgainExtensionSingle' , "Don't Show Again for this Extension" ) ;
262
+
261
263
return raceCancellablePromises ( [
262
- this . _registerP ( this . showRecommendationsNotification ( extensions , message , searchValue , source , recommendationsNotificationActions ) ) ,
264
+ this . _registerP ( this . showRecommendationsNotification ( extensions , message , searchValue , donotShowAgainLabel , source , recommendationsNotificationActions ) ) ,
263
265
this . _registerP ( this . waitUntilRecommendationsAreInstalled ( extensions ) )
264
266
] ) ;
265
267
266
268
}
267
269
268
- private showRecommendationsNotification ( extensions : IExtension [ ] , message : string , searchValue : string , source : RecommendationSource ,
270
+ private showRecommendationsNotification ( extensions : IExtension [ ] , message : string , searchValue : string , donotShowAgainLabel : string , source : RecommendationSource ,
269
271
{ onDidInstallRecommendedExtensions, onDidShowRecommendedExtensions, onDidCancelRecommendedExtensions, onDidNeverShowRecommendedExtensionsAgain } : RecommendationsNotificationActions ) : CancelablePromise < RecommendationsNotificationResult > {
270
272
return createCancelablePromise < RecommendationsNotificationResult > ( async token => {
271
273
let accepted = false ;
@@ -296,7 +298,7 @@ export class ExtensionRecommendationNotificationService extends Disposable imple
296
298
this . runAction ( this . instantiationService . createInstance ( SearchExtensionsAction , searchValue ) ) ;
297
299
}
298
300
} , {
299
- label : choiceNever ,
301
+ label : donotShowAgainLabel ,
300
302
isSecondary : true ,
301
303
run : ( ) => {
302
304
onDidNeverShowRecommendedExtensionsAgain ( extensions ) ;
0 commit comments