@theia/variable-resolver 1.67.0-next.13 → 1.67.0-next.56
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/README.md +2 -11
- package/package.json +3 -3
- package/lib/browser/common-variable-contribution.d.ts +0 -17
- package/lib/browser/common-variable-contribution.d.ts.map +0 -1
- package/lib/browser/common-variable-contribution.js +0 -162
- package/lib/browser/common-variable-contribution.js.map +0 -1
- package/lib/browser/index.d.ts +0 -4
- package/lib/browser/index.d.ts.map +0 -1
- package/lib/browser/index.js +0 -22
- package/lib/browser/index.js.map +0 -1
- package/lib/browser/variable-input-schema.d.ts +0 -3
- package/lib/browser/variable-input-schema.d.ts.map +0 -1
- package/lib/browser/variable-input-schema.js +0 -131
- package/lib/browser/variable-input-schema.js.map +0 -1
- package/lib/browser/variable-input.d.ts +0 -21
- package/lib/browser/variable-input.d.ts.map +0 -1
- package/lib/browser/variable-input.js +0 -3
- package/lib/browser/variable-input.js.map +0 -1
- package/lib/browser/variable-quick-open-service.d.ts +0 -15
- package/lib/browser/variable-quick-open-service.d.ts.map +0 -1
- package/lib/browser/variable-quick-open-service.js +0 -70
- package/lib/browser/variable-quick-open-service.js.map +0 -1
- package/lib/browser/variable-resolver-frontend-contribution.d.ts +0 -14
- package/lib/browser/variable-resolver-frontend-contribution.d.ts.map +0 -1
- package/lib/browser/variable-resolver-frontend-contribution.js +0 -54
- package/lib/browser/variable-resolver-frontend-contribution.js.map +0 -1
- package/lib/browser/variable-resolver-frontend-contribution.spec.d.ts +0 -5
- package/lib/browser/variable-resolver-frontend-contribution.spec.d.ts.map +0 -1
- package/lib/browser/variable-resolver-frontend-contribution.spec.js +0 -83
- package/lib/browser/variable-resolver-frontend-contribution.spec.js.map +0 -1
- package/lib/browser/variable-resolver-frontend-module.d.ts +0 -4
- package/lib/browser/variable-resolver-frontend-module.d.ts.map +0 -1
- package/lib/browser/variable-resolver-frontend-module.js +0 -38
- package/lib/browser/variable-resolver-frontend-module.js.map +0 -1
- package/lib/browser/variable-resolver-service.d.ts +0 -51
- package/lib/browser/variable-resolver-service.d.ts.map +0 -1
- package/lib/browser/variable-resolver-service.js +0 -162
- package/lib/browser/variable-resolver-service.js.map +0 -1
- package/lib/browser/variable-resolver-service.spec.d.ts +0 -2
- package/lib/browser/variable-resolver-service.spec.d.ts.map +0 -1
- package/lib/browser/variable-resolver-service.spec.js +0 -76
- package/lib/browser/variable-resolver-service.spec.js.map +0 -1
- package/lib/browser/variable.d.ts +0 -56
- package/lib/browser/variable.d.ts.map +0 -1
- package/lib/browser/variable.js +0 -74
- package/lib/browser/variable.js.map +0 -1
- package/lib/browser/variable.spec.d.ts +0 -2
- package/lib/browser/variable.spec.d.ts.map +0 -1
- package/lib/browser/variable.spec.js +0 -91
- package/lib/browser/variable.spec.js.map +0 -1
- package/lib/common/variable-types.d.ts +0 -8
- package/lib/common/variable-types.d.ts.map +0 -1
- package/lib/common/variable-types.js +0 -18
- package/lib/common/variable-types.js.map +0 -1
package/README.md
CHANGED
|
@@ -89,13 +89,13 @@ export class MyService {
|
|
|
89
89
|
|
|
90
90
|
If `package.json` file is currently opened and cursor is on line 5 then the following output will be logged to the console:
|
|
91
91
|
|
|
92
|
-
```
|
|
92
|
+
```sh
|
|
93
93
|
cursor is in file package.json on line 5
|
|
94
94
|
```
|
|
95
95
|
|
|
96
96
|
## Additional Information
|
|
97
97
|
|
|
98
|
-
- [API documentation for `@theia/variable-resolver`](https://eclipse-theia.github.io/theia/docs/next/modules/
|
|
98
|
+
- [API documentation for `@theia/variable-resolver`](https://eclipse-theia.github.io/theia/docs/next/modules/_theia_variable-resolver.html)
|
|
99
99
|
- [Theia - GitHub](https://github.com/eclipse-theia/theia)
|
|
100
100
|
- [Theia - Website](https://theia-ide.org/)
|
|
101
101
|
|
|
@@ -108,12 +108,3 @@ cursor is in file package.json on line 5
|
|
|
108
108
|
|
|
109
109
|
"Theia" is a trademark of the Eclipse Foundation
|
|
110
110
|
<https://www.eclipse.org/theia>
|
|
111
|
-
|
|
112
|
-
# Theia - Variable Resolver Extension
|
|
113
|
-
|
|
114
|
-
The extension
|
|
115
|
-
|
|
116
|
-
## License
|
|
117
|
-
|
|
118
|
-
- [Eclipse Public License 2.0](http://www.eclipse.org/legal/epl-2.0/)
|
|
119
|
-
- [一 (Secondary) GNU General Public License, version 2 with the GNU Classpath Exception](https://projects.eclipse.org/license/secondary-gpl-2.0-cp)
|
package/package.json
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@theia/variable-resolver",
|
|
3
|
-
"version": "1.67.0-next.
|
|
3
|
+
"version": "1.67.0-next.56+d8f18cc386c",
|
|
4
4
|
"description": "Theia - Variable Resolver Extension",
|
|
5
5
|
"dependencies": {
|
|
6
|
-
"@theia/core": "1.67.0-next.
|
|
6
|
+
"@theia/core": "1.67.0-next.56+d8f18cc386c",
|
|
7
7
|
"tslib": "^2.6.2"
|
|
8
8
|
},
|
|
9
9
|
"publishConfig": {
|
|
@@ -50,5 +50,5 @@
|
|
|
50
50
|
"nyc": {
|
|
51
51
|
"extends": "../../configs/nyc.json"
|
|
52
52
|
},
|
|
53
|
-
"gitHead": "
|
|
53
|
+
"gitHead": "d8f18cc386c45a736cd193d42eab02c8f64c6b10"
|
|
54
54
|
}
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { VariableContribution, VariableRegistry } from './variable';
|
|
2
|
-
import { ApplicationServer } from '@theia/core/lib/common/application-protocol';
|
|
3
|
-
import { EnvVariablesServer } from '@theia/core/lib/common/env-variables';
|
|
4
|
-
import { CommandService } from '@theia/core/lib/common/command';
|
|
5
|
-
import { PreferenceService } from '@theia/core/lib/common/preferences/preference-service';
|
|
6
|
-
import { ResourceContextKey } from '@theia/core/lib/browser/resource-context-key';
|
|
7
|
-
import { QuickInputService } from '@theia/core/lib/browser';
|
|
8
|
-
export declare class CommonVariableContribution implements VariableContribution {
|
|
9
|
-
protected readonly env: EnvVariablesServer;
|
|
10
|
-
protected readonly commands: CommandService;
|
|
11
|
-
protected readonly preferences: PreferenceService;
|
|
12
|
-
protected readonly resourceContextKey: ResourceContextKey;
|
|
13
|
-
protected readonly quickInputService: QuickInputService;
|
|
14
|
-
protected readonly appServer: ApplicationServer;
|
|
15
|
-
registerVariables(variables: VariableRegistry): Promise<void>;
|
|
16
|
-
}
|
|
17
|
-
//# sourceMappingURL=common-variable-contribution.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"common-variable-contribution.d.ts","sourceRoot":"","sources":["../../src/browser/common-variable-contribution.ts"],"names":[],"mappings":"AAiBA,OAAO,EAAE,oBAAoB,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AACpE,OAAO,EAAE,iBAAiB,EAAE,MAAM,6CAA6C,CAAC;AAChF,OAAO,EAAE,kBAAkB,EAAE,MAAM,sCAAsC,CAAC;AAC1E,OAAO,EAAE,cAAc,EAAE,MAAM,gCAAgC,CAAC;AAEhE,OAAO,EAAE,iBAAiB,EAAE,MAAM,uDAAuD,CAAC;AAC1F,OAAO,EAAE,kBAAkB,EAAE,MAAM,8CAA8C,CAAC;AAElF,OAAO,EAAE,iBAAiB,EAAkB,MAAM,yBAAyB,CAAC;AAK5E,qBACa,0BAA2B,YAAW,oBAAoB;IAGnE,SAAS,CAAC,QAAQ,CAAC,GAAG,EAAE,kBAAkB,CAAC;IAG3C,SAAS,CAAC,QAAQ,CAAC,QAAQ,EAAE,cAAc,CAAC;IAG5C,SAAS,CAAC,QAAQ,CAAC,WAAW,EAAE,iBAAiB,CAAC;IAGlD,SAAS,CAAC,QAAQ,CAAC,kBAAkB,EAAE,kBAAkB,CAAC;IAG1D,SAAS,CAAC,QAAQ,CAAC,iBAAiB,EAAE,iBAAiB,CAAC;IAGxD,SAAS,CAAC,QAAQ,CAAC,SAAS,EAAE,iBAAiB,CAAC;IAE1C,iBAAiB,CAAC,SAAS,EAAE,gBAAgB,GAAG,OAAO,CAAC,IAAI,CAAC;CAmGtE"}
|
|
@@ -1,162 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
// *****************************************************************************
|
|
3
|
-
// Copyright (C) 2019 TypeFox and others.
|
|
4
|
-
//
|
|
5
|
-
// This program and the accompanying materials are made available under the
|
|
6
|
-
// terms of the Eclipse Public License v. 2.0 which is available at
|
|
7
|
-
// http://www.eclipse.org/legal/epl-2.0.
|
|
8
|
-
//
|
|
9
|
-
// This Source Code may also be made available under the following Secondary
|
|
10
|
-
// Licenses when the conditions for such availability set forth in the Eclipse
|
|
11
|
-
// Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
12
|
-
// with the GNU Classpath Exception which is available at
|
|
13
|
-
// https://www.gnu.org/software/classpath/license.html.
|
|
14
|
-
//
|
|
15
|
-
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
|
|
16
|
-
// *****************************************************************************
|
|
17
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
|
-
exports.CommonVariableContribution = void 0;
|
|
19
|
-
const tslib_1 = require("tslib");
|
|
20
|
-
const inversify_1 = require("@theia/core/shared/inversify");
|
|
21
|
-
const application_protocol_1 = require("@theia/core/lib/common/application-protocol");
|
|
22
|
-
const env_variables_1 = require("@theia/core/lib/common/env-variables");
|
|
23
|
-
const command_1 = require("@theia/core/lib/common/command");
|
|
24
|
-
const os_1 = require("@theia/core/lib/common/os");
|
|
25
|
-
const preference_service_1 = require("@theia/core/lib/common/preferences/preference-service");
|
|
26
|
-
const resource_context_key_1 = require("@theia/core/lib/browser/resource-context-key");
|
|
27
|
-
const browser_1 = require("@theia/core/lib/browser");
|
|
28
|
-
const cancellation_1 = require("@theia/core/lib/common/cancellation");
|
|
29
|
-
const uri_1 = require("@theia/core/lib/common/uri");
|
|
30
|
-
let CommonVariableContribution = class CommonVariableContribution {
|
|
31
|
-
async registerVariables(variables) {
|
|
32
|
-
const execPath = await this.env.getExecPath();
|
|
33
|
-
variables.registerVariable({
|
|
34
|
-
name: 'execPath',
|
|
35
|
-
resolve: () => execPath
|
|
36
|
-
});
|
|
37
|
-
variables.registerVariable({
|
|
38
|
-
name: 'pathSeparator',
|
|
39
|
-
resolve: () => os_1.OS.backend.isWindows ? '\\' : '/'
|
|
40
|
-
});
|
|
41
|
-
variables.registerVariable({
|
|
42
|
-
name: 'env',
|
|
43
|
-
resolve: async (_, envVariableName) => {
|
|
44
|
-
const envVariable = envVariableName && await this.env.getValue(envVariableName);
|
|
45
|
-
const envValue = envVariable && envVariable.value;
|
|
46
|
-
return envValue || '';
|
|
47
|
-
}
|
|
48
|
-
});
|
|
49
|
-
variables.registerVariable({
|
|
50
|
-
name: 'config',
|
|
51
|
-
resolve: (resourceUri = new uri_1.default(this.resourceContextKey.get()), preferenceName) => {
|
|
52
|
-
if (!preferenceName) {
|
|
53
|
-
return undefined;
|
|
54
|
-
}
|
|
55
|
-
return this.preferences.get(preferenceName, undefined, resourceUri && resourceUri.toString());
|
|
56
|
-
}
|
|
57
|
-
});
|
|
58
|
-
variables.registerVariable({
|
|
59
|
-
name: 'command',
|
|
60
|
-
resolve: async (contextUri, commandId, configurationSection, commandIdVariables, configuration) => {
|
|
61
|
-
if (commandId) {
|
|
62
|
-
if (commandIdVariables === null || commandIdVariables === void 0 ? void 0 : commandIdVariables[commandId]) {
|
|
63
|
-
commandId = commandIdVariables[commandId];
|
|
64
|
-
}
|
|
65
|
-
const result = await this.commands.executeCommand(commandId, configuration);
|
|
66
|
-
// eslint-disable-next-line no-null/no-null
|
|
67
|
-
if (result === null) {
|
|
68
|
-
throw (0, cancellation_1.cancelled)();
|
|
69
|
-
}
|
|
70
|
-
return result;
|
|
71
|
-
}
|
|
72
|
-
}
|
|
73
|
-
});
|
|
74
|
-
variables.registerVariable({
|
|
75
|
-
name: 'input',
|
|
76
|
-
resolve: async (resourceUri = new uri_1.default(this.resourceContextKey.get()), variable, section) => {
|
|
77
|
-
var _a, _b;
|
|
78
|
-
if (!variable || !section) {
|
|
79
|
-
return undefined;
|
|
80
|
-
}
|
|
81
|
-
const configuration = this.preferences.get(section, undefined, resourceUri && resourceUri.toString());
|
|
82
|
-
const inputs = !!configuration && 'inputs' in configuration ? configuration.inputs : undefined;
|
|
83
|
-
const input = Array.isArray(inputs) && inputs.find(item => !!item && item.id === variable);
|
|
84
|
-
if (!input) {
|
|
85
|
-
return undefined;
|
|
86
|
-
}
|
|
87
|
-
if (input.type === 'promptString') {
|
|
88
|
-
if (typeof input.description !== 'string') {
|
|
89
|
-
return undefined;
|
|
90
|
-
}
|
|
91
|
-
return (_a = this.quickInputService) === null || _a === void 0 ? void 0 : _a.input({
|
|
92
|
-
prompt: input.description,
|
|
93
|
-
value: input.default
|
|
94
|
-
});
|
|
95
|
-
}
|
|
96
|
-
if (input.type === 'pickString') {
|
|
97
|
-
if (typeof input.description !== 'string' || !Array.isArray(input.options)) {
|
|
98
|
-
return undefined;
|
|
99
|
-
}
|
|
100
|
-
const elements = [];
|
|
101
|
-
for (const option of input.options) {
|
|
102
|
-
if (typeof option !== 'string') {
|
|
103
|
-
return undefined;
|
|
104
|
-
}
|
|
105
|
-
if (option === input.default) {
|
|
106
|
-
elements.unshift({
|
|
107
|
-
description: 'Default',
|
|
108
|
-
label: option,
|
|
109
|
-
value: option
|
|
110
|
-
});
|
|
111
|
-
}
|
|
112
|
-
else {
|
|
113
|
-
elements.push({
|
|
114
|
-
label: option,
|
|
115
|
-
value: option
|
|
116
|
-
});
|
|
117
|
-
}
|
|
118
|
-
}
|
|
119
|
-
const selectedPick = await ((_b = this.quickInputService) === null || _b === void 0 ? void 0 : _b.showQuickPick(elements, { placeholder: input.description }));
|
|
120
|
-
return selectedPick === null || selectedPick === void 0 ? void 0 : selectedPick.value;
|
|
121
|
-
}
|
|
122
|
-
if (input.type === 'command') {
|
|
123
|
-
if (typeof input.command !== 'string') {
|
|
124
|
-
return undefined;
|
|
125
|
-
}
|
|
126
|
-
return this.commands.executeCommand(input.command, input.args);
|
|
127
|
-
}
|
|
128
|
-
return undefined;
|
|
129
|
-
}
|
|
130
|
-
});
|
|
131
|
-
}
|
|
132
|
-
};
|
|
133
|
-
exports.CommonVariableContribution = CommonVariableContribution;
|
|
134
|
-
tslib_1.__decorate([
|
|
135
|
-
(0, inversify_1.inject)(env_variables_1.EnvVariablesServer),
|
|
136
|
-
tslib_1.__metadata("design:type", Object)
|
|
137
|
-
], CommonVariableContribution.prototype, "env", void 0);
|
|
138
|
-
tslib_1.__decorate([
|
|
139
|
-
(0, inversify_1.inject)(command_1.CommandService),
|
|
140
|
-
tslib_1.__metadata("design:type", Object)
|
|
141
|
-
], CommonVariableContribution.prototype, "commands", void 0);
|
|
142
|
-
tslib_1.__decorate([
|
|
143
|
-
(0, inversify_1.inject)(preference_service_1.PreferenceService),
|
|
144
|
-
tslib_1.__metadata("design:type", Object)
|
|
145
|
-
], CommonVariableContribution.prototype, "preferences", void 0);
|
|
146
|
-
tslib_1.__decorate([
|
|
147
|
-
(0, inversify_1.inject)(resource_context_key_1.ResourceContextKey),
|
|
148
|
-
tslib_1.__metadata("design:type", resource_context_key_1.ResourceContextKey)
|
|
149
|
-
], CommonVariableContribution.prototype, "resourceContextKey", void 0);
|
|
150
|
-
tslib_1.__decorate([
|
|
151
|
-
(0, inversify_1.inject)(browser_1.QuickInputService),
|
|
152
|
-
(0, inversify_1.optional)(),
|
|
153
|
-
tslib_1.__metadata("design:type", Object)
|
|
154
|
-
], CommonVariableContribution.prototype, "quickInputService", void 0);
|
|
155
|
-
tslib_1.__decorate([
|
|
156
|
-
(0, inversify_1.inject)(application_protocol_1.ApplicationServer),
|
|
157
|
-
tslib_1.__metadata("design:type", Object)
|
|
158
|
-
], CommonVariableContribution.prototype, "appServer", void 0);
|
|
159
|
-
exports.CommonVariableContribution = CommonVariableContribution = tslib_1.__decorate([
|
|
160
|
-
(0, inversify_1.injectable)()
|
|
161
|
-
], CommonVariableContribution);
|
|
162
|
-
//# sourceMappingURL=common-variable-contribution.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"common-variable-contribution.js","sourceRoot":"","sources":["../../src/browser/common-variable-contribution.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,yCAAyC;AACzC,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;;;AAEhF,4DAA4E;AAE5E,sFAAgF;AAChF,wEAA0E;AAC1E,4DAAgE;AAChE,kDAA+C;AAC/C,8FAA0F;AAC1F,uFAAkF;AAElF,qDAA4E;AAE5E,sEAAgE;AAChE,oDAA6C;AAGtC,IAAM,0BAA0B,GAAhC,MAAM,0BAA0B;IAoBnC,KAAK,CAAC,iBAAiB,CAAC,SAA2B;QAC/C,MAAM,QAAQ,GAAG,MAAM,IAAI,CAAC,GAAG,CAAC,WAAW,EAAE,CAAC;QAC9C,SAAS,CAAC,gBAAgB,CAAC;YACvB,IAAI,EAAE,UAAU;YAChB,OAAO,EAAE,GAAG,EAAE,CAAC,QAAQ;SAC1B,CAAC,CAAC;QACH,SAAS,CAAC,gBAAgB,CAAC;YACvB,IAAI,EAAE,eAAe;YACrB,OAAO,EAAE,GAAG,EAAE,CAAC,OAAE,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,GAAG;SACnD,CAAC,CAAC;QACH,SAAS,CAAC,gBAAgB,CAAC;YACvB,IAAI,EAAE,KAAK;YACX,OAAO,EAAE,KAAK,EAAE,CAAC,EAAE,eAAe,EAAE,EAAE;gBAClC,MAAM,WAAW,GAAG,eAAe,IAAI,MAAM,IAAI,CAAC,GAAG,CAAC,QAAQ,CAAC,eAAe,CAAC,CAAC;gBAChF,MAAM,QAAQ,GAAG,WAAW,IAAI,WAAW,CAAC,KAAK,CAAC;gBAClD,OAAO,QAAQ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CAAiB,CAAC;;+DACwB;AAG/B;IADlB,IAAA,kBAAM,EAAC,yCAAkB,CAAC;sCACY,yCAAkB;sEAAC;AAGvC;IADlB,IAAA,kBAAM,EAAC,2BAAiB,CAAC;IAAE,IAAA,oBAAQ,GAAE;;qEACkB;AAGrC;IADlB,IAAA,kBAAM,EAAC,wCAAiB,CAAC;;6DACsB;qCAlBvC,0BAA0B;IADtC,IAAA,sBAAU,GAAE;GACA,0BAA0B,CAuHtC"}
|
package/lib/browser/index.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/browser/index.ts"],"names":[],"mappings":"AAgBA,cAAc,YAAY,CAAC;AAC3B,cAAc,+BAA+B,CAAC;AAC9C,cAAc,6BAA6B,CAAC"}
|
package/lib/browser/index.js
DELETED
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
// *****************************************************************************
|
|
3
|
-
// Copyright (C) 2018 Red Hat, Inc. and others.
|
|
4
|
-
//
|
|
5
|
-
// This program and the accompanying materials are made available under the
|
|
6
|
-
// terms of the Eclipse Public License v. 2.0 which is available at
|
|
7
|
-
// http://www.eclipse.org/legal/epl-2.0.
|
|
8
|
-
//
|
|
9
|
-
// This Source Code may also be made available under the following Secondary
|
|
10
|
-
// Licenses when the conditions for such availability set forth in the Eclipse
|
|
11
|
-
// Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
12
|
-
// with the GNU Classpath Exception which is available at
|
|
13
|
-
// https://www.gnu.org/software/classpath/license.html.
|
|
14
|
-
//
|
|
15
|
-
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
|
|
16
|
-
// *****************************************************************************
|
|
17
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
|
-
const tslib_1 = require("tslib");
|
|
19
|
-
tslib_1.__exportStar(require("./variable"), exports);
|
|
20
|
-
tslib_1.__exportStar(require("./variable-quick-open-service"), exports);
|
|
21
|
-
tslib_1.__exportStar(require("./variable-resolver-service"), exports);
|
|
22
|
-
//# sourceMappingURL=index.js.map
|
package/lib/browser/index.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/browser/index.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,+CAA+C;AAC/C,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;;AAEhF,qDAA2B;AAC3B,wEAA8C;AAC9C,sEAA4C"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"variable-input-schema.d.ts","sourceRoot":"","sources":["../../src/browser/variable-input-schema.ts"],"names":[],"mappings":"AA6BA,OAAO,EAAE,WAAW,EAAE,MAAM,oCAAoC,CAAC;AAEjE,eAAO,MAAM,YAAY,EAAE,WAmG1B,CAAC"}
|
|
@@ -1,131 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
// *****************************************************************************
|
|
3
|
-
// Copyright (C) 2019 TypeFox and others.
|
|
4
|
-
//
|
|
5
|
-
// This program and the accompanying materials are made available under the
|
|
6
|
-
// terms of the Eclipse Public License v. 2.0 which is available at
|
|
7
|
-
// http://www.eclipse.org/legal/epl-2.0.
|
|
8
|
-
//
|
|
9
|
-
// This Source Code may also be made available under the following Secondary
|
|
10
|
-
// Licenses when the conditions for such availability set forth in the Eclipse
|
|
11
|
-
// Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
12
|
-
// with the GNU Classpath Exception which is available at
|
|
13
|
-
// https://www.gnu.org/software/classpath/license.html.
|
|
14
|
-
//
|
|
15
|
-
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
|
|
16
|
-
// *****************************************************************************
|
|
17
|
-
/*---------------------------------------------------------------------------------------------
|
|
18
|
-
* Copyright (c) Microsoft Corporation. All rights reserved.
|
|
19
|
-
* Licensed under the MIT License. See License.txt in the project root for license information.
|
|
20
|
-
*--------------------------------------------------------------------------------------------*/
|
|
21
|
-
/*
|
|
22
|
-
* copied from
|
|
23
|
-
* https://github.com/microsoft/vscode/blob/0a34756cae4fc67739e60c708b04637089f8bb0d/src/vs/workbench/services/configurationResolver/common/configurationResolverSchema.ts#L23
|
|
24
|
-
*/
|
|
25
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
26
|
-
exports.inputsSchema = void 0;
|
|
27
|
-
const idDescription = "The input's id is used to associate an input with a variable of the form ${input:id}.";
|
|
28
|
-
const typeDescription = 'The type of user input prompt to use.';
|
|
29
|
-
const descriptionDescription = 'The description is shown when the user is prompted for input.';
|
|
30
|
-
const defaultDescription = 'The default value for the input.';
|
|
31
|
-
exports.inputsSchema = {
|
|
32
|
-
definitions: {
|
|
33
|
-
inputs: {
|
|
34
|
-
type: 'array',
|
|
35
|
-
description: 'User inputs. Used for defining user input prompts, such as free string input or a choice from several options.',
|
|
36
|
-
items: {
|
|
37
|
-
oneOf: [
|
|
38
|
-
{
|
|
39
|
-
type: 'object',
|
|
40
|
-
required: ['id', 'type', 'description'],
|
|
41
|
-
additionalProperties: false,
|
|
42
|
-
properties: {
|
|
43
|
-
id: {
|
|
44
|
-
type: 'string',
|
|
45
|
-
description: idDescription
|
|
46
|
-
},
|
|
47
|
-
type: {
|
|
48
|
-
type: 'string',
|
|
49
|
-
description: typeDescription,
|
|
50
|
-
enum: ['promptString'],
|
|
51
|
-
enumDescriptions: [
|
|
52
|
-
"The 'promptString' type opens an input box to ask the user for input."
|
|
53
|
-
]
|
|
54
|
-
},
|
|
55
|
-
description: {
|
|
56
|
-
type: 'string',
|
|
57
|
-
description: descriptionDescription
|
|
58
|
-
},
|
|
59
|
-
default: {
|
|
60
|
-
type: 'string',
|
|
61
|
-
description: defaultDescription
|
|
62
|
-
},
|
|
63
|
-
}
|
|
64
|
-
},
|
|
65
|
-
{
|
|
66
|
-
type: 'object',
|
|
67
|
-
required: ['id', 'type', 'description', 'options'],
|
|
68
|
-
additionalProperties: false,
|
|
69
|
-
properties: {
|
|
70
|
-
id: {
|
|
71
|
-
type: 'string',
|
|
72
|
-
description: idDescription
|
|
73
|
-
},
|
|
74
|
-
type: {
|
|
75
|
-
type: 'string',
|
|
76
|
-
description: typeDescription,
|
|
77
|
-
enum: ['pickString'],
|
|
78
|
-
enumDescriptions: [
|
|
79
|
-
"The 'pickString' type shows a selection list.",
|
|
80
|
-
]
|
|
81
|
-
},
|
|
82
|
-
description: {
|
|
83
|
-
type: 'string',
|
|
84
|
-
description: descriptionDescription
|
|
85
|
-
},
|
|
86
|
-
default: {
|
|
87
|
-
type: 'string',
|
|
88
|
-
description: defaultDescription
|
|
89
|
-
},
|
|
90
|
-
options: {
|
|
91
|
-
type: 'array',
|
|
92
|
-
description: 'An array of strings that defines the options for a quick pick.',
|
|
93
|
-
items: {
|
|
94
|
-
type: 'string'
|
|
95
|
-
}
|
|
96
|
-
}
|
|
97
|
-
}
|
|
98
|
-
},
|
|
99
|
-
{
|
|
100
|
-
type: 'object',
|
|
101
|
-
required: ['id', 'type', 'command'],
|
|
102
|
-
additionalProperties: false,
|
|
103
|
-
properties: {
|
|
104
|
-
id: {
|
|
105
|
-
type: 'string',
|
|
106
|
-
description: idDescription
|
|
107
|
-
},
|
|
108
|
-
type: {
|
|
109
|
-
type: 'string',
|
|
110
|
-
description: typeDescription,
|
|
111
|
-
enum: ['command'],
|
|
112
|
-
enumDescriptions: [
|
|
113
|
-
"The 'command' type executes a command.",
|
|
114
|
-
]
|
|
115
|
-
},
|
|
116
|
-
command: {
|
|
117
|
-
type: 'string',
|
|
118
|
-
description: 'The command to execute for this input variable.'
|
|
119
|
-
},
|
|
120
|
-
args: {
|
|
121
|
-
type: 'object',
|
|
122
|
-
description: 'Optional arguments passed to the command.'
|
|
123
|
-
}
|
|
124
|
-
}
|
|
125
|
-
}
|
|
126
|
-
]
|
|
127
|
-
}
|
|
128
|
-
}
|
|
129
|
-
}
|
|
130
|
-
};
|
|
131
|
-
//# sourceMappingURL=variable-input-schema.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"variable-input-schema.js","sourceRoot":"","sources":["../../src/browser/variable-input-schema.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,yCAAyC;AACzC,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;AAChF;;;gGAGgG;AAChG;;;GAGG;;;AAEH,MAAM,aAAa,GAAG,uFAAuF,CAAC;AAC9G,MAAM,eAAe,GAAG,uCAAuC,CAAC;AAChE,MAAM,sBAAsB,GAAG,+DAA+D,CAAC;AAC/F,MAAM,kBAAkB,GAAG,kCAAkC,CAAC;AAIjD,QAAA,YAAY,GAAgB;IACrC,WAAW,EAAE;QACT,MAAM,EAAE;YACJ,IAAI,EAAE,OAAO;YACb,WAAW,EAAE,gHAAgH;YAC7H,KAAK,EAAE;gBACH,KAAK,EAAE;oBACH;wBACI,IAAI,EAAE,QAAQ;wBACd,QAAQ,EAAE,CAAC,IAAI,EAAE,MAAM,EAAE,aAAa,CAAC;wBACvC,oBAAoB,EAAE,KAAK;wBAC3B,UAAU,EAAE;4BACR,EAAE,EAAE;gCACA,IAAI,EAAE,QAAQ;gCACd,WAAW,EAAE,aAAa;6BAC7B;4BACD,IAAI,EAAE;gCACF,IAAI,EAAE,QAAQ;gCACd,WAAW,EAAE,eAAe;gCAC5B,IAAI,EAAE,CAAC,cAAc,CAAC;gCACtB,gBAAgB,EAAE;oCACd,uEAAuE;iCAC1E;6BACJ;4BACD,WAAW,EAAE;gCACT,IAAI,EAAE,Q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CACd,WAAW,EAAE,iDAAiD;6BACjE;4BACD,IAAI,EAAE;gCACF,IAAI,EAAE,QAAQ;gCACd,WAAW,EAAE,2CAA2C;6BAC3D;yBACJ;qBACJ;iBACJ;aACJ;SACJ;KACJ;CACJ,CAAC"}
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
export interface VariablePromptStringInput {
|
|
2
|
-
id: string;
|
|
3
|
-
type: 'promptString';
|
|
4
|
-
description: string;
|
|
5
|
-
default?: string;
|
|
6
|
-
}
|
|
7
|
-
export interface VariablePickStringInput {
|
|
8
|
-
id: string;
|
|
9
|
-
type: 'pickString';
|
|
10
|
-
description: string;
|
|
11
|
-
options: string[];
|
|
12
|
-
default?: string;
|
|
13
|
-
}
|
|
14
|
-
export interface VariableCommandInput {
|
|
15
|
-
id: string;
|
|
16
|
-
type: 'command';
|
|
17
|
-
command: string;
|
|
18
|
-
args?: any;
|
|
19
|
-
}
|
|
20
|
-
export type VariableInput = VariablePromptStringInput | VariablePickStringInput | VariableCommandInput;
|
|
21
|
-
//# sourceMappingURL=variable-input.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"variable-input.d.ts","sourceRoot":"","sources":["../../src/browser/variable-input.ts"],"names":[],"mappings":"AAuBA,MAAM,WAAW,yBAAyB;IACtC,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,cAAc,CAAC;IACrB,WAAW,EAAE,MAAM,CAAC;IACpB,OAAO,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,uBAAuB;IACpC,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,YAAY,CAAC;IACnB,WAAW,EAAE,MAAM,CAAC;IACpB,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,oBAAoB;IACjC,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,SAAS,CAAC;IAChB,OAAO,EAAE,MAAM,CAAC;IAEhB,IAAI,CAAC,EAAE,GAAG,CAAC;CACd;AAED,MAAM,MAAM,aAAa,GAAG,yBAAyB,GAAG,uBAAuB,GAAG,oBAAoB,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"variable-input.js","sourceRoot":"","sources":["../../src/browser/variable-input.ts"],"names":[],"mappings":""}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { MessageService } from '@theia/core/lib/common/message-service';
|
|
2
|
-
import { VariableRegistry, Variable } from './variable';
|
|
3
|
-
import { VariableResolverService } from './variable-resolver-service';
|
|
4
|
-
import { QuickPickItem, QuickInputService } from '@theia/core/lib/browser';
|
|
5
|
-
export declare class VariableQuickOpenService {
|
|
6
|
-
protected readonly variableRegistry: VariableRegistry;
|
|
7
|
-
protected items: Array<QuickPickItem>;
|
|
8
|
-
protected readonly messages: MessageService;
|
|
9
|
-
protected readonly quickInputService: QuickInputService;
|
|
10
|
-
protected readonly variableResolver: VariableResolverService;
|
|
11
|
-
constructor(variableRegistry: VariableRegistry);
|
|
12
|
-
open(): void;
|
|
13
|
-
protected showValue(variable: Variable): Promise<void>;
|
|
14
|
-
}
|
|
15
|
-
//# sourceMappingURL=variable-quick-open-service.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"variable-quick-open-service.d.ts","sourceRoot":"","sources":["../../src/browser/variable-quick-open-service.ts"],"names":[],"mappings":"AAiBA,OAAO,EAAE,cAAc,EAAE,MAAM,wCAAwC,CAAC;AACxE,OAAO,EAAE,gBAAgB,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACxD,OAAO,EAAE,uBAAuB,EAAE,MAAM,6BAA6B,CAAC;AACtE,OAAO,EAAE,aAAa,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AAE3E,qBACa,wBAAwB;IAcH,SAAS,CAAC,QAAQ,CAAC,gBAAgB,EAAE,gBAAgB;IAZnF,SAAS,CAAC,KAAK,EAAE,KAAK,CAAC,aAAa,CAAC,CAAC;IAGtC,SAAS,CAAC,QAAQ,CAAC,QAAQ,EAAE,cAAc,CAAC;IAG5C,SAAS,CAAC,QAAQ,CAAC,iBAAiB,EAAE,iBAAiB,CAAC;IAGxD,SAAS,CAAC,QAAQ,CAAC,gBAAgB,EAAE,uBAAuB,CAAC;gBAGZ,gBAAgB,EAAE,gBAAgB;IAGnF,IAAI,IAAI,IAAI;cAYI,SAAS,CAAC,QAAQ,EAAE,QAAQ,GAAG,OAAO,CAAC,IAAI,CAAC;CAS/D"}
|
|
@@ -1,70 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
// *****************************************************************************
|
|
3
|
-
// Copyright (C) 2018 Red Hat, Inc. and others.
|
|
4
|
-
//
|
|
5
|
-
// This program and the accompanying materials are made available under the
|
|
6
|
-
// terms of the Eclipse Public License v. 2.0 which is available at
|
|
7
|
-
// http://www.eclipse.org/legal/epl-2.0.
|
|
8
|
-
//
|
|
9
|
-
// This Source Code may also be made available under the following Secondary
|
|
10
|
-
// Licenses when the conditions for such availability set forth in the Eclipse
|
|
11
|
-
// Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
12
|
-
// with the GNU Classpath Exception which is available at
|
|
13
|
-
// https://www.gnu.org/software/classpath/license.html.
|
|
14
|
-
//
|
|
15
|
-
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
|
|
16
|
-
// *****************************************************************************
|
|
17
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
|
-
exports.VariableQuickOpenService = void 0;
|
|
19
|
-
const tslib_1 = require("tslib");
|
|
20
|
-
const inversify_1 = require("@theia/core/shared/inversify");
|
|
21
|
-
const message_service_1 = require("@theia/core/lib/common/message-service");
|
|
22
|
-
const variable_1 = require("./variable");
|
|
23
|
-
const variable_resolver_service_1 = require("./variable-resolver-service");
|
|
24
|
-
const browser_1 = require("@theia/core/lib/browser");
|
|
25
|
-
let VariableQuickOpenService = class VariableQuickOpenService {
|
|
26
|
-
constructor(variableRegistry) {
|
|
27
|
-
this.variableRegistry = variableRegistry;
|
|
28
|
-
}
|
|
29
|
-
open() {
|
|
30
|
-
var _a;
|
|
31
|
-
this.items = this.variableRegistry.getVariables().map(v => ({
|
|
32
|
-
label: '${' + v.name + '}',
|
|
33
|
-
detail: v.description,
|
|
34
|
-
execute: () => {
|
|
35
|
-
setTimeout(() => this.showValue(v));
|
|
36
|
-
}
|
|
37
|
-
}));
|
|
38
|
-
(_a = this.quickInputService) === null || _a === void 0 ? void 0 : _a.showQuickPick(this.items, { placeholder: 'Registered variables' });
|
|
39
|
-
}
|
|
40
|
-
async showValue(variable) {
|
|
41
|
-
var _a;
|
|
42
|
-
const argument = await ((_a = this.quickInputService) === null || _a === void 0 ? void 0 : _a.input({
|
|
43
|
-
placeHolder: 'Type a variable argument'
|
|
44
|
-
}));
|
|
45
|
-
const value = await this.variableResolver.resolve('${' + variable.name + ':' + argument + '}');
|
|
46
|
-
if (typeof value === 'string') {
|
|
47
|
-
this.messages.info(value);
|
|
48
|
-
}
|
|
49
|
-
}
|
|
50
|
-
};
|
|
51
|
-
exports.VariableQuickOpenService = VariableQuickOpenService;
|
|
52
|
-
tslib_1.__decorate([
|
|
53
|
-
(0, inversify_1.inject)(message_service_1.MessageService),
|
|
54
|
-
tslib_1.__metadata("design:type", message_service_1.MessageService)
|
|
55
|
-
], VariableQuickOpenService.prototype, "messages", void 0);
|
|
56
|
-
tslib_1.__decorate([
|
|
57
|
-
(0, inversify_1.inject)(browser_1.QuickInputService),
|
|
58
|
-
(0, inversify_1.optional)(),
|
|
59
|
-
tslib_1.__metadata("design:type", Object)
|
|
60
|
-
], VariableQuickOpenService.prototype, "quickInputService", void 0);
|
|
61
|
-
tslib_1.__decorate([
|
|
62
|
-
(0, inversify_1.inject)(variable_resolver_service_1.VariableResolverService),
|
|
63
|
-
tslib_1.__metadata("design:type", variable_resolver_service_1.VariableResolverService)
|
|
64
|
-
], VariableQuickOpenService.prototype, "variableResolver", void 0);
|
|
65
|
-
exports.VariableQuickOpenService = VariableQuickOpenService = tslib_1.__decorate([
|
|
66
|
-
(0, inversify_1.injectable)(),
|
|
67
|
-
tslib_1.__param(0, (0, inversify_1.inject)(variable_1.VariableRegistry)),
|
|
68
|
-
tslib_1.__metadata("design:paramtypes", [variable_1.VariableRegistry])
|
|
69
|
-
], VariableQuickOpenService);
|
|
70
|
-
//# sourceMappingURL=variable-quick-open-service.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"variable-quick-open-service.js","sourceRoot":"","sources":["../../src/browser/variable-quick-open-service.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,+CAA+C;AAC/C,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;;;AAEhF,4DAA4E;AAC5E,4EAAwE;AACxE,yCAAwD;AACxD,2EAAsE;AACtE,qDAA2E;AAGpE,IAAM,wBAAwB,GAA9B,MAAM,wBAAwB;IAajC,YACiD,gBAAkC;QAAlC,qBAAgB,GAAhB,gBAAgB,CAAkB;IAC/E,CAAC;IAEL,IAAI;;QACA,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,gBAAgB,CAAC,YAAY,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC;YACxD,KAAK,EAAE,IAAI,GAAG,CAAC,CAAC,IAAI,GAAG,GAAG;YAC1B,MAAM,EAAE,CAAC,CAAC,WAAW;YACrB,OAAO,EAAE,GAAG,EAAE;gBACV,UAAU,CAAC,GAAG,EAAE,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,CAAC;YACxC,CAAC;SACJ,CAAC,CAAC,CAAC;QAEJ,MAAA,IAAI,CAAC,iBAAiB,0CAAE,aAAa,CAAC,IAAI,CAAC,KAAK,EAAE,EAAE,WAAW,EAAE,sBAAsB,EAAE,CAAC,CAAC;IAC/F,CAAC;IAES,KAAK,CAAC,SAAS,CAAC,QAAkB;;QACxC,MAAM,QAAQ,GAAG,MAAM,CAAA,MAAA,IAAI,CAAC,iBAAiB,0CAAE,KAAK,CAAC;YACjD,WAAW,EAAE,0BAA0B;SAC1C,CAAC,CAAA,CAAC;QACH,MAAM,KAAK,GAAG,MAAM,IAAI,CAAC,gBAAgB,CAAC,OAAO,CAAC,IAAI,GAAG,QAAQ,CAAC,IAAI,GAAG,GAAG,GAAG,QAAQ,GAAG,GAAG,CAAC,CAAC;QAC/F,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE,CAAC;YAC5B,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;QAC9B,CAAC;IACL,CAAC;CACJ,CAAA;AAtCY,4DAAwB;AAKd;IADlB,IAAA,kBAAM,EAAC,gCAAc,CAAC;sCACM,gCAAc;0DAAC;AAGzB;IADlB,IAAA,kBAAM,EAAC,2BAAiB,CAAC;IAAE,IAAA,oBAAQ,GAAE;;mEACkB;AAGrC;IADlB,IAAA,kBAAM,EAAC,mDAAuB,CAAC;sCACK,mDAAuB;kEAAC;mCAXpD,wBAAwB;IADpC,IAAA,sBAAU,GAAE;IAeJ,mBAAA,IAAA,kBAAM,EAAC,2BAAgB,CAAC,CAAA;6CAAsC,2BAAgB;GAd1E,wBAAwB,CAsCpC"}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { FrontendApplicationContribution } from '@theia/core/lib/browser';
|
|
2
|
-
import { Command, CommandContribution, CommandRegistry, ContributionProvider } from '@theia/core/lib/common';
|
|
3
|
-
import { VariableContribution, VariableRegistry } from './variable';
|
|
4
|
-
import { VariableQuickOpenService } from './variable-quick-open-service';
|
|
5
|
-
export declare const LIST_VARIABLES: Command;
|
|
6
|
-
export declare class VariableResolverFrontendContribution implements FrontendApplicationContribution, CommandContribution {
|
|
7
|
-
protected readonly contributionProvider: ContributionProvider<VariableContribution>;
|
|
8
|
-
protected readonly variableRegistry: VariableRegistry;
|
|
9
|
-
protected readonly variableQuickOpenService: VariableQuickOpenService;
|
|
10
|
-
constructor(contributionProvider: ContributionProvider<VariableContribution>, variableRegistry: VariableRegistry, variableQuickOpenService: VariableQuickOpenService);
|
|
11
|
-
onStart(): void;
|
|
12
|
-
registerCommands(commands: CommandRegistry): void;
|
|
13
|
-
}
|
|
14
|
-
//# sourceMappingURL=variable-resolver-frontend-contribution.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"variable-resolver-frontend-contribution.d.ts","sourceRoot":"","sources":["../../src/browser/variable-resolver-frontend-contribution.ts"],"names":[],"mappings":"AAiBA,OAAO,EAAE,+BAA+B,EAAE,MAAM,yBAAyB,CAAC;AAC1E,OAAO,EAAE,OAAO,EAAE,mBAAmB,EAAE,eAAe,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AAC7G,OAAO,EAAE,oBAAoB,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AACpE,OAAO,EAAE,wBAAwB,EAAE,MAAM,+BAA+B,CAAC;AAEzE,eAAO,MAAM,cAAc,EAAE,OAGgB,CAAC;AAE9C,qBACa,oCAAqC,YAAW,+BAA+B,EAAE,mBAAmB;IAIzG,SAAS,CAAC,QAAQ,CAAC,oBAAoB,EAAE,oBAAoB,CAAC,oBAAoB,CAAC;IACzD,SAAS,CAAC,QAAQ,CAAC,gBAAgB,EAAE,gBAAgB;IAC7C,SAAS,CAAC,QAAQ,CAAC,wBAAwB,EAAE,wBAAwB;gBAFpF,oBAAoB,EAAE,oBAAoB,CAAC,oBAAoB,CAAC,EACtC,gBAAgB,EAAE,gBAAgB,EAC1B,wBAAwB,EAAE,wBAAwB;IAG3G,OAAO,IAAI,IAAI;IAMf,gBAAgB,CAAC,QAAQ,EAAE,eAAe,GAAG,IAAI;CAMpD"}
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
// *****************************************************************************
|
|
3
|
-
// Copyright (C) 2018 Red Hat, Inc. and others.
|
|
4
|
-
//
|
|
5
|
-
// This program and the accompanying materials are made available under the
|
|
6
|
-
// terms of the Eclipse Public License v. 2.0 which is available at
|
|
7
|
-
// http://www.eclipse.org/legal/epl-2.0.
|
|
8
|
-
//
|
|
9
|
-
// This Source Code may also be made available under the following Secondary
|
|
10
|
-
// Licenses when the conditions for such availability set forth in the Eclipse
|
|
11
|
-
// Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
12
|
-
// with the GNU Classpath Exception which is available at
|
|
13
|
-
// https://www.gnu.org/software/classpath/license.html.
|
|
14
|
-
//
|
|
15
|
-
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
|
|
16
|
-
// *****************************************************************************
|
|
17
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
|
-
exports.VariableResolverFrontendContribution = exports.LIST_VARIABLES = void 0;
|
|
19
|
-
const tslib_1 = require("tslib");
|
|
20
|
-
const inversify_1 = require("@theia/core/shared/inversify");
|
|
21
|
-
const common_1 = require("@theia/core/lib/common");
|
|
22
|
-
const variable_1 = require("./variable");
|
|
23
|
-
const variable_quick_open_service_1 = require("./variable-quick-open-service");
|
|
24
|
-
exports.LIST_VARIABLES = common_1.Command.toLocalizedCommand({
|
|
25
|
-
id: 'variable.list',
|
|
26
|
-
label: 'Variable: List All'
|
|
27
|
-
}, 'theia/variableResolver/listAllVariables');
|
|
28
|
-
let VariableResolverFrontendContribution = class VariableResolverFrontendContribution {
|
|
29
|
-
constructor(contributionProvider, variableRegistry, variableQuickOpenService) {
|
|
30
|
-
this.contributionProvider = contributionProvider;
|
|
31
|
-
this.variableRegistry = variableRegistry;
|
|
32
|
-
this.variableQuickOpenService = variableQuickOpenService;
|
|
33
|
-
}
|
|
34
|
-
onStart() {
|
|
35
|
-
this.contributionProvider.getContributions().forEach(contrib => contrib.registerVariables(this.variableRegistry));
|
|
36
|
-
}
|
|
37
|
-
registerCommands(commands) {
|
|
38
|
-
commands.registerCommand(exports.LIST_VARIABLES, {
|
|
39
|
-
isEnabled: () => true,
|
|
40
|
-
execute: () => this.variableQuickOpenService.open()
|
|
41
|
-
});
|
|
42
|
-
}
|
|
43
|
-
};
|
|
44
|
-
exports.VariableResolverFrontendContribution = VariableResolverFrontendContribution;
|
|
45
|
-
exports.VariableResolverFrontendContribution = VariableResolverFrontendContribution = tslib_1.__decorate([
|
|
46
|
-
(0, inversify_1.injectable)(),
|
|
47
|
-
tslib_1.__param(0, (0, inversify_1.inject)(common_1.ContributionProvider)),
|
|
48
|
-
tslib_1.__param(0, (0, inversify_1.named)(variable_1.VariableContribution)),
|
|
49
|
-
tslib_1.__param(1, (0, inversify_1.inject)(variable_1.VariableRegistry)),
|
|
50
|
-
tslib_1.__param(2, (0, inversify_1.inject)(variable_quick_open_service_1.VariableQuickOpenService)),
|
|
51
|
-
tslib_1.__metadata("design:paramtypes", [Object, variable_1.VariableRegistry,
|
|
52
|
-
variable_quick_open_service_1.VariableQuickOpenService])
|
|
53
|
-
], VariableResolverFrontendContribution);
|
|
54
|
-
//# sourceMappingURL=variable-resolver-frontend-contribution.js.map
|