@codingame/monaco-vscode-workspace-trust-service-override 2.0.3 → 2.1.0

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": "2.0.3",
3
+ "version": "2.1.0",
4
4
  "keywords": [],
5
5
  "author": {
6
6
  "name": "CodinGame",
@@ -18,7 +18,7 @@
18
18
  "module": "index.js",
19
19
  "types": "index.d.ts",
20
20
  "dependencies": {
21
- "vscode": "npm:@codingame/monaco-vscode-api@2.0.3",
21
+ "vscode": "npm:@codingame/monaco-vscode-api@2.1.0",
22
22
  "vscode-marked": "npm:marked@=3.0.2"
23
23
  }
24
24
  }
@@ -1,6 +1,6 @@
1
1
  import n from '../../../../../../../../external/rollup-plugin-styles/dist/runtime/inject-css.js';
2
2
 
3
- var css = ".monaco-icon-label.file-icon.workspacetrusteditor-name-file-icon.ext-file-icon.tab-label:before{background-image:none;content:\"\\eb53\";font-family:codicon;font-size:16px}.workspace-trust-editor{height:calc(100% - 11px);margin:auto;max-width:1000px;padding-top:11px}.workspace-trust-editor:focus{outline:none!important}.workspace-trust-editor>.workspace-trust-header{align-items:center;display:flex;flex-direction:column;padding:14px}.workspace-trust-editor .workspace-trust-header .workspace-trust-title{display:flex;font-size:24px;font-weight:600;line-height:32px;padding:10px 0}.workspace-trust-editor .workspace-trust-header .workspace-trust-title .workspace-trust-title-icon{color:var(--workspace-trust-selected-color)!important;font-size:32px;margin-right:8px}.workspace-trust-editor .workspace-trust-header .workspace-trust-description{cursor:default;max-width:600px;padding:14px 0;text-align:center;user-select:text}.workspace-trust-editor .workspace-trust-section-title{font-size:18px;font-weight:600;padding-bottom:5px}.workspace-trust-editor .workspace-trust-subsection-title{font-size:16px;font-weight:600;line-height:32px}.workspace-trust-editor .workspace-trust-editor-body{height:100%}.workspace-trust-editor .workspace-trust-features{cursor:default;display:flex;flex-direction:row;flex-flow:wrap;justify-content:space-evenly;padding:14px;user-select:text}.workspace-trust-editor .workspace-trust-features .workspace-trust-limitations{border:1px solid var(--workspace-trust-unselected-color);display:flex;flex-direction:column;margin:4px;min-height:315px;padding:10px 40px}.workspace-trust-editor.trusted .workspace-trust-features .workspace-trust-limitations.trusted,.workspace-trust-editor.untrusted .workspace-trust-features .workspace-trust-limitations.untrusted{border-color:var(--workspace-trust-selected-color)!important;border-width:2px;outline-offset:2px;padding:9px 39px}.workspace-trust-editor .workspace-trust-features .workspace-trust-limitations ul{list-style:none;padding-inline-start:0}.workspace-trust-editor .workspace-trust-features .workspace-trust-limitations li{display:flex;padding-bottom:10px}.workspace-trust-editor .workspace-trust-features .workspace-trust-limitations .list-item-icon{line-height:24px;padding-right:5px}.workspace-trust-editor .workspace-trust-features .workspace-trust-limitations.trusted .list-item-icon{color:var(--workspace-trust-check-color)!important;font-size:18px}.workspace-trust-editor .workspace-trust-features .workspace-trust-limitations.untrusted .list-item-icon{color:var(--workspace-trust-x-color)!important;font-size:20px}.workspace-trust-editor .workspace-trust-features .workspace-trust-limitations .list-item-text{font-size:16px;line-height:24px}.workspace-trust-editor .workspace-trust-features .workspace-trust-limitations-header{align-items:center;display:flex;flex-direction:column}.workspace-trust-editor .workspace-trust-features .workspace-trust-limitations-header .workspace-trust-limitations-title{display:flex;font-size:16px;font-weight:600;line-height:24px;padding:10px 0}.workspace-trust-editor .workspace-trust-features .workspace-trust-limitations-header .workspace-trust-limitations-title .workspace-trust-title-icon{display:none;font-size:24px;margin-right:8px}.workspace-trust-editor.trusted .workspace-trust-features .workspace-trust-limitations.trusted .workspace-trust-limitations-header .workspace-trust-limitations-title .workspace-trust-title-icon,.workspace-trust-editor.untrusted .workspace-trust-features .workspace-trust-limitations.untrusted .workspace-trust-limitations-header .workspace-trust-limitations-title .workspace-trust-title-icon{color:var(--workspace-trust-selected-color)!important;display:unset}.workspace-trust-editor .workspace-trust-features .workspace-trust-untrusted-description{font-style:italic;padding-bottom:10px}.workspace-trust-editor .workspace-trust-features .workspace-trust-buttons-row{align-items:center;display:flex;justify-content:center;margin-top:auto;overflow:hidden;padding:5px 0 10px;white-space:nowrap}.workspace-trust-editor .workspace-trust-features .workspace-trust-buttons-row .workspace-trust-buttons,.workspace-trust-editor .workspace-trust-settings .trusted-uris-button-bar{display:flex;overflow:hidden}.workspace-trust-editor .workspace-trust-settings .trusted-uris-button-bar{margin-top:5px}.workspace-trust-editor .workspace-trust-settings .trusted-uris-button-bar .monaco-button{outline-offset:2px!important;overflow:hidden;padding:5px 10px;text-overflow:ellipsis;width:fit-content}.workspace-trust-editor .workspace-trust-features .workspace-trust-buttons-row .workspace-trust-buttons>.monaco-button,.workspace-trust-editor .workspace-trust-features .workspace-trust-buttons-row .workspace-trust-buttons>.monaco-button-dropdown,.workspace-trust-editor .workspace-trust-settings .trusted-uris-button-bar .monaco-button{margin:4px 5px}.workspace-trust-editor .workspace-trust-features .workspace-trust-buttons-row .workspace-trust-buttons .monaco-button-dropdown .monaco-dropdown-button{padding:5px}.workspace-trust-limitations{flex:1;max-width:350px;min-width:250px;width:50%}.workspace-trust-intro-dialog{min-width:min(50vw,500px);padding-right:24px}.workspace-trust-intro-dialog .workspace-trust-dialog-image-row p{align-items:center;display:flex}.workspace-trust-intro-dialog .workspace-trust-dialog-image-row.badge-row img{max-height:40px;padding-right:10px}.workspace-trust-intro-dialog .workspace-trust-dialog-image-row.status-bar img{max-height:32px;padding-right:10px}.workspace-trust-editor .workspace-trust-settings{padding:20px 14px}.workspace-trust-editor .workspace-trust-settings .workspace-trusted-folders-title{font-weight:600}.workspace-trust-editor .empty>.trusted-uris-table{display:none}.workspace-trust-editor .monaco-table-tr .monaco-table-td .path{width:100%}.workspace-trust-editor .monaco-table-tr .monaco-table-td .path.input-mode .path-label,.workspace-trust-editor .monaco-table-tr .monaco-table-td .path:not(.input-mode) .monaco-inputbox{display:none}.workspace-trust-editor .monaco-table-tr .monaco-table-td .current-workspace-parent .host-label,.workspace-trust-editor .monaco-table-tr .monaco-table-td .current-workspace-parent .path-label{font-style:italic;font-weight:700}.workspace-trust-editor .monaco-table-td,.workspace-trust-editor .monaco-table-th{padding-left:5px}.workspace-trust-editor .workspace-trust-settings .monaco-action-bar .action-item>.codicon{align-items:center;color:inherit;display:flex;justify-content:center}.workspace-trust-editor .workspace-trust-settings .monaco-table-tr .monaco-table-td{align-items:center;display:flex;overflow:hidden}.workspace-trust-editor .workspace-trust-settings .monaco-table-tr .monaco-table-td .host,.workspace-trust-editor .workspace-trust-settings .monaco-table-tr .monaco-table-td .path{max-width:100%}.workspace-trust-editor .workspace-trust-settings .monaco-table-tr .monaco-table-td .actions{width:100%}.workspace-trust-editor .workspace-trust-settings .monaco-table-tr .monaco-table-td .actions .actions-container{justify-content:flex-end;padding-right:3px}.workspace-trust-editor .workspace-trust-settings .monaco-table-tr .monaco-table-td .monaco-button{height:18px;padding-left:8px;padding-right:8px}.workspace-trust-editor .workspace-trust-settings .monaco-table-tr .monaco-table-td .actions .monaco-action-bar{display:none;flex:1}.workspace-trust-editor .workspace-trust-settings .monaco-list-row.selected .monaco-table-tr .monaco-table-td .actions .monaco-action-bar,.workspace-trust-editor .workspace-trust-settings .monaco-list-row:hover .monaco-table-tr .monaco-table-td .actions .monaco-action-bar,.workspace-trust-editor .workspace-trust-settings .monaco-table .monaco-list-row.focused .monaco-table-tr .monaco-table-td .actions .monaco-action-bar{display:flex}";
3
+ var css = ".workspace-trust-editor{height:calc(100% - 11px);margin:auto;max-width:1000px;padding-top:11px}.workspace-trust-editor:focus{outline:none!important}.workspace-trust-editor>.workspace-trust-header{align-items:center;display:flex;flex-direction:column;padding:14px}.workspace-trust-editor .workspace-trust-header .workspace-trust-title{display:flex;font-size:24px;font-weight:600;line-height:32px;padding:10px 0}.workspace-trust-editor .workspace-trust-header .workspace-trust-title .workspace-trust-title-icon{color:var(--workspace-trust-selected-color)!important;font-size:32px;margin-right:8px}.workspace-trust-editor .workspace-trust-header .workspace-trust-description{cursor:default;max-width:600px;padding:14px 0;text-align:center;user-select:text}.workspace-trust-editor .workspace-trust-section-title{font-size:18px;font-weight:600;padding-bottom:5px}.workspace-trust-editor .workspace-trust-subsection-title{font-size:16px;font-weight:600;line-height:32px}.workspace-trust-editor .workspace-trust-editor-body{height:100%}.workspace-trust-editor .workspace-trust-features{cursor:default;display:flex;flex-direction:row;flex-flow:wrap;justify-content:space-evenly;padding:14px;user-select:text}.workspace-trust-editor .workspace-trust-features .workspace-trust-limitations{border:1px solid var(--workspace-trust-unselected-color);display:flex;flex-direction:column;margin:4px;min-height:315px;padding:10px 40px}.workspace-trust-editor.trusted .workspace-trust-features .workspace-trust-limitations.trusted,.workspace-trust-editor.untrusted .workspace-trust-features .workspace-trust-limitations.untrusted{border-color:var(--workspace-trust-selected-color)!important;border-width:2px;outline-offset:2px;padding:9px 39px}.workspace-trust-editor .workspace-trust-features .workspace-trust-limitations ul{list-style:none;padding-inline-start:0}.workspace-trust-editor .workspace-trust-features .workspace-trust-limitations li{display:flex;padding-bottom:10px}.workspace-trust-editor .workspace-trust-features .workspace-trust-limitations .list-item-icon{line-height:24px;padding-right:5px}.workspace-trust-editor .workspace-trust-features .workspace-trust-limitations.trusted .list-item-icon{color:var(--workspace-trust-check-color)!important;font-size:18px}.workspace-trust-editor .workspace-trust-features .workspace-trust-limitations.untrusted .list-item-icon{color:var(--workspace-trust-x-color)!important;font-size:20px}.workspace-trust-editor .workspace-trust-features .workspace-trust-limitations .list-item-text{font-size:16px;line-height:24px}.workspace-trust-editor .workspace-trust-features .workspace-trust-limitations-header{align-items:center;display:flex;flex-direction:column}.workspace-trust-editor .workspace-trust-features .workspace-trust-limitations-header .workspace-trust-limitations-title{display:flex;font-size:16px;font-weight:600;line-height:24px;padding:10px 0}.workspace-trust-editor .workspace-trust-features .workspace-trust-limitations-header .workspace-trust-limitations-title .workspace-trust-title-icon{display:none;font-size:24px;margin-right:8px}.workspace-trust-editor.trusted .workspace-trust-features .workspace-trust-limitations.trusted .workspace-trust-limitations-header .workspace-trust-limitations-title .workspace-trust-title-icon,.workspace-trust-editor.untrusted .workspace-trust-features .workspace-trust-limitations.untrusted .workspace-trust-limitations-header .workspace-trust-limitations-title .workspace-trust-title-icon{color:var(--workspace-trust-selected-color)!important;display:unset}.workspace-trust-editor .workspace-trust-features .workspace-trust-untrusted-description{font-style:italic;padding-bottom:10px}.workspace-trust-editor .workspace-trust-features .workspace-trust-buttons-row{align-items:center;display:flex;justify-content:center;margin-top:auto;overflow:hidden;padding:5px 0 10px;white-space:nowrap}.workspace-trust-editor .workspace-trust-features .workspace-trust-buttons-row .workspace-trust-buttons,.workspace-trust-editor .workspace-trust-settings .trusted-uris-button-bar{display:flex;overflow:hidden}.workspace-trust-editor .workspace-trust-settings .trusted-uris-button-bar{margin-top:5px}.workspace-trust-editor .workspace-trust-settings .trusted-uris-button-bar .monaco-button{outline-offset:2px!important;overflow:hidden;padding:5px 10px;text-overflow:ellipsis;width:fit-content}.workspace-trust-editor .workspace-trust-features .workspace-trust-buttons-row .workspace-trust-buttons>.monaco-button,.workspace-trust-editor .workspace-trust-features .workspace-trust-buttons-row .workspace-trust-buttons>.monaco-button-dropdown,.workspace-trust-editor .workspace-trust-settings .trusted-uris-button-bar .monaco-button{margin:4px 5px}.workspace-trust-editor .workspace-trust-features .workspace-trust-buttons-row .workspace-trust-buttons .monaco-button-dropdown .monaco-dropdown-button{padding:5px}.workspace-trust-limitations{flex:1;max-width:350px;min-width:250px;width:50%}.workspace-trust-intro-dialog{min-width:min(50vw,500px);padding-right:24px}.workspace-trust-intro-dialog .workspace-trust-dialog-image-row p{align-items:center;display:flex}.workspace-trust-intro-dialog .workspace-trust-dialog-image-row.badge-row img{max-height:40px;padding-right:10px}.workspace-trust-intro-dialog .workspace-trust-dialog-image-row.status-bar img{max-height:32px;padding-right:10px}.workspace-trust-editor .workspace-trust-settings{padding:20px 14px}.workspace-trust-editor .workspace-trust-settings .workspace-trusted-folders-title{font-weight:600}.workspace-trust-editor .empty>.trusted-uris-table{display:none}.workspace-trust-editor .monaco-table-tr .monaco-table-td .path{width:100%}.workspace-trust-editor .monaco-table-tr .monaco-table-td .path.input-mode .path-label,.workspace-trust-editor .monaco-table-tr .monaco-table-td .path:not(.input-mode) .monaco-inputbox{display:none}.workspace-trust-editor .monaco-table-tr .monaco-table-td .current-workspace-parent .host-label,.workspace-trust-editor .monaco-table-tr .monaco-table-td .current-workspace-parent .path-label{font-style:italic;font-weight:700}.workspace-trust-editor .monaco-table-td,.workspace-trust-editor .monaco-table-th{padding-left:5px}.workspace-trust-editor .workspace-trust-settings .monaco-action-bar .action-item>.codicon{align-items:center;color:inherit;display:flex;justify-content:center}.workspace-trust-editor .workspace-trust-settings .monaco-table-tr .monaco-table-td{align-items:center;display:flex;overflow:hidden}.workspace-trust-editor .workspace-trust-settings .monaco-table-tr .monaco-table-td .host,.workspace-trust-editor .workspace-trust-settings .monaco-table-tr .monaco-table-td .path{max-width:100%}.workspace-trust-editor .workspace-trust-settings .monaco-table-tr .monaco-table-td .actions{width:100%}.workspace-trust-editor .workspace-trust-settings .monaco-table-tr .monaco-table-td .actions .actions-container{justify-content:flex-end;padding-right:3px}.workspace-trust-editor .workspace-trust-settings .monaco-table-tr .monaco-table-td .monaco-button{height:18px;padding-left:8px;padding-right:8px}.workspace-trust-editor .workspace-trust-settings .monaco-table-tr .monaco-table-td .actions .monaco-action-bar{display:none;flex:1}.workspace-trust-editor .workspace-trust-settings .monaco-list-row.selected .monaco-table-tr .monaco-table-td .actions .monaco-action-bar,.workspace-trust-editor .workspace-trust-settings .monaco-list-row:hover .monaco-table-tr .monaco-table-td .actions .monaco-action-bar,.workspace-trust-editor .workspace-trust-settings .monaco-table .monaco-list-row.focused .monaco-table-tr .monaco-table-td .actions .monaco-action-bar{display:flex}";
4
4
  n(css,{});
