@codingame/monaco-vscode-workspace-trust-service-override 7.0.11 → 7.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@codingame/monaco-vscode-workspace-trust-service-override",
3
- "version": "7.0.11",
3
+ "version": "7.1.1",
4
4
  "keywords": [],
5
5
  "author": {
6
6
  "name": "CodinGame",
@@ -26,6 +26,6 @@
26
26
  }
27
27
  },
28
28
  "dependencies": {
29
- "vscode": "npm:@codingame/monaco-vscode-api@7.0.11"
29
+ "vscode": "npm:@codingame/monaco-vscode-api@7.1.1"
30
30
  }
31
31
  }
@@ -2,7 +2,7 @@ import { __decorate, __param } from 'vscode/external/tslib/tslib.es6.js';
2
2
  import './media/workspaceTrustEditor.css.js';
3
3
  import { SyncDescriptor } from 'vscode/vscode/vs/platform/instantiation/common/descriptors';
4
4
  import { Disposable, MutableDisposable } from 'vscode/vscode/vs/base/common/lifecycle';
5
- import { localizeWithPath, localize2WithPath } from 'vscode/vscode/vs/nls';
5
+ import { localize, localize2 } from 'vscode/vscode/vs/nls';
6
6
  import { registerAction2, Action2 } from 'vscode/vscode/vs/platform/actions/common/actions';
7
7
  import { Extensions as Extensions$1, ConfigurationScope } from 'vscode/vscode/vs/platform/configuration/common/configurationRegistry';
8
8
  import { IDialogService } from 'vscode/vscode/vs/platform/dialogs/common/dialogs.service';
@@ -53,7 +53,6 @@ import { IEnvironmentService } from 'vscode/vscode/vs/platform/environment/commo
53
53
  import { IFileService } from 'vscode/vscode/vs/platform/files/common/files.service';
54
54
  import Severity$1 from 'vscode/vscode/vs/base/common/severity';
55
55
 
56
- const _moduleId = "vs/workbench/contrib/workspace/browser/workspace.contribution";
57
56
  const BANNER_RESTRICTED_MODE = 'workbench.banner.restrictedMode';
58
57
  const STARTUP_PROMPT_SHOWN_KEY = 'workspace.trust.startupPrompt.shown';
59
58
  const BANNER_RESTRICTED_MODE_DISMISSED_KEY = 'workbench.banner.restrictedMode.dismissed';
@@ -92,34 +91,31 @@ let WorkspaceTrustRequestHandler = class WorkspaceTrustRequestHandler extends Di
92
91
  await this.workspaceTrustManagementService.workspaceResolved;
