feat:清空数据安装软件时,插件侧边栏中默认的popular,recommend页面不显示,并支持显示/隐藏.

This commit is contained in:
chriswang521 2024-06-13 16:49:26 +08:00 committed by wangpenglong
parent 6263df6635
commit e5743383a8
1 changed files with 3 additions and 1 deletions

View File

@ -224,9 +224,10 @@ export class ExtensionsViewletViewsContribution implements IWorkbenchContributio
name: localize2('popularExtensions', "Popular"),
ctorDescriptor: new SyncDescriptor(DefaultPopularExtensionsView, [{ hideBadge: true }]),
when: ContextKeyExpr.and(DefaultViewsContext, ContextKeyExpr.not('hasInstalledExtensions'), CONTEXT_HAS_GALLERY),
hideByDefault: true,
weight: 60,
order: 2,
canToggleVisibility: false
canToggleVisibility: true
});
/*
@ -255,6 +256,7 @@ export class ExtensionsViewletViewsContribution implements IWorkbenchContributio
name: localize2('recommendedExtensions', "Recommended"),
ctorDescriptor: new SyncDescriptor(DefaultRecommendedExtensionsView, [{ flexibleHeight: true }]),
when: ContextKeyExpr.and(DefaultViewsContext, SortByUpdateDateContext.negate(), ContextKeyExpr.not('config.extensions.showRecommendationsOnlyOnDemand'), CONTEXT_HAS_GALLERY),
hideByDefault: true,
weight: 40,
order: 3,
canToggleVisibility: true