5
5
 
6
6
  export { css, css as default };
@@ -2,7 +2,7 @@ import { __decorate, __param } from '../../../../../../../external/tslib/tslib.e
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 } from 'vscode/vscode/vs/nls';
5
+ import { localizeWithPath, localize2WithPath } 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 } from 'vscode/vscode/vs/platform/configuration/common/configurationRegistry';
8
8
  import '../../../../../../../override/vs/platform/dialogs/common/dialogs.js';
@@ -742,11 +742,11 @@ class WorkspaceTrustEditorInputSerializer {
742
742
  ( new SyncDescriptor(WorkspaceTrustEditorInput))
743
743
  ]);
744
744
  const CONFIGURE_TRUST_COMMAND_ID = 'workbench.trust.configure';
745
- const WORKSPACES_CATEGORY = { value: ( localizeWithPath(
745
+ const WORKSPACES_CATEGORY = ( localize2WithPath(
746
746
  'vs/workbench/contrib/workspace/browser/workspace.contribution',
747
747
  'workspacesCategory',
748
- "Workspaces"
749
- )), original: 'Workspaces' };
748
+ 'Workspaces'
749
+ ));
750
750
  registerAction2(class extends Action2 {
751
751
  constructor() {
752
752
  super({
@@ -166,6 +166,11 @@ let WorkspaceTrustedUrisTable = class WorkspaceTrustedUrisTable extends Disposab
166
166
  'trustedFoldersAndWorkspaces',
167
167
  "Trusted Folders & Workspaces"
168
168
  ))
169
+ },
170
+ identityProvider: {
171
+ getId(element) {
172
+ return ( element.uri.toString());
173
+ },
169
174
  }
170
175
  });