93
92
  const markdownDetails = [
94
93
  this.workspaceContextService.getWorkbenchState() !== WorkbenchState.EMPTY ?
95
- ( localizeWithPath(
96
- _moduleId,
97
- 0,
94
+ ( localize(
95
+ 3158,
98
96
  "You are trying to open untrusted files in a workspace which is trusted."
99
97
  )) :
100
- ( localizeWithPath(
101
- _moduleId,
102
- 1,
98
+ ( localize(
99
+ 3159,
103
100
  "You are trying to open untrusted files in a window which is trusted."
104
101
  )),
105
- ( localizeWithPath(
106
- _moduleId,
107
- 2,
102
+ ( localize(
103
+ 3160,
108
104
  "If you don't want to open untrusted files, we recommend to open them in Restricted Mode in a new window as the files may be malicious. See [our docs](https://aka.ms/vscode-workspace-trust) to learn more."
109
105
  ))
110
106
  ];
111
107
  await this.dialogService.prompt({
112
108
  type: Severity$1.Info,
113
109
  message: this.workspaceContextService.getWorkbenchState() !== WorkbenchState.EMPTY ?
114
- ( localizeWithPath(_moduleId, 3, "Do you want to allow untrusted files in this workspace?")) :
115
- ( localizeWithPath(_moduleId, 4, "Do you want to allow untrusted files in this window?")),
110
+ ( localize(3161, "Do you want to allow untrusted files in this workspace?")) :
111
+ ( localize(3162, "Do you want to allow untrusted files in this window?")),
116
112
  buttons: [
117
113
  {
118
- label: ( localizeWithPath(_moduleId, 5, "&&Open")),
114
+ label: ( localize(3163, "&&Open")),
119
115
  run: ({ checkboxChecked }) => this.workspaceTrustRequestService.completeOpenFilesTrustRequest(WorkspaceTrustUriResponse.Open, !!checkboxChecked)
120
116
  },
121
117
  {
122
- label: ( localizeWithPath(_moduleId, 6, "Open in &&Restricted Mode")),
118
+ label: ( localize(3164, "Open in &&Restricted Mode")),
123
119
  run: ({ checkboxChecked }) => this.workspaceTrustRequestService.completeOpenFilesTrustRequest(WorkspaceTrustUriResponse.OpenInNewWindow, !!checkboxChecked)
124
120
  }
125
121
  ],
@@ -127,7 +123,7 @@ let WorkspaceTrustRequestHandler = class WorkspaceTrustRequestHandler extends Di
127
123
  run: () => this.workspaceTrustRequestService.completeOpenFilesTrustRequest(WorkspaceTrustUriResponse.Cancel)
128
124
  },
129
125
  checkbox: {
130
- label: ( localizeWithPath(_moduleId, 7, "Remember my decision for all workspaces")),
126
+ label: ( localize(3165, "Remember my decision for all workspaces")),
131
127
  checked: false
132
128
  },
133
129
  custom: {
@@ -139,20 +135,19 @@ let WorkspaceTrustRequestHandler = class WorkspaceTrustRequestHandler extends Di
139
135
  this._register(this.workspaceTrustRequestService.onDidInitiateWorkspaceTrustRequest(async (requestOptions) => {
140
136
  await this.workspaceTrustManagementService.workspaceResolved;
141
137
  const message = this.useWorkspaceLanguage ?
142
- ( localizeWithPath(_moduleId, 8, "Do you trust the authors of the files in this workspace?")) :
143
- ( localizeWithPath(_moduleId, 9, "Do you trust the authors of the files in this folder?"));
144
- const defaultDetails = ( localizeWithPath(
145
- _moduleId,
146
- 10,
138
+ ( localize(3166, "Do you trust the authors of the files in this workspace?")) :
139
+ ( localize(3167, "Do you trust the authors of the files in this folder?"));
140
+ const defaultDetails = ( localize(
141
+ 3168,
147
142
  "A feature you are trying to use may be a security risk if you do not trust the source of the files or folders you currently have open."
148
143
  ));
149
144
  const details = requestOptions?.message ?? defaultDetails;
150
145
  const buttons = requestOptions?.buttons ?? [
151
- { label: this.useWorkspaceLanguage ? ( localizeWithPath(_moduleId, 11, "&&Trust Workspace & Continue")) : ( localizeWithPath(_moduleId, 12, "&&Trust Folder & Continue")), type: 'ContinueWithTrust' },
152
- { label: ( localizeWithPath(_moduleId, 13, "&&Manage")), type: 'Manage' }
146
+ { label: this.useWorkspaceLanguage ? ( localize(3169, "&&Trust Workspace & Continue")) : ( localize(3170, "&&Trust Folder & Continue")), type: 'ContinueWithTrust' },
147
+ { label: ( localize(3171, "&&Manage")), type: 'Manage' }
153
148
  ];
154
149
  if (!( (buttons.some(b => b.type === 'Cancel')))) {
155
- buttons.push({ label: ( localizeWithPath(_moduleId, 14, "Cancel")), type: 'Cancel' });
150
+ buttons.push({ label: ( localize(3172, "Cancel")), type: 'Cancel' });
156
151
  }
157
152
  const { result } = await this.dialogService.prompt({
158
153
  type: Severity$1.Info,
@@ -161,9 +156,8 @@ let WorkspaceTrustRequestHandler = class WorkspaceTrustRequestHandler extends Di
161
156
  icon: Codicon.shield,
162
157
  markdownDetails: [
163
158
  { markdown: ( (new MarkdownString(details))) },
164
- { markdown: ( (new MarkdownString(( localizeWithPath(
165
- _moduleId,
166
- 15,
159
+ { markdown: ( (new MarkdownString(( localize(
160
+ 3173,
167
161
  "If you don't trust the authors of these files, we do not recommend continuing as the files may be malicious. See [our docs](https://aka.ms/vscode-workspace-trust) to learn more."
168
162
  ))))) }
169
163
  ]
@@ -264,13 +258,12 @@ let WorkspaceTrustUXHandler = class WorkspaceTrustUXHandler extends Disposable {
264
258
  if (!( (addedFoldersTrustInfo.map(info => info.trusted))).every(trusted => trusted)) {
265
259
  const { confirmed } = await this.dialogService.confirm({
266
260
  type: Severity$1.Info,
267
- message: ( localizeWithPath(_moduleId, 16, "Do you trust the authors of the files in this folder?")),
268
- detail: ( localizeWithPath(
269
- _moduleId,
270
- 17,
261
+ message: ( localize(3174, "Do you trust the authors of the files in this folder?")),
262
+ detail: ( localize(
263
+ 3175,
271
264
  "You are adding files that are not currently trusted to a trusted workspace. Do you trust the authors of these new files?"
272
265
  )),
273
- cancelButton: ( localizeWithPath(_moduleId, 18, 'No')),
266
+ cancelButton: ( localize(3176, 'No')),
274
267
  custom: { icon: Codicon.shield }
275
268
  });
276
269
  await this.workspaceTrustManagementService.setUrisTrust(( (addedFoldersTrustInfo.map(i => i.uri))), confirmed);
@@ -298,38 +291,30 @@ let WorkspaceTrustUXHandler = class WorkspaceTrustUXHandler extends Disposable {
298
291
  console.warn('AI generated workspace trust dialog contents not available.');
299
292
  }
300
293
  const title = titleString ?? (this.useWorkspaceLanguage ?
301
- ( localizeWithPath(_moduleId, 8, "Do you trust the authors of the files in this workspace?")) :
302
- ( localizeWithPath(_moduleId, 9, "Do you trust the authors of the files in this folder?")));
294
+ ( localize(3176, "Do you trust the authors of the files in this workspace?")) :
295
+ ( localize(3176, "Do you trust the authors of the files in this folder?")));
303
296
  let checkboxText;
304
297
  const workspaceIdentifier = toWorkspaceIdentifier(this.workspaceContextService.getWorkspace());
305
298
  const isSingleFolderWorkspace = isSingleFolderWorkspaceIdentifier(workspaceIdentifier);
306
299
  const isEmptyWindow = isEmptyWorkspaceIdentifier(workspaceIdentifier);
307
300
  if (!isAiGeneratedWorkspace && this.workspaceTrustManagementService.canSetParentFolderTrust()) {
308
301
  const name = basename(dirname(workspaceIdentifier.uri));
309
- checkboxText = ( localizeWithPath(
310
- _moduleId,
311
- 19,
312
- "Trust the authors of all files in the parent folder '{0}'",
313
- name
314
- ));
302
+ checkboxText = ( localize(3177, "Trust the authors of all files in the parent folder '{0}'", name));
315
303
  }
316
- this.doShowModal(title, { label: trustOption ?? ( localizeWithPath(_moduleId, 20, "&&Yes, I trust the authors")), sublabel: isSingleFolderWorkspace ? ( localizeWithPath(_moduleId, 21, "Trust folder and enable all features")) : ( localizeWithPath(_moduleId, 22, "Trust workspace and enable all features")) }, { label: dontTrustOption ?? ( localizeWithPath(_moduleId, 23, "&&No, I don't trust the authors")), sublabel: isSingleFolderWorkspace ? ( localizeWithPath(_moduleId, 24, "Browse folder in restricted mode")) : ( localizeWithPath(_moduleId, 25, "Browse workspace in restricted mode")) }, [
304
+ this.doShowModal(title, { label: trustOption ?? ( localize(3178, "&&Yes, I trust the authors")), sublabel: isSingleFolderWorkspace ? ( localize(3179, "Trust folder and enable all features")) : ( localize(3180, "Trust workspace and enable all features")) }, { label: dontTrustOption ?? ( localize(3181, "&&No, I don't trust the authors")), sublabel: isSingleFolderWorkspace ? ( localize(3182, "Browse folder in restricted mode")) : ( localize(3183, "Browse workspace in restricted mode")) }, [
317
305
  !isSingleFolderWorkspace ?
318
- ( localizeWithPath(
319
- _moduleId,
320
- 26,
306
+ ( localize(
307
+ 3184,
321
308
  "{0} provides features that may automatically execute files in this workspace.",
322
309
  this.productService.nameShort
323
310
  )) :
324
- ( localizeWithPath(
325
- _moduleId,
326
- 27,
311
+ ( localize(
312
+ 3185,
327
313
  "{0} provides features that may automatically execute files in this folder.",
328
314
  this.productService.nameShort
329
315
  )),
330
- learnMoreString ?? ( localizeWithPath(
331
- _moduleId,
332
- 28,
316
+ learnMoreString ?? ( localize(
317
+ 3186,
333
318
  "If you don't trust the authors of these files, we recommend to continue in restricted mode as the files may be malicious. See [our docs](https://aka.ms/vscode-workspace-trust) to learn more."
334
319
  )),
335
320
  !isEmptyWindow ?
@@ -447,11 +432,11 @@ let WorkspaceTrustUXHandler = class WorkspaceTrustUXHandler extends Disposable {
447
432
  }
448
433
  const actions = [
449
434
  {
450
- label: ( localizeWithPath(_moduleId, 29, "Manage")),
435
+ label: ( localize(3187, "Manage")),
451
436
  href: 'command:' + MANAGE_TRUST_COMMAND_ID
452
437
  },
453
438
  {
454
- label: ( localizeWithPath(_moduleId, 30, "Learn More")),
439
+ label: ( localize(3188, "Learn More")),
455
440
  href: 'https://aka.ms/vscode-workspace-trust'
456
441
  }
457
442
  ];
@@ -471,21 +456,18 @@ let WorkspaceTrustUXHandler = class WorkspaceTrustUXHandler extends Disposable {
471
456
  getBannerItemAriaLabels() {
472
457
  switch (this.workspaceContextService.getWorkbenchState()) {
473
458
  case WorkbenchState.EMPTY:
474
- return ( localizeWithPath(
475
- _moduleId,
476
- 31,
459
+ return ( localize(
460
+ 3189,
477
461
  "Restricted Mode is intended for safe code browsing. Trust this window to enable all features. Use navigation keys to access banner actions."
478
462
  ));
479
463
  case WorkbenchState.FOLDER:
480
- return ( localizeWithPath(
481
- _moduleId,
482
- 32,
464
+ return ( localize(
465
+ 3190,
483
466
  "Restricted Mode is intended for safe code browsing. Trust this folder to enable all features. Use navigation keys to access banner actions."
484
467
  ));
485
468
  case WorkbenchState.WORKSPACE:
486
- return ( localizeWithPath(
487
- _moduleId,
488
- 33,
469
+ return ( localize(
470
+ 3191,
489
471
  "Restricted Mode is intended for safe code browsing. Trust this workspace to enable all features. Use navigation keys to access banner actions."
490
472
  ));
491
473
  }
@@ -493,21 +475,18 @@ let WorkspaceTrustUXHandler = class WorkspaceTrustUXHandler extends Disposable {
493
475
  getBannerItemMessages() {
494
476
  switch (this.workspaceContextService.getWorkbenchState()) {
495
477
  case WorkbenchState.EMPTY:
496
- return ( localizeWithPath(
497
- _moduleId,
498
- 34,
478
+ return ( localize(
479
+ 3192,
499
480
  "Restricted Mode is intended for safe code browsing. Trust this window to enable all features."
500
481
  ));
501
482
  case WorkbenchState.FOLDER:
502
- return ( localizeWithPath(
503
- _moduleId,
504
- 35,
483
+ return ( localize(
484
+ 3193,
505
485
  "Restricted Mode is intended for safe code browsing. Trust this folder to enable all features."
506
486
  ));
507
487
  case WorkbenchState.WORKSPACE:
508
- return ( localizeWithPath(
509
- _moduleId,
510
- 36,
488
+ return ( localize(
489
+ 3194,
511
490
  "Restricted Mode is intended for safe code browsing. Trust this workspace to enable all features."
512
491
  ));
513
492
  }
@@ -524,15 +503,13 @@ let WorkspaceTrustUXHandler = class WorkspaceTrustUXHandler extends Disposable {
524
503
  let toolTip;
525
504
  switch (this.workspaceContextService.getWorkbenchState()) {
526
505
  case WorkbenchState.EMPTY: {
527
- ariaLabel = ( localizeWithPath(
528
- _moduleId,
529
- 37,
506
+ ariaLabel = ( localize(
507
+ 3195,
530
508
  "Restricted Mode: Some features are disabled because this window is not trusted."
531
509
  ));
532
510
  toolTip = {
533
- value: ( localizeWithPath(
534
- _moduleId,
535
- 38,
511
+ value: ( localize(
512
+ 3196,
536
513
  "Running in Restricted Mode\n\nSome [features are disabled]({0}) because this [window is not trusted]({1}).",
537
514
  `command:${LIST_WORKSPACE_UNSUPPORTED_EXTENSIONS_COMMAND_ID}`,
538
515
  `command:${MANAGE_TRUST_COMMAND_ID}`
@@ -543,15 +520,13 @@ let WorkspaceTrustUXHandler = class WorkspaceTrustUXHandler extends Disposable {
543
520
  break;
544
521
  }
545
522
  case WorkbenchState.FOLDER: {
546
- ariaLabel = ( localizeWithPath(
547
- _moduleId,
548
- 39,
523
+ ariaLabel = ( localize(
524
+ 3197,
549
525
  "Restricted Mode: Some features are disabled because this folder is not trusted."
550
526
  ));
551
527
  toolTip = {
552
- value: ( localizeWithPath(
553
- _moduleId,
554
- 40,
528
+ value: ( localize(
529
+ 3198,
555
530
  "Running in Restricted Mode\n\nSome [features are disabled]({0}) because this [folder is not trusted]({1}).",
556
531
  `command:${LIST_WORKSPACE_UNSUPPORTED_EXTENSIONS_COMMAND_ID}`,
557
532
  `command:${MANAGE_TRUST_COMMAND_ID}`
@@ -562,15 +537,13 @@ let WorkspaceTrustUXHandler = class WorkspaceTrustUXHandler extends Disposable {
562
537
  break;
563
538
  }
564
539
  case WorkbenchState.WORKSPACE: {
565
- ariaLabel = ( localizeWithPath(
566
- _moduleId,
567
- 41,
540
+ ariaLabel = ( localize(
541
+ 3199,
568
542
  "Restricted Mode: Some features are disabled because this workspace is not trusted."
569
543
  ));
570
544
  toolTip = {
571
- value: ( localizeWithPath(
572
- _moduleId,
573
- 42,
545
+ value: ( localize(
546
+ 3200,
574
547
  "Running in Restricted Mode\n\nSome [features are disabled]({0}) because this [workspace is not trusted]({1}).",
575
548
  `command:${LIST_WORKSPACE_UNSUPPORTED_EXTENSIONS_COMMAND_ID}`,
576
549
  `command:${MANAGE_TRUST_COMMAND_ID}`
@@ -582,8 +555,8 @@ let WorkspaceTrustUXHandler = class WorkspaceTrustUXHandler extends Disposable {
582
555
  }
583
556
  }
584
557
  return {
585
- name: ( localizeWithPath(_moduleId, 43, "Workspace Trust")),
586
- text: `$(shield) ${( localizeWithPath(_moduleId, 44, "Restricted Mode"))}`,
558
+ name: ( localize(3201, "Workspace Trust")),
559
+ text: `$(shield) ${( localize(3202, "Restricted Mode"))}`,
587
560
  ariaLabel: ariaLabel,
588
561
  tooltip: toolTip,
589
562
  command: MANAGE_TRUST_COMMAND_ID,
@@ -633,16 +606,16 @@ class WorkspaceTrustEditorInputSerializer {
633
606
  }
634
607
  ( (Registry.as(EditorExtensions.EditorFactory)))
635
608
  .registerEditorSerializer(WorkspaceTrustEditorInput.ID, WorkspaceTrustEditorInputSerializer);
636
- ( (Registry.as(EditorExtensions.EditorPane))).registerEditorPane(EditorPaneDescriptor.create(WorkspaceTrustEditor, WorkspaceTrustEditor.ID, ( localizeWithPath(_moduleId, 45, "Workspace Trust Editor"))), [
609
+ ( (Registry.as(EditorExtensions.EditorPane))).registerEditorPane(EditorPaneDescriptor.create(WorkspaceTrustEditor, WorkspaceTrustEditor.ID, ( localize(3203, "Workspace Trust Editor"))), [
637
610
  ( (new SyncDescriptor(WorkspaceTrustEditorInput)))
638
611
  ]);
639
612
  const CONFIGURE_TRUST_COMMAND_ID = 'workbench.trust.configure';
640
- const WORKSPACES_CATEGORY = ( localize2WithPath(_moduleId, 46, 'Workspaces'));
613
+ const WORKSPACES_CATEGORY = ( localize2(3204, 'Workspaces'));
641
614
  registerAction2(class extends Action2 {
642
615
  constructor() {
643
616
  super({
644
617
  id: CONFIGURE_TRUST_COMMAND_ID,
645
- title: ( localize2WithPath(_moduleId, 47, "Configure Workspace Trust Settings")),
618
+ title: ( localize2(3205, "Configure Workspace Trust Settings")),
646
619
  precondition: ( (ContextKeyExpr.and(
647
620
  WorkspaceTrustContext.IsEnabled,
648
621
  (ContextKeyExpr.equals(`config.${WORKSPACE_TRUST_ENABLED}`, true))
@@ -659,7 +632,7 @@ registerAction2(class extends Action2 {
659
632
  constructor() {
660
633
  super({
661
634
  id: MANAGE_TRUST_COMMAND_ID,
662
- title: ( localize2WithPath(_moduleId, 48, "Manage Workspace Trust")),
635
+ title: ( localize2(3206, "Manage Workspace Trust")),
663
636
  precondition: ( (ContextKeyExpr.and(
664
637
  WorkspaceTrustContext.IsEnabled,
665
638
  (ContextKeyExpr.equals(`config.${WORKSPACE_TRUST_ENABLED}`, true))
@@ -683,74 +656,44 @@ registerAction2(class extends Action2 {
683
656
  [WORKSPACE_TRUST_ENABLED]: {
684
657
  type: 'boolean',
685
658
  default: true,
686
- description: ( localizeWithPath(
687
- _moduleId,
688
- 49,
689
- "Controls whether or not Workspace Trust is enabled within VS Code."
690
- )),
659
+ description: ( localize(3207, "Controls whether or not Workspace Trust is enabled within VS Code.")),
691
660
  tags: [WORKSPACE_TRUST_SETTING_TAG],
692
661
  scope: ConfigurationScope.APPLICATION,
693
662
  },
694
663
  [WORKSPACE_TRUST_STARTUP_PROMPT]: {
695
664
  type: 'string',
696
665
  default: 'once',
697
- description: ( localizeWithPath(
698
- _moduleId,
699
- 50,
700
- "Controls when the startup prompt to trust a workspace is shown."
701
- )),
666
+ description: ( localize(3208, "Controls when the startup prompt to trust a workspace is shown.")),
702
667
  tags: [WORKSPACE_TRUST_SETTING_TAG],
703
668
  scope: ConfigurationScope.APPLICATION,
704
669
  enum: ['always', 'once', 'never'],
705
670
  enumDescriptions: [
706
- ( localizeWithPath(
707
- _moduleId,
708
- 51,
709
- "Ask for trust every time an untrusted workspace is opened."
710
- )),
711
- ( localizeWithPath(
712
- _moduleId,
713
- 52,
714
- "Ask for trust the first time an untrusted workspace is opened."
715
- )),
716
- ( localizeWithPath(
717
- _moduleId,
718
- 53,
719
- "Do not ask for trust when an untrusted workspace is opened."
720
- )),
671
+ ( localize(3209, "Ask for trust every time an untrusted workspace is opened.")),
672
+ ( localize(3210, "Ask for trust the first time an untrusted workspace is opened.")),
673
+ ( localize(3211, "Do not ask for trust when an untrusted workspace is opened.")),
721
674
  ]
722
675
  },
723
676
  [WORKSPACE_TRUST_BANNER]: {
724
677
  type: 'string',
725
678
  default: 'untilDismissed',
726
- description: ( localizeWithPath(_moduleId, 54, "Controls when the restricted mode banner is shown.")),
679
+ description: ( localize(3212, "Controls when the restricted mode banner is shown.")),
727
680
  tags: [WORKSPACE_TRUST_SETTING_TAG],
728
681
  scope: ConfigurationScope.APPLICATION,
729
682
  enum: ['always', 'untilDismissed', 'never'],
730
683
  enumDescriptions: [
731
- ( localizeWithPath(
732
- _moduleId,
733
- 55,
734
- "Show the banner every time an untrusted workspace is open."
735
- )),
736
- ( localizeWithPath(
737
- _moduleId,
738
- 56,
684
+ ( localize(3213, "Show the banner every time an untrusted workspace is open.")),
685
+ ( localize(
686
+ 3214,
739
687
  "Show the banner when an untrusted workspace is opened until dismissed."
740
688
  )),
741
- ( localizeWithPath(
742
- _moduleId,
743
- 57,
744
- "Do not show the banner when an untrusted workspace is open."
745
- )),
689
+ ( localize(3215, "Do not show the banner when an untrusted workspace is open.")),
746
690
  ]
747
691
  },
748
692
  [WORKSPACE_TRUST_UNTRUSTED_FILES]: {
749
693
  type: 'string',
750
694
  default: 'prompt',
751
- markdownDescription: ( localizeWithPath(
752
- _moduleId,
753
- 58,
695
+ markdownDescription: ( localize(
696
+ 3216,
754
697
  "Controls how to handle opening untrusted files in a trusted workspace. This setting also applies to opening files in an empty window which is trusted via `#{0}#`.",
755
698
  WORKSPACE_TRUST_EMPTY_WINDOW
756
699
  )),
@@ -758,19 +701,16 @@ registerAction2(class extends Action2 {
758
701
  scope: ConfigurationScope.APPLICATION,
759
702
  enum: ['prompt', 'open', 'newWindow'],
760
703
  enumDescriptions: [
761
- ( localizeWithPath(
762
- _moduleId,
763
- 59,
704
+ ( localize(
705
+ 3217,
764
706
  "Ask how to handle untrusted files for each workspace. Once untrusted files are introduced to a trusted workspace, you will not be prompted again."
765
707
  )),
766
- ( localizeWithPath(
767
- _moduleId,
768
- 60,
708
+ ( localize(
709
+ 3218,
769
710
  "Always allow untrusted files to be introduced to a trusted workspace without prompting."
770
711
  )),
771
- ( localizeWithPath(
772
- _moduleId,
773
- 61,
712
+ ( localize(
713
+ 3219,
774
714
  "Always open untrusted files in a separate window in restricted mode without prompting."
775
715
  )),
776
716
  ]
@@ -778,9 +718,8 @@ registerAction2(class extends Action2 {
778
718
  [WORKSPACE_TRUST_EMPTY_WINDOW]: {
779
719
  type: 'boolean',
780
720
  default: true,
781
- markdownDescription: ( localizeWithPath(
782
- _moduleId,
783
- 62,
721
+ markdownDescription: ( localize(
722
+ 3220,
784
723
  "Controls whether or not the empty window is trusted by default within VS Code. When used with `#{0}#`, you can enable the full functionality of VS Code without prompting in an empty window.",
785
724
  WORKSPACE_TRUST_UNTRUSTED_FILES
786
725
  )),
@@ -15,7 +15,7 @@ import { parseLinkedText } from 'vscode/vscode/vs/base/common/linkedText';
15
15
  import { Schemas } from 'vscode/vscode/vs/base/common/network';
16
16
  import { ScrollbarVisibility } from 'vscode/vscode/vs/base/common/scrollable';
17
17
  import { URI } from 'vscode/vscode/vs/base/common/uri';
18
- import { localizeWithPath } from 'vscode/vscode/vs/nls';
18
+ import { localize } from 'vscode/vscode/vs/nls';
19
19
  import { Extensions, ConfigurationScope } from 'vscode/vscode/vs/platform/configuration/common/configurationRegistry';
20
20
  import { IContextViewService } from 'vscode/vscode/vs/platform/contextview/browser/contextView.service';
21
21
  import { IFileDialogService } from 'vscode/vscode/vs/platform/dialogs/common/dialogs.service';
@@ -64,25 +64,12 @@ import { IKeybindingService } from 'vscode/vscode/vs/platform/keybinding/common/
64
64
  import { basename, dirname } from 'vscode/vscode/vs/base/common/resources';
65
65
 
66
66
  var TrustedUriActionsColumnRenderer_1, TrustedUriPathColumnRenderer_1, TrustedUriHostColumnRenderer_1, WorkspaceTrustEditor_1;
67
- const _moduleId = "vs/workbench/contrib/workspace/browser/workspaceTrustEditor";
68
- const shieldIcon = registerIcon('workspace-trust-banner', Codicon.shield, ( localizeWithPath(_moduleId, 0, 'Icon for workspace trust ion the banner.')));
69
- const checkListIcon = registerIcon('workspace-trust-editor-check', Codicon.check, ( localizeWithPath(_moduleId, 1, 'Icon for the checkmark in the workspace trust editor.')));
70
- const xListIcon = registerIcon('workspace-trust-editor-cross', Codicon.x, ( localizeWithPath(_moduleId, 2, 'Icon for the cross in the workspace trust editor.')));
71
- const folderPickerIcon = registerIcon('workspace-trust-editor-folder-picker', Codicon.folder, ( localizeWithPath(
72
- _moduleId,
73
- 3,
74
- 'Icon for the pick folder icon in the workspace trust editor.'
75
- )));
76
- const editIcon = registerIcon('workspace-trust-editor-edit-folder', Codicon.edit, ( localizeWithPath(
77
- _moduleId,
78
- 4,
79
- 'Icon for the edit folder icon in the workspace trust editor.'
80
- )));
81
- const removeIcon = registerIcon('workspace-trust-editor-remove-folder', Codicon.close, ( localizeWithPath(
82
- _moduleId,
83
- 5,
84
- 'Icon for the remove folder icon in the workspace trust editor.'
85
- )));
67
+ const shieldIcon = registerIcon('workspace-trust-banner', Codicon.shield, ( localize(7356, 'Icon for workspace trust ion the banner.')));
68
+ const checkListIcon = registerIcon('workspace-trust-editor-check', Codicon.check, ( localize(7357, 'Icon for the checkmark in the workspace trust editor.')));
69
+ const xListIcon = registerIcon('workspace-trust-editor-cross', Codicon.x, ( localize(7358, 'Icon for the cross in the workspace trust editor.')));
70
+ const folderPickerIcon = registerIcon('workspace-trust-editor-folder-picker', Codicon.folder, ( localize(7359, 'Icon for the pick folder icon in the workspace trust editor.')));
71
+ const editIcon = registerIcon('workspace-trust-editor-edit-folder', Codicon.edit, ( localize(7360, 'Icon for the edit folder icon in the workspace trust editor.')));
72
+ const removeIcon = registerIcon('workspace-trust-editor-remove-folder', Codicon.close, ( localize(7361, 'Icon for the remove folder icon in the workspace trust editor.')));
86
73
  let WorkspaceTrustedUrisTable = class WorkspaceTrustedUrisTable extends Disposable {
87
74
  constructor(container, instantiationService, workspaceService, workspaceTrustManagementService, uriService, labelService, fileDialogService) {
88
75
  super();
@@ -106,14 +93,14 @@ let WorkspaceTrustedUrisTable = class WorkspaceTrustedUrisTable extends Disposab
106
93
  const addButtonBarElement = container.appendChild($('.trusted-uris-button-bar'));
107
94
  this.table = this.instantiationService.createInstance(WorkbenchTable, 'WorkspaceTrust', tableElement, ( (new TrustedUriTableVirtualDelegate())), [
108
95
  {
109
- label: ( localizeWithPath(_moduleId, 6, "Host")),
96
+ label: ( localize(7362, "Host")),
110
97
  tooltip: '',
111
98
  weight: 1,
112
99
  templateId: TrustedUriHostColumnRenderer.TEMPLATE_ID,
113
100
  project(row) { return row; }
114
101
  },
115
102
  {
116
- label: ( localizeWithPath(_moduleId, 7, "Path")),
103
+ label: ( localize(7363, "Path")),
117
104
  tooltip: '',
118
105
  weight: 8,
119
106
  templateId: TrustedUriPathColumnRenderer.TEMPLATE_ID,
@@ -141,17 +128,16 @@ let WorkspaceTrustedUrisTable = class WorkspaceTrustedUrisTable extends Disposab
141
128
  getAriaLabel: (item) => {
142
129
  const hostLabel = getHostLabel(this.labelService, item);
143
130
  if (hostLabel === undefined || hostLabel.length === 0) {
144
- return ( localizeWithPath(_moduleId, 8, "{0}, trusted", this.labelService.getUriLabel(item.uri)));
131
+ return ( localize(7364, "{0}, trusted", this.labelService.getUriLabel(item.uri)));
145
132
  }
146
- return ( localizeWithPath(
147
- _moduleId,
148
- 9,
133
+ return ( localize(
134
+ 7365,
149
135
  "{0} on {1}, trusted",
150
136
  this.labelService.getUriLabel(item.uri),
151
137
  hostLabel
152
138
  ));
153
139
  },
154
- getWidgetAriaLabel: () => ( localizeWithPath(_moduleId, 10, "Trusted Folders & Workspaces"))
140
+ getWidgetAriaLabel: () => ( localize(7366, "Trusted Folders & Workspaces"))
155
141
  },
156
142
  identityProvider: {
157
143
  getId(element) {
@@ -167,16 +153,16 @@ let WorkspaceTrustedUrisTable = class WorkspaceTrustedUrisTable extends Disposab
167
153
  }
168
154
  }));
169
155
  const buttonBar = this._register(( (new ButtonBar(addButtonBarElement))));
170
- const addButton = this._register(buttonBar.addButton({ title: ( localizeWithPath(_moduleId, 11, "Add Folder")), ...defaultButtonStyles }));
171
- addButton.label = ( localizeWithPath(_moduleId, 11, "Add Folder"));
156
+ const addButton = this._register(buttonBar.addButton({ title: ( localize(7367, "Add Folder")), ...defaultButtonStyles }));
157
+ addButton.label = ( localize(7367, "Add Folder"));
172
158
  this._register(addButton.onDidClick(async () => {
173
159
  const uri = await this.fileDialogService.showOpenDialog({
174
160
  canSelectFiles: false,
175
161
  canSelectFolders: true,
176
162
  canSelectMany: false,
177
163
  defaultUri: this.currentWorkspaceUri,
178
- openLabel: ( localizeWithPath(_moduleId, 12, "Trust Folder")),
179
- title: ( localizeWithPath(_moduleId, 13, "Select Folder To Trust"))
164
+ openLabel: ( localize(7368, "Trust Folder")),
165
+ title: ( localize(7369, "Select Folder To Trust"))
180
166
  });
181
167
  if (uri) {
182
168
  this.workspaceTrustManagementService.setUrisTrust(uri, true);
@@ -256,12 +242,11 @@ let WorkspaceTrustedUrisTable = class WorkspaceTrustedUrisTable extends Disposab
256
242
  const entries = this.trustedUriEntries;
257
243
  this.container.classList.toggle('empty', entries.length === 0);
258
244
  this.descriptionElement.innerText = entries.length ?
259
- ( localizeWithPath(
260
- _moduleId,
261
- 14,
245
+ ( localize(
246
+ 7370,
262
247
  "You trust the following folders, their subfolders, and workspace files."
263
248
  )) :
264
- ( localizeWithPath(_moduleId, 15, "You haven't trusted any folders or workspace files yet."));
249
+ ( localize(7371, "You haven't trusted any folders or workspace files yet."));
265
250
  this.table.splice(0, Number.POSITIVE_INFINITY, this.trustedUriEntries);
266
251
  this.layout();
267
252
  }
@@ -274,9 +259,8 @@ let WorkspaceTrustedUrisTable = class WorkspaceTrustedUrisTable extends Disposab
274
259
  if (segments.length === 0 && path.startsWith(posix.sep)) {
275
260
  return {
276
261
  type: MessageType.WARNING,
277
- content: ( localizeWithPath(
278
- _moduleId,
279
- 16,
262
+ content: ( localize(
263
+ 7372,
280
264
  "You will trust all repositories on {0}.",
281
265
  getHostLabel(this.labelService, item)
282
266
  ))
@@ -285,9 +269,8 @@ let WorkspaceTrustedUrisTable = class WorkspaceTrustedUrisTable extends Disposab
285
269
  if (segments.length === 1) {
286
270
  return {
287
271
  type: MessageType.WARNING,
288
- content: ( localizeWithPath(
289
- _moduleId,
290
- 17,
272
+ content: ( localize(
273
+ 7373,
291
274
  "You will trust all repositories and forks under '{0}' on {1}.",
292
275
  segments[0],
293
276
  getHostLabel(this.labelService, item)
@@ -297,12 +280,7 @@ let WorkspaceTrustedUrisTable = class WorkspaceTrustedUrisTable extends Disposab
297
280
  if (segments.length > 2) {
298
281
  return {
299
282
  type: MessageType.ERROR,
300
- content: ( localizeWithPath(
301
- _moduleId,
302
- 18,
303
- "You cannot trust individual folders within a repository.",
304
- path
305
- ))
283
+ content: ( localize(7374, "You cannot trust individual folders within a repository.", path))
306
284
  };
307
285
  }
308
286
  }
@@ -343,8 +321,8 @@ let WorkspaceTrustedUrisTable = class WorkspaceTrustedUrisTable extends Disposab
343
321
  canSelectFolders: true,
344
322
  canSelectMany: false,
345
323
  defaultUri: item.uri,
346
- openLabel: ( localizeWithPath(_moduleId, 12, "Trust Folder")),
347
- title: ( localizeWithPath(_moduleId, 13, "Select Folder To Trust"))
324
+ openLabel: ( localize(7374, "Trust Folder")),
325
+ title: ( localize(7374, "Select Folder To Trust"))
348
326
  });
349
327
  if (uri) {
350
328
  this.acceptEdit(item, uri[0]);
@@ -411,7 +389,7 @@ let TrustedUriActionsColumnRenderer = class TrustedUriActionsColumnRenderer {
411
389
  class: ThemeIcon.asClassName(editIcon),
412
390
  enabled: true,
413
391
  id: 'editTrustedUri',
414
- tooltip: ( localizeWithPath(_moduleId, 19, "Edit Path")),
392
+ tooltip: ( localize(7375, "Edit Path")),
415
393
  run: () => {
416
394
  this.table.edit(item, false);
417
395
  }
@@ -423,7 +401,7 @@ let TrustedUriActionsColumnRenderer = class TrustedUriActionsColumnRenderer {
423
401
  class: ThemeIcon.asClassName(folderPickerIcon),
424
402
  enabled: true,
425
403
  id: 'pickerTrustedUri',
426
- tooltip: ( localizeWithPath(_moduleId, 20, "Open File Picker")),
404
+ tooltip: ( localize(7376, "Open File Picker")),
427
405
  run: () => {
428
406
  this.table.edit(item, true);
429
407
  }
@@ -435,7 +413,7 @@ let TrustedUriActionsColumnRenderer = class TrustedUriActionsColumnRenderer {
435
413
  class: ThemeIcon.asClassName(removeIcon),
436
414
  enabled: true,
437
415
  id: 'deleteTrustedUri',
438
- tooltip: ( localizeWithPath(_moduleId, 21, "Delete Path")),
416
+ tooltip: ( localize(7377, "Delete Path")),
439
417
  run: async () => {
440
418
  await this.table.delete(item);
441
419
  }
@@ -552,7 +530,7 @@ TrustedUriPathColumnRenderer = TrustedUriPathColumnRenderer_1 = ( (__decorate([
552
530
  ( (__param(1, IContextViewService)))
553
531
  ], TrustedUriPathColumnRenderer)));
554
532
  function getHostLabel(labelService, item) {
555
- return item.uri.authority ? labelService.getHostLabel(item.uri.scheme, item.uri.authority) : ( localizeWithPath(_moduleId, 22, "Local"));
533
+ return item.uri.authority ? labelService.getHostLabel(item.uri.scheme, item.uri.authority) : ( localize(7378, "Local"));
556
534
  }
557
535
  let TrustedUriHostColumnRenderer = class TrustedUriHostColumnRenderer {
558
536
  static { TrustedUriHostColumnRenderer_1 = this; }
@@ -685,18 +663,18 @@ let WorkspaceTrustEditor = class WorkspaceTrustEditor extends EditorPane {
685
663
  getHeaderTitleText(trusted) {
686
664
  if (trusted) {
687
665
  if (this.workspaceTrustManagementService.isWorkspaceTrustForced()) {
688
- return ( localizeWithPath(_moduleId, 23, "This window is trusted"));
666
+ return ( localize(7379, "This window is trusted"));
689
667
  }
690
668
  switch (this.workspaceService.getWorkbenchState()) {
691
669
  case WorkbenchState.EMPTY:
692
- return ( localizeWithPath(_moduleId, 24, "You trust this window"));
670
+ return ( localize(7380, "You trust this window"));
693
671
  case WorkbenchState.FOLDER:
694
- return ( localizeWithPath(_moduleId, 25, "You trust this folder"));
672
+ return ( localize(7381, "You trust this folder"));
695
673
  case WorkbenchState.WORKSPACE:
696
- return ( localizeWithPath(_moduleId, 26, "You trust this workspace"));
674
+ return ( localize(7382, "You trust this workspace"));
697
675
  }
698
676
  }
699
- return ( localizeWithPath(_moduleId, 27, "You are in Restricted Mode"));
677
+ return ( localize(7383, "You are in Restricted Mode"));
700
678
  }
701
679
  getHeaderTitleIconClassNames(trusted) {
702
680
  return ThemeIcon.asClassNameArray(shieldIcon);
@@ -706,43 +684,37 @@ let WorkspaceTrustEditor = class WorkspaceTrustEditor extends EditorPane {
706
684
  let subTitle = '';
707
685
  switch (this.workspaceService.getWorkbenchState()) {
708
686
  case WorkbenchState.EMPTY: {
709
- title = trusted ? ( localizeWithPath(_moduleId, 28, "In a Trusted Window")) : ( localizeWithPath(_moduleId, 29, "In Restricted Mode"));
710
- subTitle = trusted ? ( localizeWithPath(
711
- _moduleId,
712
- 30,
687
+ title = trusted ? ( localize(7384, "In a Trusted Window")) : ( localize(7385, "In Restricted Mode"));
688
+ subTitle = trusted ? ( localize(
689
+ 7386,
713
690
  "You trust the authors of the files in the current window. All features are enabled:"
714
691
  )) :
715
- ( localizeWithPath(
716
- _moduleId,
717
- 31,
692
+ ( localize(
693
+ 7387,
718
694
  "You do not trust the authors of the files in the current window. The following features are disabled:"
719
695
  ));
720
696
  break;
721
697
  }
722
698
  case WorkbenchState.FOLDER: {
723
- title = trusted ? ( localizeWithPath(_moduleId, 32, "In a Trusted Folder")) : ( localizeWithPath(_moduleId, 29, "In Restricted Mode"));
724
- subTitle = trusted ? ( localizeWithPath(
725
- _moduleId,
726
- 33,
699
+ title = trusted ? ( localize(7388, "In a Trusted Folder")) : ( localize(7388, "In Restricted Mode"));
700
+ subTitle = trusted ? ( localize(
701
+ 7389,
727
702
  "You trust the authors of the files in the current folder. All features are enabled:"
728
703
  )) :
729
- ( localizeWithPath(
730
- _moduleId,
731
- 34,
704
+ ( localize(
705
+ 7390,
732
706
  "You do not trust the authors of the files in the current folder. The following features are disabled:"
733
707
  ));
734
708
  break;
735
709
  }
736
710
  case WorkbenchState.WORKSPACE: {
737
- title = trusted ? ( localizeWithPath(_moduleId, 35, "In a Trusted Workspace")) : ( localizeWithPath(_moduleId, 29, "In Restricted Mode"));
738
- subTitle = trusted ? ( localizeWithPath(
739
- _moduleId,
740
- 36,
711
+ title = trusted ? ( localize(7391, "In a Trusted Workspace")) : ( localize(7391, "In Restricted Mode"));
712
+ subTitle = trusted ? ( localize(
713
+ 7392,
741
714
  "You trust the authors of the files in the current workspace. All features are enabled:"
742
715
  )) :
743
- ( localizeWithPath(
744
- _moduleId,
745
- 37,
716
+ ( localize(
717
+ 7393,
746
718
  "You do not trust the authors of the files in the current workspace. The following features are disabled:"
747
719
  ));
748
720
  break;
@@ -765,21 +737,18 @@ let WorkspaceTrustEditor = class WorkspaceTrustEditor extends EditorPane {
765
737
  this.headerDescription.innerText = '';
766
738
  const headerDescriptionText = append(this.headerDescription, $('div'));
767
739
  headerDescriptionText.innerText = isWorkspaceTrusted ?
768
- ( localizeWithPath(
769
- _moduleId,
770
- 38,
740
+ ( localize(
741
+ 7394,
771
742
  "All features are enabled because trust has been granted to the workspace."
772
743
  )) :
773
- ( localizeWithPath(
774
- _moduleId,
775
- 39,
744
+ ( localize(
745
+ 7395,
776
746
  "{0} is in a restricted mode intended for safe code browsing.",
777
747
  this.productService.nameShort
778
748
  ));
779
749
  const headerDescriptionActions = append(this.headerDescription, $('div'));
780
- const headerDescriptionActionsText = ( localizeWithPath(
781
- _moduleId,
782
- 40,
750
+ const headerDescriptionActionsText = ( localize(
751
+ 7396,
783
752
  "[Configure your settings]({0}) or [learn more](https://aka.ms/vscode-workspace-trust).",
784
753
  `command:workbench.trust.configure`
785
754
  ));
@@ -792,7 +761,7 @@ let WorkspaceTrustEditor = class WorkspaceTrustEditor extends EditorPane {
792
761
  }
793
762
  }
794
763
  this.headerContainer.className = this.getHeaderContainerClass(isWorkspaceTrusted);
795
- this.rootElement.setAttribute('aria-label', `${( localizeWithPath(_moduleId, 41, "Manage Workspace Trust"))}: ${this.headerContainer.innerText}`);
764
+ this.rootElement.setAttribute('aria-label', `${( localize(7397, "Manage Workspace Trust"))}: ${this.headerContainer.innerText}`);
796
765
  const restrictedSettings = this.configurationService.restrictedSettings;
797
766
  const configurationRegistry = ( (Registry.as(Extensions.Configuration)));
798
767
  const settingsRequiringTrustedWorkspaceCount = restrictedSettings.default.filter(key => {
@@ -857,7 +826,7 @@ let WorkspaceTrustEditor = class WorkspaceTrustEditor extends EditorPane {
857
826
  createConfigurationElement(parent) {
858
827
  this.configurationContainer = append(parent, $('.workspace-trust-settings', { tabIndex: '0' }));
859
828
  const configurationTitle = append(this.configurationContainer, $('.workspace-trusted-folders-title'));
860
- configurationTitle.innerText = ( localizeWithPath(_moduleId, 10, "Trusted Folders & Workspaces"));
829
+ configurationTitle.innerText = ( localize(7397, "Trusted Folders & Workspaces"));
861
830
  this.workspaceTrustedUrisTable = this._register(this.instantiationService.createInstance(WorkspaceTrustedUrisTable, this.configurationContainer));
862
831
  }
863
832
  createAffectedFeaturesElement(parent) {
@@ -872,44 +841,41 @@ let WorkspaceTrustEditor = class WorkspaceTrustEditor extends EditorPane {
872
841
  this.renderLimitationsHeaderElement(this.trustedContainer, trustedTitle, trustedSubTitle);
873
842
  const trustedContainerItems = this.workspaceService.getWorkbenchState() === WorkbenchState.EMPTY ?
874
843
  [
875
- ( localizeWithPath(_moduleId, 42, "Tasks are allowed to run")),
876
- ( localizeWithPath(_moduleId, 43, "Debugging is enabled")),
877
- ( localizeWithPath(_moduleId, 44, "All enabled extensions are activated"))
844
+ ( localize(7398, "Tasks are allowed to run")),
845
+ ( localize(7399, "Debugging is enabled")),
846
+ ( localize(7400, "All enabled extensions are activated"))
878
847
  ] :
879
848
  [
880
- ( localizeWithPath(_moduleId, 42, "Tasks are allowed to run")),
881
- ( localizeWithPath(_moduleId, 43, "Debugging is enabled")),
882
- ( localizeWithPath(_moduleId, 45, "All workspace settings are applied")),
883
- ( localizeWithPath(_moduleId, 44, "All enabled extensions are activated"))
849
+ ( localize(7400, "Tasks are allowed to run")),
850
+ ( localize(7400, "Debugging is enabled")),
851
+ ( localize(7401, "All workspace settings are applied")),
852
+ ( localize(7401, "All enabled extensions are activated"))
884
853
  ];
885
854
  this.renderLimitationsListElement(this.trustedContainer, trustedContainerItems, ThemeIcon.asClassNameArray(checkListIcon));
886
855
  const [untrustedTitle, untrustedSubTitle] = this.getFeaturesHeaderText(false);
887
856
  this.renderLimitationsHeaderElement(this.untrustedContainer, untrustedTitle, untrustedSubTitle);
888
857
  const untrustedContainerItems = this.workspaceService.getWorkbenchState() === WorkbenchState.EMPTY ?
889
858
  [
890
- ( localizeWithPath(_moduleId, 46, "Tasks are not allowed to run")),
891
- ( localizeWithPath(_moduleId, 47, "Debugging is disabled")),
892
- fixBadLocalizedLinks(( localizeWithPath(
893
- _moduleId,
894
- 48,
859
+ ( localize(7402, "Tasks are not allowed to run")),
860
+ ( localize(7403, "Debugging is disabled")),
861
+ fixBadLocalizedLinks(( localize(
862
+ 7404,
895
863
  "[{0} extensions]({1}) are disabled or have limited functionality",
896
864
  numExtensions,
897
865
  `command:${LIST_WORKSPACE_UNSUPPORTED_EXTENSIONS_COMMAND_ID}`
898
866
  )))
899
867
  ] :
900
868
  [
901
- ( localizeWithPath(_moduleId, 46, "Tasks are not allowed to run")),
902
- ( localizeWithPath(_moduleId, 47, "Debugging is disabled")),
903
- fixBadLocalizedLinks(numSettings ? ( localizeWithPath(
904
- _moduleId,
905
- 49,
869
+ ( localize(7404, "Tasks are not allowed to run")),
870
+ ( localize(7404, "Debugging is disabled")),
871
+ fixBadLocalizedLinks(numSettings ? ( localize(
872
+ 7405,
906
873
  "[{0} workspace settings]({1}) are not applied",
907
874
  numSettings,
908
875
  'command:settings.filterUntrusted'
909
- )) : ( localizeWithPath(_moduleId, 50, "Workspace settings requiring trust are not applied"))),
910
- fixBadLocalizedLinks(( localizeWithPath(
911
- _moduleId,
912
- 48,
876
+ )) : ( localize(7406, "Workspace settings requiring trust are not applied"))),
877
+ fixBadLocalizedLinks(( localize(
878
+ 7406,
913
879
  "[{0} extensions]({1}) are disabled or have limited functionality",
914
880
  numExtensions,
915
881
  `command:${LIST_WORKSPACE_UNSUPPORTED_EXTENSIONS_COMMAND_ID}`
@@ -939,7 +905,7 @@ let WorkspaceTrustEditor = class WorkspaceTrustEditor extends EditorPane {
939
905
  button.label = action.label;
940
906
  button.enabled = enabled !== undefined ? enabled : action.enabled;
941
907
  button.description = keybinding.getLabel();
942
- button.element.ariaLabel = action.label + ', ' + ( localizeWithPath(_moduleId, 51, "Keyboard Shortcut: {0}", keybinding.getAriaLabel()));
908
+ button.element.ariaLabel = action.label + ', ' + ( localize(7407, "Keyboard Shortcut: {0}", keybinding.getAriaLabel()));
943
909
  this.rerenderDisposables.add(button.onDidClick(e => {
944
910
  if (e) {
945
911
  EventHelper.stop(e, true);
@@ -949,7 +915,7 @@ let WorkspaceTrustEditor = class WorkspaceTrustEditor extends EditorPane {
949
915
  }
950
916
  }
951
917
  addTrustButtonToElement(parent) {
952
- const trustAction = ( (new Action('workspace.trust.button.action.grant', ( localizeWithPath(_moduleId, 52, "Trust")), undefined, true, async () => {
918
+ const trustAction = ( (new Action('workspace.trust.button.action.grant', ( localize(7408, "Trust")), undefined, true, async () => {
953
919
  await this.workspaceTrustManagementService.setWorkspaceTrust(true);
954
920
  })));
955
921
  const trustActions = [{ action: trustAction, keybinding: this.keybindingService.resolveUserBinding(isMacintosh ? 'Cmd+Enter' : 'Ctrl+Enter')[0] }];
@@ -957,13 +923,12 @@ let WorkspaceTrustEditor = class WorkspaceTrustEditor extends EditorPane {
957
923
  const workspaceIdentifier = toWorkspaceIdentifier(this.workspaceService.getWorkspace());
958
924
  const name = basename(dirname(workspaceIdentifier.uri));
959
925
  const trustMessageElement = append(parent, $('.trust-message-box'));
960
- trustMessageElement.innerText = ( localizeWithPath(
961
- _moduleId,
962
- 53,
926
+ trustMessageElement.innerText = ( localize(
927
+ 7409,
963
928
  "Trust the authors of all files in the current folder or its parent '{0}'.",
964
929
  name
965
930
  ));
966
- const trustParentAction = ( (new Action('workspace.trust.button.action.grantParent', ( localizeWithPath(_moduleId, 54, "Trust Parent")), undefined, true, async () => {
931
+ const trustParentAction = ( (new Action('workspace.trust.button.action.grantParent', ( localize(7410, "Trust Parent")), undefined, true, async () => {
967
932
  await this.workspaceTrustManagementService.setParentFolderTrust(true);
968
933
  })));
969
934
  trustActions.push({ action: trustParentAction, keybinding: this.keybindingService.resolveUserBinding(isMacintosh ? 'Cmd+Shift+Enter' : 'Ctrl+Shift+Enter')[0] });
@@ -972,7 +937,7 @@ let WorkspaceTrustEditor = class WorkspaceTrustEditor extends EditorPane {
972
937
  }
973
938
  addDontTrustButtonToElement(parent) {
974
939
  this.createButtonRow(parent, [{
975
- action: ( (new Action('workspace.trust.button.action.deny', ( localizeWithPath(_moduleId, 55, "Don't Trust")), undefined, true, async () => {
940
+ action: ( (new Action('workspace.trust.button.action.deny', ( localize(7411, "Don't Trust")), undefined, true, async () => {
976
941
  await this.workspaceTrustManagementService.setWorkspaceTrust(false);
977
942
  }))),
978
943
  keybinding: this.keybindingService.resolveUserBinding(isMacintosh ? 'Cmd+Enter' : 'Ctrl+Enter')[0]
@@ -984,22 +949,16 @@ let WorkspaceTrustEditor = class WorkspaceTrustEditor extends EditorPane {
984
949
  }
985
950
  const textElement = append(parent, $('.workspace-trust-untrusted-description'));
986
951
  if (!this.workspaceTrustManagementService.isWorkspaceTrustForced()) {
987
- textElement.innerText = this.workspaceService.getWorkbenchState() === WorkbenchState.WORKSPACE ? ( localizeWithPath(
988
- _moduleId,
989
- 56,
952
+ textElement.innerText = this.workspaceService.getWorkbenchState() === WorkbenchState.WORKSPACE ? ( localize(
953
+ 7412,
990
954
  "This workspace is trusted via the bolded entries in the trusted folders below."
991
- )) : ( localizeWithPath(
992
- _moduleId,
993
- 57,
955
+ )) : ( localize(
956
+ 7413,
994
957
  "This folder is trusted via the bolded entries in the the trusted folders below."
995
958
  ));
996
959
  }
997
960
  else {
998
- textElement.innerText = ( localizeWithPath(
999
- _moduleId,
1000
- 58,
1001
- "This window is trusted by nature of the workspace that is opened."
1002
- ));
961
+ textElement.innerText = ( localize(7414, "This window is trusted by nature of the workspace that is opened."));
1003
962
  }
1004
963
  }
1005
964
  renderLimitationsHeaderElement(parent, headerText, subtitleText) {
@@ -1,13 +1,12 @@
1
1
  import { Codicon } from 'vscode/vscode/vs/base/common/codicons';
2
2
  import { Schemas } from 'vscode/vscode/vs/base/common/network';
3
3
  import { URI } from 'vscode/vscode/vs/base/common/uri';
4
- import { localizeWithPath } from 'vscode/vscode/vs/nls';
4
+ import { localize } from 'vscode/vscode/vs/nls';
5
5
  import { registerIcon } from 'vscode/vscode/vs/platform/theme/common/iconRegistry';
6
6
  import { EditorInputCapabilities } from 'vscode/vscode/vs/workbench/common/editor';
7
7
  import { EditorInput } from 'vscode/vscode/vs/workbench/common/editor/editorInput';
8
8
 
9
- const _moduleId = "vs/workbench/services/workspaces/browser/workspaceTrustEditorInput";
10
- const WorkspaceTrustEditorIcon = registerIcon('workspace-trust-editor-label-icon', Codicon.shield, ( localizeWithPath(_moduleId, 0, 'Icon of the workspace trust editor label.')));
9
+ const WorkspaceTrustEditorIcon = registerIcon('workspace-trust-editor-label-icon', Codicon.shield, ( localize(7415, 'Icon of the workspace trust editor label.')));
11
10
  class WorkspaceTrustEditorInput extends EditorInput {
12
11
  constructor() {
13
12
  super(...arguments);
@@ -27,7 +26,7 @@ class WorkspaceTrustEditorInput extends EditorInput {
27
26
  return super.matches(otherInput) || otherInput instanceof WorkspaceTrustEditorInput;
28
27
  }
29
28
  getName() {
30
- return ( localizeWithPath(_moduleId, 1, "Workspace Trust"));
29
+ return ( localize(7416, "Workspace Trust"));
31
30
  }
32
31
  getIcon() {
33
32
  return WorkspaceTrustEditorIcon;