Launch Week Day 3: Introducing Organization Notifications in Socket.Learn More
Socket
Book a DemoSign in
Socket

sprotty-vscode-protocol

Package Overview
Dependencies
Maintainers
4
Versions
15
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

sprotty-vscode-protocol - npm Package Compare versions

Comparing version
0.1.1-alpha.17
to
0.2.0
+9
CHANGELOG.md
## Eclipse Sprotty Change Log (VS Code Protocol)
This change log covers only the VS Code extension-to-webview protocol of Sprotty. See also the change log of [sprotty](https://github.com/eclipse/sprotty/blob/master/packages/sprotty/CHANGELOG.md).
### v0.2.0 (Dec. 2021)
This version is mainly about dependency updates:
* Updated `vscode-languageserver-protocol` to v3.16.0
* Added dependency to `sprotty-protocol` and updated imports
{"version":3,"file":"handshake.d.ts","sourceRoot":"","sources":["../src/handshake.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAOlF,MAAM,WAAW,mBAAmB;IAChC,YAAY,EAAE,MAAM,CAAA;CACvB;AAED,wBAAgB,qBAAqB,CAAC,MAAM,EAAE,OAAO,GAAG,MAAM,IAAI,mBAAmB,CAEpF;AAED,eAAO,MAAM,wBAAwB,eAAqC,CAAC;AAE3E,MAAM,WAAW,wBAAwB;IACrC,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IACpB,GAAG,EAAE,MAAM,CAAA;CACd;AAED,wBAAgB,mBAAmB,CAAC,MAAM,EAAE,OAAO,GAAG,MAAM,IAAI,wBAAwB,CAEvF"}
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAElF,cAAc,aAAa,CAAC"}
/********************************************************************************
* Copyright (c) 2020 TypeFox and others.
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v. 2.0 which is available at
* http://www.eclipse.org/legal/epl-2.0.
*
* This Source Code may also be made available under the following Secondary
* Licenses when the conditions for such availability set forth in the Eclipse
* Public License v. 2.0 are satisfied: GNU General Public License, version 2
* with the GNU Classpath Exception which is available at
* https://www.gnu.org/software/classpath/license.html.
*
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
********************************************************************************/
import { Action } from 'sprotty-protocol';
import { Location, WorkspaceEdit } from 'vscode-languageserver-protocol';
export interface LspLabelEditAction extends Action {
kind: typeof LspLabelEditAction.KIND;
location: Location;
editKind: 'xref' | 'name';
initialText: string;
}
export declare namespace LspLabelEditAction {
const KIND = "languageLabelEdit";
function is(action: Action): action is LspLabelEditAction;
}
export interface WorkspaceEditAction extends Action {
kind: typeof WorkspaceEditAction.KIND;
workspaceEdit: WorkspaceEdit;
}
export declare namespace WorkspaceEditAction {
const KIND = "workspaceEdit";
function is(action: Action): action is WorkspaceEditAction;
}
export interface DeleteWithWorkspaceEditAction extends Action {
kind: typeof DeleteWithWorkspaceEditAction.KIND;
}
export declare namespace DeleteWithWorkspaceEditAction {
const KIND = "deleteWithWorkspaceEdit";
function is(action: Action): action is DeleteWithWorkspaceEditAction;
}
//# sourceMappingURL=editing.d.ts.map
{"version":3,"file":"editing.d.ts","sourceRoot":"","sources":["../../../src/lsp/editing/editing.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAElF,OAAO,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAC;AAC1C,OAAO,EAAE,QAAQ,EAAE,aAAa,EAAE,MAAM,gCAAgC,CAAC;AAEzE,MAAM,WAAW,kBAAmB,SAAQ,MAAM;IAC9C,IAAI,EAAE,OAAO,kBAAkB,CAAC,IAAI,CAAA;IACpC,QAAQ,EAAE,QAAQ,CAAA;IAClB,QAAQ,EAAE,MAAM,GAAG,MAAM,CAAA;IACzB,WAAW,EAAE,MAAM,CAAA;CACtB;AACD,yBAAiB,kBAAkB,CAAC;IACzB,MAAM,IAAI,sBAAsB,CAAC;IAExC,SAAgB,EAAE,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,IAAI,kBAAkB,CAE/D;CACJ;AAED,MAAM,WAAW,mBAAoB,SAAQ,MAAM;IAC/C,IAAI,EAAE,OAAO,mBAAmB,CAAC,IAAI,CAAA;IACrC,aAAa,EAAE,aAAa,CAAA;CAC/B;AACD,yBAAiB,mBAAmB,CAAC;IAC1B,MAAM,IAAI,kBAAkB,CAAC;IAEpC,SAAgB,EAAE,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,IAAI,mBAAmB,CAEhE;CACJ;AAED,MAAM,WAAW,6BAA8B,SAAQ,MAAM;IACzD,IAAI,EAAE,OAAO,6BAA6B,CAAC,IAAI,CAAA;CAClD;AACD,yBAAiB,6BAA6B,CAAC;IACpC,MAAM,IAAI,4BAA4B,CAAC;IAE9C,SAAgB,EAAE,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,IAAI,6BAA6B,CAE1E;CACJ"}
"use strict";
/********************************************************************************
* Copyright (c) 2020 TypeFox and others.
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v. 2.0 which is available at
* http://www.eclipse.org/legal/epl-2.0.
*
* This Source Code may also be made available under the following Secondary
* Licenses when the conditions for such availability set forth in the Eclipse
* Public License v. 2.0 are satisfied: GNU General Public License, version 2
* with the GNU Classpath Exception which is available at
* https://www.gnu.org/software/classpath/license.html.
*
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
********************************************************************************/
Object.defineProperty(exports, "__esModule", { value: true });
var LspLabelEditAction;
(function (LspLabelEditAction) {
LspLabelEditAction.KIND = 'languageLabelEdit';
function is(action) {
return action.kind === LspLabelEditAction.KIND;
}
LspLabelEditAction.is = is;
})(LspLabelEditAction = exports.LspLabelEditAction || (exports.LspLabelEditAction = {}));
var WorkspaceEditAction;
(function (WorkspaceEditAction) {
WorkspaceEditAction.KIND = 'workspaceEdit';
function is(action) {
return action.kind === WorkspaceEditAction.KIND;
}
WorkspaceEditAction.is = is;
})(WorkspaceEditAction = exports.WorkspaceEditAction || (exports.WorkspaceEditAction = {}));
var DeleteWithWorkspaceEditAction;
(function (DeleteWithWorkspaceEditAction) {
DeleteWithWorkspaceEditAction.KIND = 'deleteWithWorkspaceEdit';
function is(action) {
return action.kind === DeleteWithWorkspaceEditAction.KIND;
}
DeleteWithWorkspaceEditAction.is = is;
})(DeleteWithWorkspaceEditAction = exports.DeleteWithWorkspaceEditAction || (exports.DeleteWithWorkspaceEditAction = {}));
//# sourceMappingURL=editing.js.map
{"version":3,"file":"editing.js","sourceRoot":"","sources":["../../../src/lsp/editing/editing.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;kFAckF;;AAWlF,IAAiB,kBAAkB,CAMlC;AAND,WAAiB,kBAAkB;IAClB,uBAAI,GAAG,mBAAmB,CAAC;IAExC,SAAgB,EAAE,CAAC,MAAc;QAC7B,OAAO,MAAM,CAAC,IAAI,KAAK,mBAAA,IAAI,CAAC;IAChC,CAAC;IAFe,qBAAE,KAEjB,CAAA;AACL,CAAC,EANgB,kBAAkB,GAAlB,0BAAkB,KAAlB,0BAAkB,QAMlC;AAMD,IAAiB,mBAAmB,CAMnC;AAND,WAAiB,mBAAmB;IACnB,wBAAI,GAAG,eAAe,CAAC;IAEpC,SAAgB,EAAE,CAAC,MAAc;QAC7B,OAAO,MAAM,CAAC,IAAI,KAAK,oBAAA,IAAI,CAAC;IAChC,CAAC;IAFe,sBAAE,KAEjB,CAAA;AACL,CAAC,EANgB,mBAAmB,GAAnB,2BAAmB,KAAnB,2BAAmB,QAMnC;AAKD,IAAiB,6BAA6B,CAM7C;AAND,WAAiB,6BAA6B;IAC7B,kCAAI,GAAG,yBAAyB,CAAC;IAE9C,SAAgB,EAAE,CAAC,MAAc;QAC7B,OAAO,MAAM,CAAC,IAAI,KAAK,8BAAA,IAAI,CAAC;IAChC,CAAC;IAFe,gCAAE,KAEjB,CAAA;AACL,CAAC,EANgB,6BAA6B,GAA7B,qCAA6B,KAA7B,qCAA6B,QAM7C"}
/********************************************************************************
* Copyright (c) 2018 TypeFox and others.
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v. 2.0 which is available at
* http://www.eclipse.org/legal/epl-2.0.
*
* This Source Code may also be made available under the following Secondary
* Licenses when the conditions for such availability set forth in the Eclipse
* Public License v. 2.0 are satisfied: GNU General Public License, version 2
* with the GNU Classpath Exception which is available at
* https://www.gnu.org/software/classpath/license.html.
*
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
********************************************************************************/
export * from './editing';
//# sourceMappingURL=index.d.ts.map
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/lsp/editing/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAElF,cAAc,WAAW,CAAC"}
"use strict";
/********************************************************************************
* Copyright (c) 2018 TypeFox and others.
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v. 2.0 which is available at
* http://www.eclipse.org/legal/epl-2.0.
*
* This Source Code may also be made available under the following Secondary
* Licenses when the conditions for such availability set forth in the Eclipse
* Public License v. 2.0 are satisfied: GNU General Public License, version 2
* with the GNU Classpath Exception which is available at
* https://www.gnu.org/software/classpath/license.html.
*
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
********************************************************************************/
function __export(m) {
for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p];
}
Object.defineProperty(exports, "__esModule", { value: true });
__export(require("./editing"));
//# sourceMappingURL=index.js.map
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/lsp/editing/index.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;kFAckF;;;;;AAElF,+BAA0B"}
# Protocol for Sprotty Webviews in VS Code
This package contains common interfaces and functions used by [sprotty-vscode](https://www.npmjs.com/package/sprotty-vscode) and [sprotty-vscode-webview](https://www.npmjs.com/package/sprotty-vscode-webview).
/********************************************************************************
* Copyright (c) 2020 TypeFox and others.
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v. 2.0 which is available at
* http://www.eclipse.org/legal/epl-2.0.
*
* This Source Code may also be made available under the following Secondary
* Licenses when the conditions for such availability set forth in the Eclipse
* Public License v. 2.0 are satisfied: GNU General Public License, version 2
* with the GNU Classpath Exception which is available at
* https://www.gnu.org/software/classpath/license.html.
*
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
********************************************************************************/
import { Action } from 'sprotty-protocol';
import { Location, WorkspaceEdit } from 'vscode-languageserver-protocol';
export interface LspLabelEditAction extends Action {
kind: typeof LspLabelEditAction.KIND
location: Location
editKind: 'xref' | 'name'
initialText: string
}
export namespace LspLabelEditAction {
export const KIND = 'languageLabelEdit';
export function is(action: Action): action is LspLabelEditAction {
return action.kind === KIND;
}
}
export interface WorkspaceEditAction extends Action {
kind: typeof WorkspaceEditAction.KIND
workspaceEdit: WorkspaceEdit
}
export namespace WorkspaceEditAction {
export const KIND = 'workspaceEdit';
export function is(action: Action): action is WorkspaceEditAction {
return action.kind === KIND;
}
}
export interface DeleteWithWorkspaceEditAction extends Action {
kind: typeof DeleteWithWorkspaceEditAction.KIND
}
export namespace DeleteWithWorkspaceEditAction {
export const KIND = 'deleteWithWorkspaceEdit';
export function is(action: Action): action is DeleteWithWorkspaceEditAction {
return action.kind === KIND;
}
}
/********************************************************************************
* Copyright (c) 2018 TypeFox and others.
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v. 2.0 which is available at
* http://www.eclipse.org/legal/epl-2.0.
*
* This Source Code may also be made available under the following Secondary
* Licenses when the conditions for such availability set forth in the Eclipse
* Public License v. 2.0 are satisfied: GNU General Public License, version 2
* with the GNU Classpath Exception which is available at
* https://www.gnu.org/software/classpath/license.html.
*
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
********************************************************************************/
export * from './editing';
+3
-2

@@ -19,3 +19,3 @@ /********************************************************************************

}
export declare function isWebviewReadyMessage(object: any): object is WebviewReadyMessage;
export declare function isWebviewReadyMessage(object: unknown): object is WebviewReadyMessage;
export declare const SprottyDiagramIdentifier: unique symbol;

@@ -27,2 +27,3 @@ export interface SprottyDiagramIdentifier {

}
export declare function isDiagramIdentifier(object: any): object is SprottyDiagramIdentifier;
export declare function isDiagramIdentifier(object: unknown): object is SprottyDiagramIdentifier;
//# sourceMappingURL=handshake.d.ts.map

@@ -18,4 +18,5 @@ "use strict";

Object.defineProperty(exports, "__esModule", { value: true });
var sprotty_protocol_1 = require("sprotty-protocol");
function isWebviewReadyMessage(object) {
return object !== undefined && object.hasOwnProperty('readyMessage');
return sprotty_protocol_1.hasOwnProperty(object, 'readyMessage');
}

@@ -25,5 +26,5 @@ exports.isWebviewReadyMessage = isWebviewReadyMessage;

function isDiagramIdentifier(object) {
return object !== undefined && object.hasOwnProperty('clientId') && object.hasOwnProperty('diagramType') && object.hasOwnProperty('uri');
return sprotty_protocol_1.hasOwnProperty(object, ['clientId', 'diagramType', 'uri']);
}
exports.isDiagramIdentifier = isDiagramIdentifier;
//# sourceMappingURL=handshake.js.map
+1
-1

@@ -1,1 +0,1 @@

{"version":3,"file":"handshake.js","sourceRoot":"","sources":["../src/handshake.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;kFAckF;;AASlF,SAAgB,qBAAqB,CAAC,MAAW;IAC7C,OAAO,MAAM,KAAK,SAAS,IAAI,MAAM,CAAC,cAAc,CAAC,cAAc,CAAC,CAAC;AACzE,CAAC;AAFD,sDAEC;AAEY,QAAA,wBAAwB,GAAG,MAAM,CAAC,0BAA0B,CAAC,CAAC;AAQ3E,SAAgB,mBAAmB,CAAC,MAAW;IAC3C,OAAO,MAAM,KAAK,SAAS,IAAI,MAAM,CAAC,cAAc,CAAC,UAAU,CAAC,IAAI,MAAM,CAAC,cAAc,CAAC,aAAa,CAAC,IAAI,MAAM,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC;AAC7I,CAAC;AAFD,kDAEC"}
{"version":3,"file":"handshake.js","sourceRoot":"","sources":["../src/handshake.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;kFAckF;;AAElF,qDAAkD;AASlD,SAAgB,qBAAqB,CAAC,MAAe;IACjD,OAAO,iCAAc,CAAC,MAAM,EAAE,cAAc,CAAC,CAAC;AAClD,CAAC;AAFD,sDAEC;AAEY,QAAA,wBAAwB,GAAG,MAAM,CAAC,0BAA0B,CAAC,CAAC;AAQ3E,SAAgB,mBAAmB,CAAC,MAAe;IAC/C,OAAO,iCAAc,CAAC,MAAM,EAAE,CAAC,UAAU,EAAE,aAAa,EAAE,KAAK,CAAC,CAAC,CAAC;AACtE,CAAC;AAFD,kDAEC"}

@@ -16,4 +16,3 @@ /********************************************************************************

********************************************************************************/
export * from './editing';
export * from './handshake';
export * from './sprotty';
//# sourceMappingURL=index.d.ts.map

@@ -21,5 +21,3 @@ "use strict";

Object.defineProperty(exports, "__esModule", { value: true });
__export(require("./editing"));
__export(require("./handshake"));
__export(require("./sprotty"));
//# sourceMappingURL=index.js.map

@@ -1,1 +0,1 @@

{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;kFAckF;;;;;AAElF,+BAA0B;AAC1B,iCAA4B;AAC5B,+BAA0B"}
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;kFAckF;;;;;AAElF,iCAA4B"}
{
"name": "sprotty-vscode-protocol",
"version": "0.1.1-alpha.17+ee3ad7c",
"version": "0.2.0",
"displayName": "Sprotty VSCode Integration - Protocol between webview and extension",

@@ -43,18 +43,22 @@ "description": "Glue code to integrate Sprotty diagrams in VSCode extensions (protocol part)",

"path": "^0.12.7",
"vscode-languageclient": "^5.1.0-next.9"
"sprotty-protocol": "~0.11.0",
"vscode-languageserver-protocol": "^3.16.0"
},
"devDependencies": {
"@types/node": "^8.0.0",
"rimraf": "^2.6.3",
"tslint": "^5.11.0",
"typescript": "^3.1.3"
"@typescript-eslint/eslint-plugin": "^5.3.0",
"@typescript-eslint/parser": "^5.3.0",
"eslint": "^8.1.0",
"eslint-config-prettier": "^8.3.0",
"eslint-plugin-header": "^3.1.1",
"eslint-plugin-no-null": "^1.0.2",
"rimraf": "latest",
"typescript": "~3.8.3"
},
"scripts": {
"prepare": "yarn run clean && yarn run build",
"clean": "rimraf lib sprotty-vscode*.tgz",
"build": "tsc",
"clean": "rimraf lib",
"build": "tsc && yarn run lint",
"watch": "tsc -w",
"lint": "tslint -c ./tslint.json --project ./tsconfig.json"
},
"gitHead": "ee3ad7c27e42eef156ea1684893cd3fd1fbabf5f"
"lint": "eslint -c ../configs/.eslintrc.js \"src/**/!(*.spec.ts*)\""
}
}

@@ -17,5 +17,7 @@ /********************************************************************************

/////////////////////////////////////
// initial handshake
import { hasOwnProperty } from 'sprotty-protocol';
// ----------------------------------
// Initial Handshake
export interface WebviewReadyMessage {

@@ -25,4 +27,4 @@ readyMessage: string

export function isWebviewReadyMessage(object: any): object is WebviewReadyMessage {
return object !== undefined && object.hasOwnProperty('readyMessage');
export function isWebviewReadyMessage(object: unknown): object is WebviewReadyMessage {
return hasOwnProperty(object, 'readyMessage');
}

@@ -38,4 +40,4 @@

export function isDiagramIdentifier(object: any): object is SprottyDiagramIdentifier {
return object !== undefined && object.hasOwnProperty('clientId') && object.hasOwnProperty('diagramType') && object.hasOwnProperty('uri');
}
export function isDiagramIdentifier(object: unknown): object is SprottyDiagramIdentifier {
return hasOwnProperty(object, ['clientId', 'diagramType', 'uri']);
}

@@ -17,4 +17,2 @@ /********************************************************************************

export * from './editing';
export * from './handshake';
export * from './sprotty';
/********************************************************************************
* Copyright (c) 2020 TypeFox and others.
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v. 2.0 which is available at
* http://www.eclipse.org/legal/epl-2.0.
*
* This Source Code may also be made available under the following Secondary
* Licenses when the conditions for such availability set forth in the Eclipse
* Public License v. 2.0 are satisfied: GNU General Public License, version 2
* with the GNU Classpath Exception which is available at
* https://www.gnu.org/software/classpath/license.html.
*
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
********************************************************************************/
import { Action } from "./sprotty";
import { Location, WorkspaceEdit } from 'vscode-languageclient';
export declare namespace LspLabelEditAction {
const KIND = "languageLabelEdit";
function is(action: Action): action is LspLabelEditAction;
}
export interface LspLabelEditAction extends Action {
location: Location;
editKind: "xref" | "name";
initialText: string;
}
export declare namespace WorkspaceEditAction {
const KIND = "workspaceEdit";
function is(action: Action): action is WorkspaceEditAction;
}
export interface WorkspaceEditAction extends Action {
workspaceEdit: WorkspaceEdit;
}
"use strict";
/********************************************************************************
* Copyright (c) 2020 TypeFox and others.
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v. 2.0 which is available at
* http://www.eclipse.org/legal/epl-2.0.
*
* This Source Code may also be made available under the following Secondary
* Licenses when the conditions for such availability set forth in the Eclipse
* Public License v. 2.0 are satisfied: GNU General Public License, version 2
* with the GNU Classpath Exception which is available at
* https://www.gnu.org/software/classpath/license.html.
*
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
********************************************************************************/
Object.defineProperty(exports, "__esModule", { value: true });
var LspLabelEditAction;
(function (LspLabelEditAction) {
LspLabelEditAction.KIND = "languageLabelEdit";
function is(action) {
return action.kind === LspLabelEditAction.KIND;
}
LspLabelEditAction.is = is;
})(LspLabelEditAction = exports.LspLabelEditAction || (exports.LspLabelEditAction = {}));
var WorkspaceEditAction;
(function (WorkspaceEditAction) {
WorkspaceEditAction.KIND = "workspaceEdit";
function is(action) {
return action.kind === WorkspaceEditAction.KIND;
}
WorkspaceEditAction.is = is;
})(WorkspaceEditAction = exports.WorkspaceEditAction || (exports.WorkspaceEditAction = {}));
//# sourceMappingURL=editing.js.map
{"version":3,"file":"editing.js","sourceRoot":"","sources":["../src/editing.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;kFAckF;;AAKlF,IAAiB,kBAAkB,CAMlC;AAND,WAAiB,kBAAkB;IAClB,uBAAI,GAAG,mBAAmB,CAAC;IAExC,SAAgB,EAAE,CAAC,MAAc;QAC7B,OAAO,MAAM,CAAC,IAAI,KAAK,mBAAA,IAAI,CAAC;IAChC,CAAC;IAFe,qBAAE,KAEjB,CAAA;AACL,CAAC,EANgB,kBAAkB,GAAlB,0BAAkB,KAAlB,0BAAkB,QAMlC;AAQD,IAAiB,mBAAmB,CAMnC;AAND,WAAiB,mBAAmB;IACnB,wBAAI,GAAG,eAAe,CAAC;IAEpC,SAAgB,EAAE,CAAC,MAAc;QAC7B,OAAO,MAAM,CAAC,IAAI,KAAK,oBAAA,IAAI,CAAC;IAChC,CAAC;IAFe,sBAAE,KAEjB,CAAA;AACL,CAAC,EANgB,mBAAmB,GAAnB,2BAAmB,KAAnB,2BAAmB,QAMnC"}
/********************************************************************************
* Copyright (c) 2020 TypeFox and others.
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v. 2.0 which is available at
* http://www.eclipse.org/legal/epl-2.0.
*
* This Source Code may also be made available under the following Secondary
* Licenses when the conditions for such availability set forth in the Eclipse
* Public License v. 2.0 are satisfied: GNU General Public License, version 2
* with the GNU Classpath Exception which is available at
* https://www.gnu.org/software/classpath/license.html.
*
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
********************************************************************************/
export interface Action {
readonly kind: string;
}
export declare function isAction(object?: any): object is Action;
export interface ActionMessage {
clientId: string;
action: Action;
}
export declare function isActionMessage(object: any): object is ActionMessage;
"use strict";
/********************************************************************************
* Copyright (c) 2020 TypeFox and others.
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v. 2.0 which is available at
* http://www.eclipse.org/legal/epl-2.0.
*
* This Source Code may also be made available under the following Secondary
* Licenses when the conditions for such availability set forth in the Eclipse
* Public License v. 2.0 are satisfied: GNU General Public License, version 2
* with the GNU Classpath Exception which is available at
* https://www.gnu.org/software/classpath/license.html.
*
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
********************************************************************************/
Object.defineProperty(exports, "__esModule", { value: true });
function isAction(object) {
return object !== undefined && object.hasOwnProperty('kind') && typeof (object['kind']) === 'string';
}
exports.isAction = isAction;
function isActionMessage(object) {
return object !== undefined && object.hasOwnProperty('clientId') && object.hasOwnProperty('action');
}
exports.isActionMessage = isActionMessage;
//# sourceMappingURL=sprotty.js.map
{"version":3,"file":"sprotty.js","sourceRoot":"","sources":["../src/sprotty.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;kFAckF;;AASlF,SAAgB,QAAQ,CAAC,MAAY;IACjC,OAAO,MAAM,KAAK,SAAS,IAAI,MAAM,CAAC,cAAc,CAAC,MAAM,CAAC,IAAI,OAAM,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC,KAAK,QAAQ,CAAC;AACxG,CAAC;AAFD,4BAEC;AAOD,SAAgB,eAAe,CAAC,MAAW;IACvC,OAAO,MAAM,KAAK,SAAS,IAAI,MAAM,CAAC,cAAc,CAAC,UAAU,CAAC,IAAI,MAAM,CAAC,cAAc,CAAC,QAAQ,CAAC,CAAC;AACxG,CAAC;AAFD,0CAEC"}
/********************************************************************************
* Copyright (c) 2020 TypeFox and others.
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v. 2.0 which is available at
* http://www.eclipse.org/legal/epl-2.0.
*
* This Source Code may also be made available under the following Secondary
* Licenses when the conditions for such availability set forth in the Eclipse
* Public License v. 2.0 are satisfied: GNU General Public License, version 2
* with the GNU Classpath Exception which is available at
* https://www.gnu.org/software/classpath/license.html.
*
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
********************************************************************************/
import { Action } from "./sprotty";
import { Location, WorkspaceEdit } from 'vscode-languageclient';
export namespace LspLabelEditAction {
export const KIND = "languageLabelEdit";
export function is(action: Action): action is LspLabelEditAction {
return action.kind === KIND;
}
}
export interface LspLabelEditAction extends Action {
location: Location
editKind: "xref" | "name"
initialText: string
}
export namespace WorkspaceEditAction {
export const KIND = "workspaceEdit";
export function is(action: Action): action is WorkspaceEditAction {
return action.kind === KIND;
}
}
export interface WorkspaceEditAction extends Action {
workspaceEdit: WorkspaceEdit
}
/********************************************************************************
* Copyright (c) 2020 TypeFox and others.
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v. 2.0 which is available at
* http://www.eclipse.org/legal/epl-2.0.
*
* This Source Code may also be made available under the following Secondary
* Licenses when the conditions for such availability set forth in the Eclipse
* Public License v. 2.0 are satisfied: GNU General Public License, version 2
* with the GNU Classpath Exception which is available at
* https://www.gnu.org/software/classpath/license.html.
*
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
********************************************************************************/
/////////////////////////////////////
// sprotty action messages
export interface Action {
readonly kind: string
}
export function isAction(object?: any): object is Action {
return object !== undefined && object.hasOwnProperty('kind') && typeof(object['kind']) === 'string';
}
export interface ActionMessage {
clientId: string
action: Action
}
export function isActionMessage(object: any): object is ActionMessage {
return object !== undefined && object.hasOwnProperty('clientId') && object.hasOwnProperty('action');
}