171
176
  this._register(this.table.onDidOpen(item => {
@@ -351,8 +356,13 @@ let WorkspaceTrustedUrisTable = class WorkspaceTrustedUrisTable extends Disposab
351
356
  this._onDidRejectEdit.fire(item);
352
357
  }
353
358
  async delete(item) {
359
+ this.table.focusNext();
354
360
  await this.workspaceTrustManagementService.setUrisTrust([item.uri], false);
361
+ if (this.table.getFocus().length === 0) {
362
+ this.table.focusLast();
363
+ }
355
364
  this._onDelete.fire(item);
365
+ this.table.domFocus();
356
366
  }
357
367
  async edit(item, usePickerIfPossible) {
358
368
  const canUseOpenDialog = item.uri.scheme === Schemas.file ||
@@ -1,8 +1,15 @@
1
+ import { Codicon } from 'vscode/vscode/vs/base/common/codicons';
1
2
  import { Schemas } from 'vscode/vscode/vs/base/common/network';
2
3
  import { URI } from 'vscode/vscode/vs/base/common/uri';
3
4
  import { localizeWithPath } from 'vscode/vscode/vs/nls';
5
+ import { registerIcon } from 'vscode/vscode/vs/platform/theme/common/iconRegistry';
4
6
  import { EditorInput } from 'vscode/vscode/vs/workbench/common/editor/editorInput';
5
7
 
8
+ const WorkspaceTrustEditorIcon = registerIcon('workspace-trust-editor-label-icon', Codicon.shield, ( localizeWithPath(
9
+ 'vs/workbench/services/workspaces/browser/workspaceTrustEditorInput',
10
+ 'workspaceTrustEditorLabelIcon',
11
+ 'Icon of the workspace trust editor label.'
12
+ )));
6
13
  class WorkspaceTrustEditorInput extends EditorInput {
7
14
  constructor() {
8
15
  super(...arguments);
@@ -28,6 +35,9 @@ class WorkspaceTrustEditorInput extends EditorInput {
28
35
  "Workspace Trust"
29
36
  ));
30
37
  }
38
+ getIcon() {
39
+ return WorkspaceTrustEditorIcon;
40
+ }
31
41
  }
32
42
 
33
43
  export { WorkspaceTrustEditorInput };