@eclipse-glsp/client 0.10.0-next.e5fcffe.169 → 1.1.0-next.282a632.186
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/css/decoration.css +5 -1
- package/css/glsp-sprotty.css +39 -0
- package/css/tool-palette.css +2 -2
- package/lib/base/container-modules.d.ts.map +1 -1
- package/lib/base/container-modules.js +10 -9
- package/lib/base/container-modules.js.map +1 -1
- package/lib/base/editor-context-service.d.ts +2 -3
- package/lib/base/editor-context-service.d.ts.map +1 -1
- package/lib/base/editor-context-service.js +11 -12
- package/lib/base/editor-context-service.js.map +1 -1
- package/lib/base/model/update-model-command.d.ts +14 -7
- package/lib/base/model/update-model-command.d.ts.map +1 -1
- package/lib/base/model/update-model-command.js +31 -41
- package/lib/base/model/update-model-command.js.map +1 -1
- package/lib/base/source-uri-aware.d.ts +2 -17
- package/lib/base/source-uri-aware.d.ts.map +1 -1
- package/lib/base/source-uri-aware.js +4 -6
- package/lib/base/source-uri-aware.js.map +1 -1
- package/lib/features/change-bounds/movement-restrictor.d.ts +36 -6
- package/lib/features/change-bounds/movement-restrictor.d.ts.map +1 -1
- package/lib/features/change-bounds/movement-restrictor.js +54 -39
- package/lib/features/change-bounds/movement-restrictor.js.map +1 -1
- package/lib/features/change-bounds/snap.d.ts +20 -5
- package/lib/features/change-bounds/snap.d.ts.map +1 -1
- package/lib/features/change-bounds/snap.js +19 -8
- package/lib/features/change-bounds/snap.js.map +1 -1
- package/lib/features/context-menu/selection-service-aware-context-menu-mouse-listener.d.ts +5 -7
- package/lib/features/context-menu/selection-service-aware-context-menu-mouse-listener.d.ts.map +1 -1
- package/lib/features/context-menu/selection-service-aware-context-menu-mouse-listener.js +7 -14
- package/lib/features/context-menu/selection-service-aware-context-menu-mouse-listener.js.map +1 -1
- package/lib/features/hover/hover.d.ts +1 -2
- package/lib/features/hover/hover.d.ts.map +1 -1
- package/lib/features/hover/hover.js +2 -15
- package/lib/features/hover/hover.js.map +1 -1
- package/lib/features/layout/di.config.d.ts +2 -2
- package/lib/features/layout/di.config.d.ts.map +1 -1
- package/lib/features/layout/di.config.js +8 -5
- package/lib/features/layout/di.config.js.map +1 -1
- package/lib/features/layout/hbox-layout.d.ts +1 -1
- package/lib/features/layout/hbox-layout.d.ts.map +1 -1
- package/lib/features/layout/hbox-layout.js +19 -7
- package/lib/features/layout/hbox-layout.js.map +1 -1
- package/lib/features/layout/{layout-commands.d.ts → layout-elements-action.d.ts} +75 -57
- package/lib/features/layout/layout-elements-action.d.ts.map +1 -0
- package/lib/features/layout/{layout-commands.js → layout-elements-action.js} +153 -197
- package/lib/features/layout/layout-elements-action.js.map +1 -0
- package/lib/features/layout/layout-elements-action.spec.d.ts +3 -0
- package/lib/features/layout/layout-elements-action.spec.d.ts.map +1 -0
- package/lib/features/layout/{layout-commands.spec.js → layout-elements-action.spec.js} +63 -56
- package/lib/features/layout/layout-elements-action.spec.js.map +1 -0
- package/lib/features/layout/layouter.d.ts +37 -0
- package/lib/features/layout/layouter.d.ts.map +1 -0
- package/lib/features/layout/layouter.js +131 -0
- package/lib/features/layout/layouter.js.map +1 -0
- package/lib/features/layout/vbox-layout.d.ts +1 -1
- package/lib/features/layout/vbox-layout.d.ts.map +1 -1
- package/lib/features/layout/vbox-layout.js +17 -5
- package/lib/features/layout/vbox-layout.js.map +1 -1
- package/lib/features/mouse-tool/mouse-tool.d.ts +0 -1
- package/lib/features/mouse-tool/mouse-tool.d.ts.map +1 -1
- package/lib/features/mouse-tool/mouse-tool.js +9 -5
- package/lib/features/mouse-tool/mouse-tool.js.map +1 -1
- package/lib/features/select/select-mouse-listener.d.ts +3 -1
- package/lib/features/select/select-mouse-listener.d.ts.map +1 -1
- package/lib/features/select/select-mouse-listener.js +62 -0
- package/lib/features/select/select-mouse-listener.js.map +1 -1
- package/lib/features/select/selection-service.d.ts +12 -3
- package/lib/features/select/selection-service.d.ts.map +1 -1
- package/lib/features/select/selection-service.js +31 -45
- package/lib/features/select/selection-service.js.map +1 -1
- package/lib/features/select/selection-service.spec.js +1 -1
- package/lib/features/select/selection-service.spec.js.map +1 -1
- package/lib/features/source-model-watcher/di.config.d.ts +4 -0
- package/lib/features/{model-source-watcher → source-model-watcher}/di.config.d.ts.map +1 -1
- package/lib/features/{model-source-watcher → source-model-watcher}/di.config.js +4 -4
- package/lib/features/{model-source-watcher → source-model-watcher}/di.config.js.map +1 -1
- package/lib/features/{model-source-watcher/model-source-changed-action-handler.d.ts → source-model-watcher/source-model-changed-action-handler.d.ts} +9 -9
- package/lib/features/{model-source-watcher/model-source-changed-action-handler.d.ts.map → source-model-watcher/source-model-changed-action-handler.d.ts.map} +1 -1
- package/lib/features/{model-source-watcher/model-source-changed-action-handler.js → source-model-watcher/source-model-changed-action-handler.js} +19 -19
- package/lib/features/{model-source-watcher/model-source-changed-action-handler.js.map → source-model-watcher/source-model-changed-action-handler.js.map} +1 -1
- package/lib/features/tool-feedback/change-bounds-tool-feedback.js +1 -1
- package/lib/features/tool-feedback/change-bounds-tool-feedback.js.map +1 -1
- package/lib/features/tool-feedback/edge-edit-tool-feedback.d.ts +3 -2
- package/lib/features/tool-feedback/edge-edit-tool-feedback.d.ts.map +1 -1
- package/lib/features/tool-feedback/edge-edit-tool-feedback.js +13 -6
- package/lib/features/tool-feedback/edge-edit-tool-feedback.js.map +1 -1
- package/lib/features/tools/di.config.d.ts +9 -2
- package/lib/features/tools/di.config.d.ts.map +1 -1
- package/lib/features/tools/di.config.js +14 -3
- package/lib/features/tools/di.config.js.map +1 -1
- package/lib/features/tools/enable-default-tools-on-focus-loss.d.ts +26 -0
- package/lib/features/tools/enable-default-tools-on-focus-loss.d.ts.map +1 -0
- package/lib/features/tools/enable-default-tools-on-focus-loss.js +29 -0
- package/lib/features/tools/enable-default-tools-on-focus-loss.js.map +1 -0
- package/lib/features/validation/di.config.d.ts +0 -15
- package/lib/features/validation/di.config.d.ts.map +1 -1
- package/lib/features/validation/di.config.js +6 -4
- package/lib/features/validation/di.config.js.map +1 -1
- package/lib/features/validation/issue-marker.d.ts +11 -5
- package/lib/features/validation/issue-marker.d.ts.map +1 -1
- package/lib/features/validation/issue-marker.js +25 -5
- package/lib/features/validation/issue-marker.js.map +1 -1
- package/lib/features/validation/marker-navigator.d.ts +11 -17
- package/lib/features/validation/marker-navigator.d.ts.map +1 -1
- package/lib/features/validation/marker-navigator.js +32 -61
- package/lib/features/validation/marker-navigator.js.map +1 -1
- package/lib/features/validation/validate.d.ts +8 -19
- package/lib/features/validation/validate.d.ts.map +1 -1
- package/lib/features/validation/validate.js +29 -55
- package/lib/features/validation/validate.js.map +1 -1
- package/lib/index.d.ts +6 -6
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +16 -15
- package/lib/index.js.map +1 -1
- package/lib/lib/model.d.ts +1 -1
- package/lib/lib/model.d.ts.map +1 -1
- package/lib/lib/model.js +3 -3
- package/lib/lib/model.js.map +1 -1
- package/lib/model-source/glsp-diagram-server.d.ts +1 -1
- package/lib/model-source/glsp-diagram-server.d.ts.map +1 -1
- package/lib/model-source/glsp-diagram-server.js +1 -1
- package/lib/model-source/glsp-diagram-server.js.map +1 -1
- package/lib/utils/layout-utils.d.ts +4 -20
- package/lib/utils/layout-utils.d.ts.map +1 -1
- package/lib/utils/layout-utils.js +1 -1
- package/lib/utils/layout-utils.js.map +1 -1
- package/lib/views/base-view-module.d.ts.map +1 -1
- package/lib/views/base-view-module.js +3 -1
- package/lib/views/base-view-module.js.map +1 -1
- package/lib/views/glsp-projection-view.d.ts +30 -0
- package/lib/views/glsp-projection-view.d.ts.map +1 -0
- package/lib/views/glsp-projection-view.js +142 -0
- package/lib/views/glsp-projection-view.js.map +1 -0
- package/lib/views/index.d.ts +1 -0
- package/lib/views/index.d.ts.map +1 -1
- package/lib/views/index.js +1 -0
- package/lib/views/index.js.map +1 -1
- package/package.json +4 -4
- package/src/base/container-modules.ts +6 -5
- package/src/base/editor-context-service.ts +15 -7
- package/src/base/model/update-model-command.ts +48 -34
- package/src/base/source-uri-aware.ts +5 -4
- package/src/features/change-bounds/movement-restrictor.ts +73 -43
- package/src/features/change-bounds/snap.ts +15 -12
- package/src/features/context-menu/selection-service-aware-context-menu-mouse-listener.ts +19 -25
- package/src/features/hover/hover.ts +2 -24
- package/src/features/layout/di.config.ts +14 -6
- package/src/features/layout/hbox-layout.ts +24 -7
- package/src/features/layout/{layout-commands.spec.ts → layout-elements-action.spec.ts} +56 -48
- package/src/features/layout/{layout-commands.ts → layout-elements-action.ts} +195 -207
- package/src/features/layout/layouter.ts +137 -0
- package/src/features/layout/vbox-layout.ts +22 -5
- package/src/features/mouse-tool/mouse-tool.ts +8 -6
- package/src/features/select/select-mouse-listener.ts +81 -1
- package/src/features/select/selection-service.spec.ts +1 -1
- package/src/features/select/selection-service.ts +37 -50
- package/src/features/{model-source-watcher → source-model-watcher}/di.config.ts +5 -5
- package/src/features/{model-source-watcher/model-source-changed-action-handler.ts → source-model-watcher/source-model-changed-action-handler.ts} +12 -12
- package/src/features/tool-feedback/change-bounds-tool-feedback.ts +1 -1
- package/src/features/tool-feedback/edge-edit-tool-feedback.ts +14 -6
- package/src/features/tools/di.config.ts +13 -2
- package/src/features/tools/enable-default-tools-on-focus-loss.ts +33 -0
- package/src/features/validation/di.config.ts +10 -7
- package/src/features/validation/issue-marker.ts +34 -12
- package/src/features/validation/marker-navigator.ts +29 -66
- package/src/features/validation/validate.ts +36 -71
- package/src/index.ts +8 -7
- package/src/lib/model.ts +1 -1
- package/src/model-source/glsp-diagram-server.ts +1 -1
- package/src/utils/layout-utils.ts +7 -27
- package/src/views/base-view-module.ts +5 -1
- package/src/views/glsp-projection-view.tsx +166 -0
- package/src/views/index.ts +2 -0
- package/lib/features/layout/layout-commands.d.ts.map +0 -1
- package/lib/features/layout/layout-commands.js.map +0 -1
- package/lib/features/layout/layout-commands.spec.d.ts +0 -3
- package/lib/features/layout/layout-commands.spec.d.ts.map +0 -1
- package/lib/features/layout/layout-commands.spec.js.map +0 -1
- package/lib/features/model-source-watcher/di.config.d.ts +0 -4
|
@@ -14,8 +14,8 @@
|
|
|
14
14
|
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
|
|
15
15
|
********************************************************************************/
|
|
16
16
|
import { Action, Point } from '@eclipse-glsp/protocol';
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
17
|
+
import { ActionDispatcher, BoundsAware, IActionHandler, IContextMenuItemProvider, KeyListener, MenuItem, Selectable, SIssueMarker, SIssueSeverity, SModelElement, SModelRoot } from 'sprotty';
|
|
18
|
+
import { SelectionService } from '../select/selection-service';
|
|
19
19
|
export interface NavigateToMarkerAction extends Action {
|
|
20
20
|
kind: typeof NavigateToMarkerAction.KIND;
|
|
21
21
|
direction: MarkerNavigationDirection;
|
|
@@ -47,27 +47,21 @@ export declare class LeftToRightTopToBottomComparator {
|
|
|
47
47
|
export declare class MarkerNavigator {
|
|
48
48
|
static readonly ALL_SEVERITIES: SIssueSeverity[];
|
|
49
49
|
protected markerComparator: SModelElementComparator;
|
|
50
|
-
next(root: SModelRoot
|
|
51
|
-
previous(root: SModelRoot
|
|
52
|
-
protected getMarkers(root: SModelRoot
|
|
50
|
+
next(root: Readonly<SModelRoot>, current?: SModelElement & BoundsAware, predicate?: (marker: SIssueMarker) => boolean): SIssueMarker | undefined;
|
|
51
|
+
previous(root: Readonly<SModelRoot>, current?: SModelElement & BoundsAware, predicate?: (marker: SIssueMarker) => boolean): SIssueMarker | undefined;
|
|
52
|
+
protected getMarkers(root: Readonly<SModelRoot>, predicate: (marker: SIssueMarker) => boolean): SIssueMarker[];
|
|
53
53
|
protected getNextIndex(current: SModelElement & BoundsAware, markers: SIssueMarker[]): number;
|
|
54
54
|
protected getPreviousIndex(current: SModelElement & BoundsAware, markers: SIssueMarker[]): number;
|
|
55
55
|
}
|
|
56
|
-
export declare class
|
|
57
|
-
protected action: NavigateToMarkerAction;
|
|
58
|
-
static KIND: string;
|
|
56
|
+
export declare class NavigateToMarkerActionHandler implements IActionHandler {
|
|
59
57
|
protected markerComparator: SModelElementComparator;
|
|
60
58
|
protected markerNavigator: MarkerNavigator;
|
|
61
59
|
protected selectionService: SelectionService;
|
|
62
|
-
protected
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
protected
|
|
67
|
-
protected getTarget(selected: SModelElement[], root: SModelRoot): SIssueMarker | undefined;
|
|
68
|
-
protected matchesSeverities(marker: SIssueMarker): boolean;
|
|
69
|
-
undo(context: CommandExecutionContext): CommandReturn;
|
|
70
|
-
redo(context: CommandExecutionContext): CommandReturn;
|
|
60
|
+
protected actionDispatcher: ActionDispatcher;
|
|
61
|
+
handle(action: NavigateToMarkerAction): void;
|
|
62
|
+
protected getSelectedElements(action: NavigateToMarkerAction): (SModelElement & Selectable)[];
|
|
63
|
+
protected getTarget(action: NavigateToMarkerAction, selected: SModelElement[]): SIssueMarker | undefined;
|
|
64
|
+
protected matchesSeverities(action: NavigateToMarkerAction, marker: SIssueMarker): boolean;
|
|
71
65
|
}
|
|
72
66
|
export declare class MarkerNavigatorContextMenuItemProvider implements IContextMenuItemProvider {
|
|
73
67
|
protected selectionService: SelectionService;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"marker-navigator.d.ts","sourceRoot":"","sources":["../../../src/features/validation/marker-navigator.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAClF,OAAO,EAAE,MAAM,EAA6C,KAAK,EAAgB,MAAM,wBAAwB,CAAC;AAEhH,OAAO,EACH,
|
|
1
|
+
{"version":3,"file":"marker-navigator.d.ts","sourceRoot":"","sources":["../../../src/features/validation/marker-navigator.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAClF,OAAO,EAAE,MAAM,EAA6C,KAAK,EAAgB,MAAM,wBAAwB,CAAC;AAEhH,OAAO,EACH,gBAAgB,EAChB,WAAW,EAEX,cAAc,EACd,wBAAwB,EAGxB,WAAW,EACX,QAAQ,EACR,UAAU,E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AAC,IAAI,EAAE,QAAQ,CAAC,UAAU,CAAC,EAAE,iBAAiB,CAAC,EAAE,KAAK,GAAG,OAAO,CAAC,QAAQ,EAAE,CAAC;CA4BvF;AAED,qBACa,0BAA2B,SAAQ,WAAW;IAC9C,OAAO,CAAC,QAAQ,EAAE,aAAa,EAAE,KAAK,EAAE,aAAa,GAAG,MAAM,EAAE;CAQ5E"}
|
|
@@ -8,11 +8,8 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
8
8
|
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
9
|
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
10
|
};
|
|
11
|
-
var __param = (this && this.__param) || function (paramIndex, decorator) {
|
|
12
|
-
return function (target, key) { decorator(target, key, paramIndex); }
|
|
13
|
-
};
|
|
14
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
|
-
exports.MarkerNavigatorKeyListener = exports.MarkerNavigatorContextMenuItemProvider = exports.
|
|
12
|
+
exports.MarkerNavigatorKeyListener = exports.MarkerNavigatorContextMenuItemProvider = exports.NavigateToMarkerActionHandler = exports.MarkerNavigator = exports.LeftToRightTopToBottomComparator = exports.SModelElementComparator = exports.NavigateToMarkerAction = void 0;
|
|
16
13
|
/********************************************************************************
|
|
17
14
|
* Copyright (c) 2020-2022 EclipseSource and others.
|
|
18
15
|
*
|
|
@@ -124,83 +121,57 @@ MarkerNavigator = __decorate([
|
|
|
124
121
|
(0, inversify_1.injectable)()
|
|
125
122
|
], MarkerNavigator);
|
|
126
123
|
exports.MarkerNavigator = MarkerNavigator;
|
|
127
|
-
let
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
this.action
|
|
131
|
-
|
|
132
|
-
execute(context) {
|
|
133
|
-
const root = context.root;
|
|
134
|
-
const selected = this.getSelectedElements(root);
|
|
135
|
-
const target = this.getTarget(selected, root);
|
|
136
|
-
if (target === undefined) {
|
|
137
|
-
return root;
|
|
138
|
-
}
|
|
139
|
-
const selectableTarget = (0, sprotty_1.findParentByFeature)(target, sprotty_1.isSelectable);
|
|
124
|
+
let NavigateToMarkerActionHandler = class NavigateToMarkerActionHandler {
|
|
125
|
+
handle(action) {
|
|
126
|
+
const selected = this.getSelectedElements(action);
|
|
127
|
+
const target = this.getTarget(action, selected);
|
|
128
|
+
const selectableTarget = target ? (0, sprotty_1.findParentByFeature)(target, sprotty_1.isSelectable) : undefined;
|
|
140
129
|
if (selectableTarget) {
|
|
141
|
-
const
|
|
142
|
-
this.
|
|
143
|
-
this.
|
|
144
|
-
this.centerCommand.execute(context);
|
|
145
|
-
return this.selectCommand.execute(context);
|
|
130
|
+
const deselectedElementsIDs = selected.map(e => e.id).filter(id => id !== selectableTarget.id);
|
|
131
|
+
this.actionDispatcher.dispatch(protocol_1.SelectAction.create({ selectedElementsIDs: [selectableTarget.id], deselectedElementsIDs }));
|
|
132
|
+
this.actionDispatcher.dispatch(protocol_1.CenterAction.create([selectableTarget.id]));
|
|
146
133
|
}
|
|
147
|
-
return root;
|
|
148
134
|
}
|
|
149
|
-
getSelectedElements(
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
selectedIds = this.action.selectedElementIds;
|
|
135
|
+
getSelectedElements(action) {
|
|
136
|
+
if (action.selectedElementIds && action.selectedElementIds.length > 0) {
|
|
137
|
+
return (0, smodel_util_1.getElements)(this.selectionService.getModelRoot().index, action.selectedElementIds, sprotty_1.isSelectable);
|
|
153
138
|
}
|
|
154
|
-
|
|
155
|
-
return this.selectionService.getSelectedElements();
|
|
156
|
-
}
|
|
157
|
-
return selectedIds.map(id => root.index.getById(id)).filter(element => element !== undefined && (0, sprotty_1.isSelectable)(element));
|
|
139
|
+
return this.selectionService.getSelectedElements();
|
|
158
140
|
}
|
|
159
|
-
getTarget(
|
|
160
|
-
const
|
|
161
|
-
const
|
|
162
|
-
if (
|
|
163
|
-
return this.markerNavigator.previous(root,
|
|
141
|
+
getTarget(action, selected) {
|
|
142
|
+
const root = this.selectionService.getModelRoot();
|
|
143
|
+
const target = selected.sort(this.markerComparator.compare).find(sprotty_1.isBoundsAware);
|
|
144
|
+
if (action.direction === 'previous') {
|
|
145
|
+
return this.markerNavigator.previous(root, target, marker => this.matchesSeverities(action, marker));
|
|
164
146
|
}
|
|
165
147
|
else {
|
|
166
|
-
return this.markerNavigator.next(root,
|
|
148
|
+
return this.markerNavigator.next(root, target, marker => this.matchesSeverities(action, marker));
|
|
167
149
|
}
|
|
168
150
|
}
|
|
169
|
-
matchesSeverities(marker) {
|
|
170
|
-
return marker.issues.find(issue =>
|
|
171
|
-
}
|
|
172
|
-
undo(context) {
|
|
173
|
-
if (this.selectCommand) {
|
|
174
|
-
context.root = this.selectCommand.undo(context);
|
|
175
|
-
}
|
|
176
|
-
return this.centerCommand ? this.centerCommand.undo(context) : context.root;
|
|
177
|
-
}
|
|
178
|
-
redo(context) {
|
|
179
|
-
if (this.selectCommand) {
|
|
180
|
-
context.root = this.selectCommand.redo(context);
|
|
181
|
-
}
|
|
182
|
-
return this.centerCommand ? this.centerCommand.redo(context) : context.root;
|
|
151
|
+
matchesSeverities(action, marker) {
|
|
152
|
+
return marker.issues.find(issue => action.severities.includes(issue.severity)) !== undefined;
|
|
183
153
|
}
|
|
184
154
|
};
|
|
185
|
-
NavigateToMarkerCommand.KIND = NavigateToMarkerAction.KIND;
|
|
186
155
|
__decorate([
|
|
187
156
|
(0, inversify_1.inject)(SModelElementComparator),
|
|
188
157
|
__metadata("design:type", SModelElementComparator)
|
|
189
|
-
],
|
|
158
|
+
], NavigateToMarkerActionHandler.prototype, "markerComparator", void 0);
|
|
190
159
|
__decorate([
|
|
191
160
|
(0, inversify_1.inject)(MarkerNavigator),
|
|
192
161
|
__metadata("design:type", MarkerNavigator)
|
|
193
|
-
],
|
|
162
|
+
], NavigateToMarkerActionHandler.prototype, "markerNavigator", void 0);
|
|
194
163
|
__decorate([
|
|
195
164
|
(0, inversify_1.inject)(types_1.TYPES.SelectionService),
|
|
196
165
|
__metadata("design:type", selection_service_1.SelectionService)
|
|
197
|
-
],
|
|
198
|
-
|
|
199
|
-
(0, inversify_1.
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
166
|
+
], NavigateToMarkerActionHandler.prototype, "selectionService", void 0);
|
|
167
|
+
__decorate([
|
|
168
|
+
(0, inversify_1.inject)(types_1.TYPES.IActionDispatcher),
|
|
169
|
+
__metadata("design:type", sprotty_1.ActionDispatcher)
|
|
170
|
+
], NavigateToMarkerActionHandler.prototype, "actionDispatcher", void 0);
|
|
171
|
+
NavigateToMarkerActionHandler = __decorate([
|
|
172
|
+
(0, inversify_1.injectable)()
|
|
173
|
+
], NavigateToMarkerActionHandler);
|
|
174
|
+
exports.NavigateToMarkerActionHandler = NavigateToMarkerActionHandler;
|
|
204
175
|
let MarkerNavigatorContextMenuItemProvider = class MarkerNavigatorContextMenuItemProvider {
|
|
205
176
|
getItems(root, lastMousePosition) {
|
|
206
177
|
const selectedElementIds = Array.from(this.selectionService.getSelectedElementIDs());
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"marker-navigator.js","sourceRoot":"","sources":["../../../src/features/validation/marker-navigator.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"marker-navigator.js","sourceRoot":"","sources":["../../../src/features/validation/marker-navigator.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA;;;;;;;;;;;;;;kFAckF;AAClF,qDAAgH;AAChH,yCAA+C;AAC/C,qCAeiB;AACjB,yDAA8D;AAC9D,4CAAyC;AACzC,+CAA2E;AAC3E,yDAAkF;AAClF,mEAA+D;AAY/D,IAAiB,sBAAsB,CAmBtC;AAnBD,WAAiB,sBAAsB;IACtB,2BAAI,GAAG,kBAAkB,CAAC;IAEvC,SAAgB,EAAE,CAAC,MAAW;QAC1B,OAAO,iBAAM,CAAC,OAAO,CAAC,MAAM,EAAE,uBAAA,IAAI,CAAC,IAAI,IAAA,wBAAa,EAAC,MAAM,EAA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|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
|
|
15
15
|
********************************************************************************/
|
|
16
16
|
import { Action, DeleteMarkersAction, Marker, SetMarkersAction } from '@eclipse-glsp/protocol';
|
|
17
|
-
import {
|
|
17
|
+
import { CommandExecutionContext, CommandReturn, IActionDispatcher, IActionHandler, ICommand } from 'sprotty';
|
|
18
18
|
import { EditorContextService } from '../../base/editor-context-service';
|
|
19
19
|
import { IFeedbackActionDispatcher, IFeedbackEmitter } from '../tool-feedback/feedback-action-dispatcher';
|
|
20
20
|
import { FeedbackCommand } from '../tool-feedback/model';
|
|
@@ -46,22 +46,15 @@ export declare abstract class ExternalMarkerManager {
|
|
|
46
46
|
removeMarkers(markers: Marker[]): void;
|
|
47
47
|
abstract setMarkers(markers: Marker[], sourceUri?: string): void;
|
|
48
48
|
}
|
|
49
|
-
|
|
50
|
-
* Command for handling `SetMarkersAction`
|
|
51
|
-
*/
|
|
52
|
-
export declare class SetMarkersCommand extends Command {
|
|
53
|
-
action: SetMarkersAction;
|
|
49
|
+
export declare class SetMarkersActionHandler implements IActionHandler {
|
|
54
50
|
protected validationFeedbackEmitter: ValidationFeedbackEmitter;
|
|
55
51
|
protected externalMarkerManager?: ExternalMarkerManager;
|
|
56
52
|
protected editorContextService: EditorContextService;
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
execute(context: CommandExecutionContext): Promise<SModelRoot>;
|
|
60
|
-
undo(context: CommandExecutionContext): CommandReturn;
|
|
61
|
-
redo(context: CommandExecutionContext): CommandReturn;
|
|
53
|
+
handle(action: SetMarkersAction): void | Action | ICommand;
|
|
54
|
+
setMarkers(markers: Marker[]): Promise<void>;
|
|
62
55
|
}
|
|
63
56
|
/**
|
|
64
|
-
* Action for applying makers to
|
|
57
|
+
* Action for applying makers to the graphical model.
|
|
65
58
|
*/
|
|
66
59
|
export interface ApplyMarkersAction extends Action {
|
|
67
60
|
kind: typeof ApplyMarkersAction.KIND;
|
|
@@ -73,26 +66,22 @@ export declare namespace ApplyMarkersAction {
|
|
|
73
66
|
function create(markers: Marker[]): ApplyMarkersAction;
|
|
74
67
|
}
|
|
75
68
|
/**
|
|
76
|
-
*
|
|
69
|
+
* Handles {@link ApplyMarkersAction}s by creating the corresponding {@link SIssueMarker}s and
|
|
70
|
+
* adding them to the graphical model.
|
|
77
71
|
*/
|
|
78
72
|
export declare class ApplyMarkersCommand extends FeedbackCommand {
|
|
79
73
|
protected action: ApplyMarkersAction;
|
|
80
74
|
static KIND: string;
|
|
81
|
-
readonly priority = 0;
|
|
82
75
|
constructor(action: ApplyMarkersAction);
|
|
83
76
|
execute(context: CommandExecutionContext): CommandReturn;
|
|
84
|
-
undo(context: CommandExecutionContext): CommandReturn;
|
|
85
|
-
redo(context: CommandExecutionContext): CommandReturn;
|
|
86
77
|
}
|
|
87
78
|
/**
|
|
88
79
|
* Command for handling `DeleteMarkersAction`
|
|
89
80
|
*/
|
|
90
|
-
export declare class DeleteMarkersCommand extends
|
|
81
|
+
export declare class DeleteMarkersCommand extends FeedbackCommand {
|
|
91
82
|
protected action: DeleteMarkersAction;
|
|
92
83
|
static KIND: string;
|
|
93
84
|
constructor(action: DeleteMarkersAction);
|
|
94
85
|
execute(context: CommandExecutionContext): CommandReturn;
|
|
95
|
-
undo(context: CommandExecutionContext): CommandReturn;
|
|
96
|
-
redo(context: CommandExecutionContext): CommandReturn;
|
|
97
86
|
}
|
|
98
87
|
//# sourceMappingURL=validate.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"validate.d.ts","sourceRoot":"","sources":["../../../src/features/validation/validate.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAClF,OAAO,EAAE,MAAM,EAAE,mBAAmB,EAAgB,MAAM,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAE7G,OAAO,
|
|
1
|
+
{"version":3,"file":"validate.d.ts","sourceR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AAE,oBAAoB,CAAC;IAErD,MAAM,CAAC,MAAM,EAAE,gBAAgB,GAAG,IAAI,GAAG,MAAM,GAAG,QAAQ;IAKpD,UAAU,CAAC,OAAO,EAAE,MAAM,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC;CAMrD;AAED;;GAEG;AACH,MAAM,WAAW,kBAAmB,SAAQ,MAAM;IAC9C,IAAI,EAAE,OAAO,kBAAkB,CAAC,IAAI,CAAC;IACrC,OAAO,EAAE,MAAM,EAAE,CAAC;CACrB;AAED,yBAAiB,kBAAkB,CAAC;IACzB,MAAM,IAAI,iBAAiB,CAAC;IAEnC,SAAgB,EAAE,CAAC,MAAM,EAAE,GAAG,GAAG,MAAM,IAAI,kBAAkB,CAE5D;IAED,SAAgB,MAAM,CAAC,OAAO,EAAE,MAAM,EAAE,GAAG,kBAAkB,CAK5D;CACJ;AAED;;;GAGG;AACH,qBACa,mBAAoB,SAAQ,eAAe;IAGlB,SAAS,CAAC,MAAM,EAAE,kBAAkB;IAFtE,MAAM,CAAC,IAAI,SAA2B;gBAEM,MAAM,EAAE,kBAAkB;IAItE,OAAO,CAAC,OAAO,EAAE,uBAAuB,GAAG,aAAa;CAe3D;AAiBD;;GAEG;AACH,qBACa,oBAAqB,SAAQ,eAAe;IAGnB,SAAS,CAAC,MAAM,EAAE,mBAAmB;IAFvE,MAAM,CAAC,IAAI,SAA4B;gBAEK,MAAM,EAAE,mBAAmB;IAIvE,OAAO,CAAC,OAAO,EAAE,uBAAuB,GAAG,aAAa;CAwB3D"}
|
|
@@ -12,7 +12,7 @@ var __param = (this && this.__param) || function (paramIndex, decorator) {
|
|
|
12
12
|
return function (target, key) { decorator(target, key, paramIndex); }
|
|
13
13
|
};
|
|
14
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
|
-
exports.DeleteMarkersCommand = exports.ApplyMarkersCommand = exports.ApplyMarkersAction = exports.
|
|
15
|
+
exports.DeleteMarkersCommand = exports.ApplyMarkersCommand = exports.ApplyMarkersAction = exports.SetMarkersActionHandler = exports.ExternalMarkerManager = exports.ValidationFeedbackEmitter = void 0;
|
|
16
16
|
/********************************************************************************
|
|
17
17
|
* Copyright (c) 2019-2022 EclipseSource and others.
|
|
18
18
|
*
|
|
@@ -34,7 +34,6 @@ const sprotty_1 = require("sprotty");
|
|
|
34
34
|
const editor_context_service_1 = require("../../base/editor-context-service");
|
|
35
35
|
const types_1 = require("../../base/types");
|
|
36
36
|
const smodel_util_1 = require("../../utils/smodel-util");
|
|
37
|
-
const hover_1 = require("../hover/hover");
|
|
38
37
|
const model_1 = require("../tool-feedback/model");
|
|
39
38
|
const issue_marker_1 = require("./issue-marker");
|
|
40
39
|
/**
|
|
@@ -94,51 +93,36 @@ ExternalMarkerManager = __decorate([
|
|
|
94
93
|
(0, inversify_1.injectable)()
|
|
95
94
|
], ExternalMarkerManager);
|
|
96
95
|
exports.ExternalMarkerManager = ExternalMarkerManager;
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
constructor(action) {
|
|
102
|
-
super();
|
|
103
|
-
this.action = action;
|
|
96
|
+
let SetMarkersActionHandler = class SetMarkersActionHandler {
|
|
97
|
+
handle(action) {
|
|
98
|
+
const markers = action.markers;
|
|
99
|
+
this.setMarkers(markers);
|
|
104
100
|
}
|
|
105
|
-
async
|
|
106
|
-
|
|
101
|
+
async setMarkers(markers) {
|
|
102
|
+
var _a;
|
|
107
103
|
const uri = await this.editorContextService.getSourceUri();
|
|
108
|
-
|
|
109
|
-
this.externalMarkerManager.setMarkers(markers, uri);
|
|
110
|
-
}
|
|
104
|
+
(_a = this.externalMarkerManager) === null || _a === void 0 ? void 0 : _a.setMarkers(markers, uri);
|
|
111
105
|
const applyMarkersAction = ApplyMarkersAction.create(markers);
|
|
112
106
|
this.validationFeedbackEmitter.registerValidationFeedbackAction(applyMarkersAction);
|
|
113
|
-
return context.root;
|
|
114
|
-
}
|
|
115
|
-
undo(context) {
|
|
116
|
-
return context.root;
|
|
117
|
-
}
|
|
118
|
-
redo(context) {
|
|
119
|
-
return this.execute(context);
|
|
120
107
|
}
|
|
121
108
|
};
|
|
122
|
-
SetMarkersCommand.KIND = protocol_1.SetMarkersAction.KIND;
|
|
123
109
|
__decorate([
|
|
124
110
|
(0, inversify_1.inject)(ValidationFeedbackEmitter),
|
|
125
111
|
__metadata("design:type", ValidationFeedbackEmitter)
|
|
126
|
-
],
|
|
112
|
+
], SetMarkersActionHandler.prototype, "validationFeedbackEmitter", void 0);
|
|
127
113
|
__decorate([
|
|
128
114
|
(0, inversify_1.inject)(ExternalMarkerManager),
|
|
129
115
|
(0, inversify_1.optional)(),
|
|
130
116
|
__metadata("design:type", ExternalMarkerManager)
|
|
131
|
-
],
|
|
117
|
+
], SetMarkersActionHandler.prototype, "externalMarkerManager", void 0);
|
|
132
118
|
__decorate([
|
|
133
119
|
(0, inversify_1.inject)(editor_context_service_1.EditorContextService),
|
|
134
120
|
__metadata("design:type", editor_context_service_1.EditorContextService)
|
|
135
|
-
],
|
|
136
|
-
|
|
137
|
-
(0, inversify_1.injectable)()
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
], SetMarkersCommand);
|
|
141
|
-
exports.SetMarkersCommand = SetMarkersCommand;
|
|
121
|
+
], SetMarkersActionHandler.prototype, "editorContextService", void 0);
|
|
122
|
+
SetMarkersActionHandler = __decorate([
|
|
123
|
+
(0, inversify_1.injectable)()
|
|
124
|
+
], SetMarkersActionHandler);
|
|
125
|
+
exports.SetMarkersActionHandler = SetMarkersActionHandler;
|
|
142
126
|
var ApplyMarkersAction;
|
|
143
127
|
(function (ApplyMarkersAction) {
|
|
144
128
|
ApplyMarkersAction.KIND = 'applyMarkers';
|
|
@@ -155,33 +139,29 @@ var ApplyMarkersAction;
|
|
|
155
139
|
ApplyMarkersAction.create = create;
|
|
156
140
|
})(ApplyMarkersAction = exports.ApplyMarkersAction || (exports.ApplyMarkersAction = {}));
|
|
157
141
|
/**
|
|
158
|
-
*
|
|
142
|
+
* Handles {@link ApplyMarkersAction}s by creating the corresponding {@link SIssueMarker}s and
|
|
143
|
+
* adding them to the graphical model.
|
|
159
144
|
*/
|
|
160
145
|
let ApplyMarkersCommand = class ApplyMarkersCommand extends model_1.FeedbackCommand {
|
|
161
146
|
constructor(action) {
|
|
162
147
|
super();
|
|
163
148
|
this.action = action;
|
|
164
|
-
this.priority = 0;
|
|
165
149
|
}
|
|
166
150
|
execute(context) {
|
|
167
|
-
|
|
168
|
-
for (const marker of markers) {
|
|
151
|
+
this.action.markers.forEach(marker => {
|
|
169
152
|
const modelElement = context.root.index.getById(marker.elementId);
|
|
170
153
|
if (modelElement instanceof sprotty_1.SParentElement) {
|
|
171
154
|
const issueMarker = (0, issue_marker_1.getOrCreateSIssueMarker)(modelElement);
|
|
172
155
|
const issue = (0, issue_marker_1.createSIssue)(marker);
|
|
173
156
|
issueMarker.issues.push(issue);
|
|
157
|
+
if (issueMarker instanceof issue_marker_1.GIssueMarker) {
|
|
158
|
+
issueMarker.computeProjectionCssClasses();
|
|
159
|
+
}
|
|
174
160
|
addMaxSeverityCSSClassToIssueParent(modelElement, issueMarker);
|
|
175
161
|
}
|
|
176
|
-
}
|
|
177
|
-
return context.root;
|
|
178
|
-
}
|
|
179
|
-
undo(context) {
|
|
162
|
+
});
|
|
180
163
|
return context.root;
|
|
181
164
|
}
|
|
182
|
-
redo(context) {
|
|
183
|
-
return this.execute(context);
|
|
184
|
-
}
|
|
185
165
|
};
|
|
186
166
|
ApplyMarkersCommand.KIND = ApplyMarkersAction.KIND;
|
|
187
167
|
ApplyMarkersCommand = __decorate([
|
|
@@ -191,7 +171,7 @@ ApplyMarkersCommand = __decorate([
|
|
|
191
171
|
], ApplyMarkersCommand);
|
|
192
172
|
exports.ApplyMarkersCommand = ApplyMarkersCommand;
|
|
193
173
|
function addMaxSeverityCSSClassToIssueParent(modelElement, issueMarker) {
|
|
194
|
-
const maxSeverityCSSClass = (0,
|
|
174
|
+
const maxSeverityCSSClass = (0, issue_marker_1.getSeverity)(issueMarker);
|
|
195
175
|
if (!modelElement.cssClasses) {
|
|
196
176
|
modelElement.cssClasses = [maxSeverityCSSClass];
|
|
197
177
|
}
|
|
@@ -201,23 +181,23 @@ function addMaxSeverityCSSClassToIssueParent(modelElement, issueMarker) {
|
|
|
201
181
|
}
|
|
202
182
|
}
|
|
203
183
|
function removeCSSClassFromIssueParent(modelElement, issueMarker) {
|
|
204
|
-
|
|
184
|
+
const severity = (0, issue_marker_1.getSeverity)(issueMarker);
|
|
185
|
+
(0, smodel_util_1.removeCssClasses)(modelElement, [severity]);
|
|
205
186
|
}
|
|
206
187
|
/**
|
|
207
188
|
* Command for handling `DeleteMarkersAction`
|
|
208
189
|
*/
|
|
209
|
-
let DeleteMarkersCommand = class DeleteMarkersCommand extends
|
|
190
|
+
let DeleteMarkersCommand = class DeleteMarkersCommand extends model_1.FeedbackCommand {
|
|
210
191
|
constructor(action) {
|
|
211
192
|
super();
|
|
212
193
|
this.action = action;
|
|
213
194
|
}
|
|
214
195
|
execute(context) {
|
|
215
|
-
|
|
216
|
-
for (const marker of markers) {
|
|
196
|
+
this.action.markers.forEach(marker => {
|
|
217
197
|
const modelElement = context.root.index.getById(marker.elementId);
|
|
218
198
|
if (modelElement instanceof sprotty_1.SParentElement) {
|
|
219
199
|
const issueMarker = (0, issue_marker_1.getSIssueMarker)(modelElement);
|
|
220
|
-
if (issueMarker
|
|
200
|
+
if (issueMarker) {
|
|
221
201
|
removeCSSClassFromIssueParent(modelElement, issueMarker);
|
|
222
202
|
for (let index = 0; index < issueMarker.issues.length; ++index) {
|
|
223
203
|
const issue = issueMarker.issues[index];
|
|
@@ -233,15 +213,9 @@ let DeleteMarkersCommand = class DeleteMarkersCommand extends sprotty_1.Command
|
|
|
233
213
|
}
|
|
234
214
|
}
|
|
235
215
|
}
|
|
236
|
-
}
|
|
216
|
+
});
|
|
237
217
|
return context.root;
|
|
238
218
|
}
|
|
239
|
-
undo(context) {
|
|
240
|
-
return context.root;
|
|
241
|
-
}
|
|
242
|
-
redo(context) {
|
|
243
|
-
return this.execute(context);
|
|
244
|
-
}
|
|
245
219
|
};
|
|
246
220
|
DeleteMarkersCommand.KIND = protocol_1.DeleteMarkersAction.KIND;
|
|
247
221
|
DeleteMarkersCommand = __decorate([
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"validate.js","sourceRoot":"","sources":["../../../src/features/validation/validate.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA;;;;;;;;;;;;;;kFAckF;AAClF,qDAA6G;AAC7G,yCAAyD;AACzD,
|
|
1
|
+
{"version":3,"file":"validate.js","sourceRoot":"","sources":["../../../src/features/validation/validate.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA;;;;;;;;;;;;;;kFAckF;AAClF,qDAA6G;AAC7G,yCAAyD;AACzD,qCAA4I;AAC5I,8EAAyE;AACzE,4CAAyC;AACzC,yDAA2D;AAE3D,kDAAyD;AACzD,iDAAmH;AAEnH;;;GAGG;AAEH,IAAa,yBAAyB,GAAtC,MAAa,yBAAyB;IAOlC,gEAAgE;IAChE,gBAAuB,CAAC;IAExB;;;OAGG;IACH,gCAAgC,CAAC,MAA0B;QACvD,yGAAyG;QACzG,IAAI,CAAC,wBAAwB,CAAC,kBAAkB,CAAC,IAAI,EAAE,EAAE,CAAC,CAAC;QAE3D,yBAAyB;QACzB,IAAI,IAAI,CAAC,gBAAgB,KAAK,SAAS,EAAE;YACrC,MAAM,mBAAmB,GAAG,8BAAmB,CAAC,MAAM,CAAC,IAAI,CAAC,gBAAgB,CAAC,OAAO,CAAC,CAAC;YACtF,IAAI,CAAC,gBAAgB,EAAE,CAAC,IAAI,CAAC,UAAU,CAAC,EAAE,CAAC,UAAU,CAAC,QAAQ,CAAC,mBAAmB,CAAC,CAAC,CAAC;SACxF;QAED,sGAAsG;QACtG,IAAI,CAAC,wBAAwB,CAAC,gBAAgB,CAAC,IAAI,EAAE,CAAC,MAAM,CAAC,CAAC,CAAC;QAC/D,I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kBAAM,EAAC,aAAK,CAAC,MAAM,CAAC,CAAA;;GAHxB,oBAAoB,CA+BhC;AA/BY,oDAAoB"}
|
package/lib/index.d.ts
CHANGED
|
@@ -21,15 +21,15 @@ import glspDecorationModule from './features/decoration/di.config';
|
|
|
21
21
|
import glspEditLabelModule from './features/edit-label/di.config';
|
|
22
22
|
import modelHintsModule from './features/hints/di.config';
|
|
23
23
|
import glspHoverModule from './features/hover/di.config';
|
|
24
|
-
import
|
|
25
|
-
import modelSourceWatcherModule from './features/model-source-watcher/di.config';
|
|
24
|
+
import layoutModule from './features/layout/di.config';
|
|
26
25
|
import glspMouseToolModule from './features/mouse-tool/di.config';
|
|
27
26
|
import { navigationModule } from './features/navigation/di.config';
|
|
28
27
|
import saveModule from './features/save/di.config';
|
|
29
28
|
import glspSelectModule from './features/select/di.config';
|
|
29
|
+
import sourceModelWatcherModule from './features/source-model-watcher/di.config';
|
|
30
30
|
import toolFeedbackModule from './features/tool-feedback/di.config';
|
|
31
31
|
import paletteModule from './features/tool-palette/di.config';
|
|
32
|
-
import toolsModule from './features/tools/di.config';
|
|
32
|
+
import { enableDefaultToolsOnFocusLossModule, toolsModule } from './features/tools/di.config';
|
|
33
33
|
import { markerNavigatorModule, validationModule } from './features/validation/di.config';
|
|
34
34
|
import glspViewportModule from './features/viewport/di.config';
|
|
35
35
|
export * from './base/action-dispatcher';
|
|
@@ -64,8 +64,7 @@ export * from './features/edit-label/edit-label-validator';
|
|
|
64
64
|
export * from './features/hints/model';
|
|
65
65
|
export * from './features/hints/type-hints';
|
|
66
66
|
export * from './features/hover/hover';
|
|
67
|
-
export * from './features/layout/layout-
|
|
68
|
-
export * from './features/model-source-watcher/model-source-changed-action-handler';
|
|
67
|
+
export * from './features/layout/layout-elements-action';
|
|
69
68
|
export * from './features/mouse-tool/mouse-tool';
|
|
70
69
|
export * from './features/navigation/navigation-action-handler';
|
|
71
70
|
export * from './features/navigation/navigation-target-resolver';
|
|
@@ -73,6 +72,7 @@ export * from './features/rank/model';
|
|
|
73
72
|
export * from './features/reconnect/model';
|
|
74
73
|
export * from './features/save/model';
|
|
75
74
|
export * from './features/save/save-keylistener';
|
|
75
|
+
export * from './features/source-model-watcher/source-model-changed-action-handler';
|
|
76
76
|
export * from './features/tool-feedback/change-bounds-tool-feedback';
|
|
77
77
|
export * from './features/tool-feedback/creation-tool-feedback';
|
|
78
78
|
export * from './features/tool-feedback/css-feedback';
|
|
@@ -99,5 +99,5 @@ export * from './utils/marker';
|
|
|
99
99
|
export * from './utils/smodel-util';
|
|
100
100
|
export * from './utils/viewpoint-util';
|
|
101
101
|
export * from './views';
|
|
102
|
-
export { validationModule, saveModule, paletteModule, toolFeedbackModule, defaultGLSPModule, modelHintsModule, glspCommandPaletteModule, glspContextMenuModule, glspServerCopyPasteModule, copyPasteContextMenuModule, glspSelectModule, glspMouseToolModule,
|
|
102
|
+
export { validationModule, saveModule, paletteModule, toolFeedbackModule, defaultGLSPModule, modelHintsModule, glspCommandPaletteModule, glspContextMenuModule, glspServerCopyPasteModule, copyPasteContextMenuModule, glspSelectModule, glspMouseToolModule, layoutModule, glspEditLabelModule, glspHoverModule, toolsModule, enableDefaultToolsOnFocusLossModule, navigationModule, markerNavigatorModule, glspDecorationModule, sourceModelWatcherModule as modelSourceWatcherModule, glspViewportModule };
|
|
103
103
|
//# sourceMappingURL=index.d.ts.map
|
package/lib/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAClF,OAAO,iBAAiB,MAAM,kBAAkB,CAAC;AACjD,OAAO,wBAAwB,MAAM,sCAAsC,CAAC;AAC5E,OAAO,qBAAqB,MAAM,mCAAmC,CAAC;AACtE,OAAO,EAAE,0BAA0B,EAAE,yBAAyB,EAAE,MAAM,iCAAiC,CAAC;AACxG,OAAO,oBAAoB,MAAM,iCAAiC,CAAC;AACnE,OAAO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