@eclipse-glsp/client 1.1.0-next.698b9de.254 → 1.1.0-next.69a77b0.259
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/lib/base/action-dispatcher.d.ts.map +1 -1
- package/lib/base/action-dispatcher.js +5 -3
- package/lib/base/action-dispatcher.js.map +1 -1
- package/lib/base/actions/focus-change-action.js +1 -1
- package/lib/base/actions/focus-change-action.js.map +1 -1
- package/lib/base/auto-complete/auto-complete-actions.js +1 -1
- package/lib/base/auto-complete/auto-complete-actions.js.map +1 -1
- package/lib/base/auto-complete/validation-decorator.js +1 -1
- package/lib/base/auto-complete/validation-decorator.js.map +1 -1
- package/lib/base/command-stack.d.ts +17 -2
- package/lib/base/command-stack.d.ts.map +1 -1
- package/lib/base/command-stack.js +43 -3
- package/lib/base/command-stack.js.map +1 -1
- package/lib/base/di.config.d.ts.map +1 -1
- package/lib/base/di.config.js +21 -3
- package/lib/base/di.config.js.map +1 -1
- package/lib/base/drag-aware-mouse-listener.d.ts +2 -2
- package/lib/base/drag-aware-mouse-listener.d.ts.map +1 -1
- package/lib/base/drag-aware-mouse-listener.js.map +1 -1
- package/lib/base/editor-context-service.d.ts +10 -7
- package/lib/base/editor-context-service.d.ts.map +1 -1
- package/lib/base/editor-context-service.js +27 -10
- package/lib/base/editor-context-service.js.map +1 -1
- package/lib/{features/tool-feedback → base/feedback}/css-feedback.d.ts +1 -1
- package/lib/base/feedback/css-feedback.d.ts.map +1 -0
- package/lib/{features/tool-feedback → base/feedback}/css-feedback.js +5 -6
- package/lib/base/feedback/css-feedback.js.map +1 -0
- package/lib/{features/tool-feedback → base/feedback}/feedback-action-dispatcher.d.ts +11 -9
- package/lib/base/feedback/feedback-action-dispatcher.d.ts.map +1 -0
- package/lib/{features/tool-feedback → base/feedback}/feedback-action-dispatcher.js +26 -20
- package/lib/base/feedback/feedback-action-dispatcher.js.map +1 -0
- package/lib/{features/tool-feedback/model.d.ts → base/feedback/feedback-command.d.ts} +1 -1
- package/lib/base/feedback/feedback-command.d.ts.map +1 -0
- package/lib/{features/tool-feedback/model.js → base/feedback/feedback-command.js} +1 -1
- package/lib/base/feedback/feedback-command.js.map +1 -0
- package/lib/base/{model → feedback}/update-model-command.d.ts +3 -15
- package/lib/base/feedback/update-model-command.d.ts.map +1 -0
- package/lib/base/{model → feedback}/update-model-command.js +3 -27
- package/lib/base/feedback/update-model-command.js.map +1 -0
- package/lib/base/focus-tracker.js +2 -3
- package/lib/base/focus-tracker.js.map +1 -1
- package/lib/base/model/model-registry.js +2 -3
- package/lib/base/model/model-registry.js.map +1 -1
- package/lib/base/model-initialization-constraint.js +4 -6
- package/lib/base/model-initialization-constraint.js.map +1 -1
- package/lib/base/ranked.d.ts +34 -0
- package/lib/base/ranked.d.ts.map +1 -0
- package/lib/base/ranked.js +38 -0
- package/lib/base/ranked.js.map +1 -0
- package/lib/base/selection-clearing-mouse-listener.js +2 -3
- package/lib/base/selection-clearing-mouse-listener.js.map +1 -1
- package/lib/{features/select → base}/selection-service.d.ts +34 -13
- package/lib/base/selection-service.d.ts.map +1 -0
- package/lib/{features/select → base}/selection-service.js +73 -29
- package/lib/base/selection-service.js.map +1 -0
- package/lib/base/selection-service.spec.d.ts +2 -0
- package/lib/base/selection-service.spec.d.ts.map +1 -0
- package/lib/base/selection-service.spec.js +281 -0
- package/lib/base/selection-service.spec.js.map +1 -0
- package/lib/base/tool-manager/glsp-tool-manager.d.ts +3 -3
- package/lib/base/tool-manager/glsp-tool-manager.d.ts.map +1 -1
- package/lib/base/tool-manager/glsp-tool-manager.js +5 -6
- package/lib/base/tool-manager/glsp-tool-manager.js.map +1 -1
- package/lib/base/view/key-tool.d.ts +5 -0
- package/lib/base/view/key-tool.d.ts.map +1 -0
- package/lib/base/view/key-tool.js +36 -0
- package/lib/base/view/key-tool.js.map +1 -0
- package/lib/base/view/mouse-tool.d.ts +19 -0
- package/lib/base/view/mouse-tool.d.ts.map +1 -0
- package/lib/{features/mouse-tool → base/view}/mouse-tool.js +14 -11
- package/lib/base/view/mouse-tool.js.map +1 -0
- package/lib/base/view/view-registry.js +2 -3
- package/lib/base/view/view-registry.js.map +1 -1
- package/lib/{base/container-modules.d.ts → container-modules.d.ts} +2 -2
- package/lib/container-modules.d.ts.map +1 -0
- package/lib/{base/container-modules.js → container-modules.js} +49 -41
- package/lib/container-modules.js.map +1 -0
- package/lib/features/accessibility/move-zoom/move-handler.js +6 -8
- package/lib/features/accessibility/move-zoom/move-handler.js.map +1 -1
- package/lib/features/accessibility/move-zoom/zoom-handler.js +6 -8
- package/lib/features/accessibility/move-zoom/zoom-handler.js.map +1 -1
- package/lib/features/accessibility/resize-key-tool/resize-key-handler.js +4 -5
- package/lib/features/accessibility/resize-key-tool/resize-key-handler.js.map +1 -1
- package/lib/features/accessibility/resize-key-tool/resize-key-tool.d.ts +1 -1
- package/lib/features/accessibility/resize-key-tool/resize-key-tool.d.ts.map +1 -1
- package/lib/features/accessibility/resize-key-tool/resize-key-tool.js +6 -8
- package/lib/features/accessibility/resize-key-tool/resize-key-tool.js.map +1 -1
- package/lib/features/accessibility/search/search-palette.js +3 -4
- package/lib/features/accessibility/search/search-palette.js.map +1 -1
- package/lib/features/accessibility/search/search-tool.js +2 -3
- package/lib/features/accessibility/search/search-tool.js.map +1 -1
- package/lib/features/accessibility/view-key-tools/deselect-key-tool.js +2 -3
- package/lib/features/accessibility/view-key-tools/deselect-key-tool.js.map +1 -1
- package/lib/features/accessibility/view-key-tools/movement-key-tool.d.ts +1 -1
- package/lib/features/accessibility/view-key-tools/movement-key-tool.d.ts.map +1 -1
- package/lib/features/accessibility/view-key-tools/movement-key-tool.js +5 -6
- package/lib/features/accessibility/view-key-tools/movement-key-tool.js.map +1 -1
- package/lib/features/accessibility/view-key-tools/zoom-key-tool.d.ts +1 -1
- package/lib/features/accessibility/view-key-tools/zoom-key-tool.d.ts.map +1 -1
- package/lib/features/accessibility/view-key-tools/zoom-key-tool.js +5 -6
- package/lib/features/accessibility/view-key-tools/zoom-key-tool.js.map +1 -1
- package/lib/features/autocomplete-palette/base-autocomplete-palette.js +1 -1
- package/lib/features/autocomplete-palette/base-autocomplete-palette.js.map +1 -1
- package/lib/features/bounds/freeform-layout.js +2 -3
- package/lib/features/bounds/freeform-layout.js.map +1 -1
- package/lib/features/bounds/freeform-layout.spec.d.ts +3 -0
- package/lib/features/bounds/freeform-layout.spec.d.ts.map +1 -0
- package/lib/features/bounds/freeform-layout.spec.js +201 -0
- package/lib/features/bounds/freeform-layout.spec.js.map +1 -0
- package/lib/features/bounds/glsp-hidden-bounds-updater.js +2 -3
- package/lib/features/bounds/glsp-hidden-bounds-updater.js.map +1 -1
- package/lib/features/bounds/hbox-layout.js +2 -3
- package/lib/features/bounds/hbox-layout.js.map +1 -1
- package/lib/features/bounds/hbox-layout.spec.d.ts +3 -0
- package/lib/features/bounds/hbox-layout.spec.d.ts.map +1 -0
- package/lib/features/bounds/hbox-layout.spec.js +160 -0
- package/lib/features/bounds/hbox-layout.spec.js.map +1 -0
- package/lib/features/bounds/layouter-test-util.spec.d.ts +32 -0
- package/lib/features/bounds/layouter-test-util.spec.d.ts.map +1 -0
- package/lib/features/bounds/layouter-test-util.spec.js +96 -0
- package/lib/features/bounds/layouter-test-util.spec.js.map +1 -0
- package/lib/features/bounds/layouter.js +2 -3
- package/lib/features/bounds/layouter.js.map +1 -1
- package/lib/features/bounds/vbox-layout.js +2 -3
- package/lib/features/bounds/vbox-layout.js.map +1 -1
- package/lib/features/bounds/vbox-layout.spec.d.ts +3 -0
- package/lib/features/bounds/vbox-layout.spec.d.ts.map +1 -0
- package/lib/features/bounds/vbox-layout.spec.js +160 -0
- package/lib/features/bounds/vbox-layout.spec.js.map +1 -0
- package/lib/features/change-bounds/model.js +2 -2
- package/lib/features/change-bounds/model.js.map +1 -1
- package/lib/features/change-bounds/movement-restrictor.d.ts +1 -1
- package/lib/features/change-bounds/movement-restrictor.d.ts.map +1 -1
- package/lib/features/change-bounds/movement-restrictor.js +3 -4
- package/lib/features/change-bounds/movement-restrictor.js.map +1 -1
- package/lib/features/change-bounds/snap.js +2 -3
- package/lib/features/change-bounds/snap.js.map +1 -1
- package/lib/features/{rank/model.d.ts → change-bounds/snap.spec.d.ts} +3 -8
- package/lib/features/change-bounds/snap.spec.d.ts.map +1 -0
- package/lib/features/change-bounds/snap.spec.js +82 -0
- package/lib/features/change-bounds/snap.spec.js.map +1 -0
- package/lib/features/command-palette/command-palette-tool.js +2 -3
- package/lib/features/command-palette/command-palette-tool.js.map +1 -1
- package/lib/features/command-palette/server-command-palette-provider.js +3 -4
- package/lib/features/command-palette/server-command-palette-provider.js.map +1 -1
- package/lib/features/context-menu/delete-element-context-menu.js +2 -3
- package/lib/features/context-menu/delete-element-context-menu.js.map +1 -1
- package/lib/features/context-menu/selection-service-aware-context-menu-mouse-listener.d.ts +1 -1
- 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 +4 -5
- package/lib/features/context-menu/selection-service-aware-context-menu-mouse-listener.js.map +1 -1
- package/lib/features/context-menu/server-context-menu-provider.js +3 -4
- package/lib/features/context-menu/server-context-menu-provider.js.map +1 -1
- package/lib/features/copy-paste/copy-paste-context-menu.js +6 -8
- package/lib/features/copy-paste/copy-paste-context-menu.js.map +1 -1
- package/lib/features/copy-paste/copy-paste-handler.js +4 -6
- package/lib/features/copy-paste/copy-paste-handler.js.map +1 -1
- package/lib/features/decoration/decoration-placer.js +2 -3
- package/lib/features/decoration/decoration-placer.js.map +1 -1
- package/lib/features/edit-label/edit-label-tool.d.ts +0 -3
- package/lib/features/edit-label/edit-label-tool.d.ts.map +1 -1
- package/lib/features/edit-label/edit-label-tool.js +3 -11
- package/lib/features/edit-label/edit-label-tool.js.map +1 -1
- package/lib/features/edit-label/edit-label-validator.js +5 -7
- package/lib/features/edit-label/edit-label-validator.js.map +1 -1
- package/lib/features/export/glsp-svg-exporter.js +2 -3
- package/lib/features/export/glsp-svg-exporter.js.map +1 -1
- package/lib/features/hints/type-hints.d.ts +2 -2
- package/lib/features/hints/type-hints.d.ts.map +1 -1
- package/lib/features/hints/type-hints.js +9 -11
- package/lib/features/hints/type-hints.js.map +1 -1
- package/lib/features/hover/hover.d.ts.map +1 -1
- package/lib/features/hover/hover.js +3 -4
- package/lib/features/hover/hover.js.map +1 -1
- package/lib/features/layout/di.config.js +1 -1
- package/lib/features/layout/di.config.js.map +1 -1
- package/lib/features/layout/layout-elements-action.d.ts +1 -1
- package/lib/features/layout/layout-elements-action.d.ts.map +1 -1
- package/lib/features/layout/layout-elements-action.js +14 -17
- package/lib/features/layout/layout-elements-action.js.map +1 -1
- 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-elements-action.spec.js +321 -0
- package/lib/features/layout/layout-elements-action.spec.js.map +1 -0
- package/lib/features/navigation/navigation-action-handler.js +5 -6
- package/lib/features/navigation/navigation-action-handler.js.map +1 -1
- package/lib/features/navigation/navigation-target-resolver.js +2 -3
- package/lib/features/navigation/navigation-target-resolver.js.map +1 -1
- package/lib/features/navigation/navigation-target-resolver.spec.d.ts +3 -0
- package/lib/features/navigation/navigation-target-resolver.spec.d.ts.map +1 -0
- package/lib/features/navigation/navigation-target-resolver.spec.js +53 -0
- package/lib/features/navigation/navigation-target-resolver.spec.js.map +1 -0
- package/lib/features/routing/di.config.d.ts +22 -0
- package/lib/features/routing/di.config.d.ts.map +1 -0
- package/lib/features/routing/di.config.js +57 -0
- package/lib/features/routing/di.config.js.map +1 -0
- package/lib/features/routing/glsp-manhattan-edge-router.d.ts.map +1 -0
- package/lib/features/routing/glsp-manhattan-edge-router.js.map +1 -0
- package/lib/features/select/di.config.d.ts.map +1 -1
- package/lib/features/select/di.config.js +3 -5
- package/lib/features/select/di.config.js.map +1 -1
- package/lib/features/select/select-feedback-command.d.ts +12 -0
- package/lib/features/select/select-feedback-command.d.ts.map +1 -0
- package/lib/features/select/{select-feedback-action.js → select-feedback-command.js} +6 -30
- package/lib/features/select/select-feedback-command.js.map +1 -0
- package/lib/features/select/select-mouse-listener.d.ts +1 -1
- package/lib/features/select/select-mouse-listener.d.ts.map +1 -1
- package/lib/features/select/select-mouse-listener.js +2 -2
- package/lib/features/select/select-mouse-listener.js.map +1 -1
- package/lib/features/source-model-watcher/source-model-changed-action-handler.js +5 -7
- package/lib/features/source-model-watcher/source-model-changed-action-handler.js.map +1 -1
- package/lib/features/svg-metadata/metadata-placer.js +2 -3
- package/lib/features/svg-metadata/metadata-placer.js.map +1 -1
- package/lib/features/tool-palette/tool-palette.d.ts +4 -4
- package/lib/features/tool-palette/tool-palette.d.ts.map +1 -1
- package/lib/features/tool-palette/tool-palette.js +12 -13
- package/lib/features/tool-palette/tool-palette.js.map +1 -1
- package/lib/features/tools/base-glsp-creation-tool.d.ts +10 -0
- package/lib/features/tools/base-glsp-creation-tool.d.ts.map +1 -0
- package/lib/features/tools/base-glsp-creation-tool.js +45 -0
- package/lib/features/tools/base-glsp-creation-tool.js.map +1 -0
- package/lib/features/tools/base-glsp-tool.d.ts +26 -8
- package/lib/features/tools/base-glsp-tool.d.ts.map +1 -1
- package/lib/features/tools/base-glsp-tool.js +34 -11
- package/lib/features/tools/base-glsp-tool.js.map +1 -1
- package/lib/features/{tool-feedback → tools/change-bounds}/change-bounds-tool-feedback.d.ts +12 -5
- package/lib/features/tools/change-bounds/change-bounds-tool-feedback.d.ts.map +1 -0
- package/lib/features/{tool-feedback → tools/change-bounds}/change-bounds-tool-feedback.js +45 -27
- package/lib/features/tools/change-bounds/change-bounds-tool-feedback.js.map +1 -0
- package/lib/features/tools/{change-bounds-tool.d.ts → change-bounds/change-bounds-tool.d.ts} +13 -14
- package/lib/features/tools/change-bounds/change-bounds-tool.d.ts.map +1 -0
- package/lib/features/tools/{change-bounds-tool.js → change-bounds/change-bounds-tool.js} +50 -35
- package/lib/features/tools/change-bounds/change-bounds-tool.js.map +1 -0
- package/lib/features/tools/change-bounds/di.config.d.ts +19 -0
- package/lib/features/tools/change-bounds/di.config.d.ts.map +1 -0
- package/lib/features/tools/change-bounds/di.config.js +32 -0
- package/lib/features/tools/change-bounds/di.config.js.map +1 -0
- package/lib/features/tools/change-bounds/view.d.ts +9 -0
- package/lib/features/tools/change-bounds/view.d.ts.map +1 -0
- package/lib/features/{tool-feedback → tools/change-bounds}/view.js +5 -21
- package/lib/features/tools/change-bounds/view.js.map +1 -0
- package/lib/features/tools/{delete-tool.d.ts → deletion/delete-tool.d.ts} +4 -9
- package/lib/features/tools/deletion/delete-tool.d.ts.map +1 -0
- package/lib/features/tools/{delete-tool.js → deletion/delete-tool.js} +13 -29
- package/lib/features/tools/deletion/delete-tool.js.map +1 -0
- package/lib/features/{tool-feedback → tools/deletion}/di.config.d.ts +2 -2
- package/lib/features/tools/deletion/di.config.d.ts.map +1 -0
- package/lib/features/{mouse-tool → tools/deletion}/di.config.js +7 -7
- package/lib/features/tools/deletion/di.config.js.map +1 -0
- package/lib/features/{tool-feedback/creation-tool-feedback.d.ts → tools/edge-creation/dangling-edge-feedback.d.ts} +5 -10
- package/lib/features/tools/edge-creation/dangling-edge-feedback.d.ts.map +1 -0
- package/lib/features/{tool-feedback/creation-tool-feedback.js → tools/edge-creation/dangling-edge-feedback.js} +25 -87
- package/lib/features/tools/edge-creation/dangling-edge-feedback.js.map +1 -0
- package/lib/features/tools/edge-creation/di.config.d.ts +19 -0
- package/lib/features/tools/edge-creation/di.config.d.ts.map +1 -0
- package/lib/features/tools/edge-creation/di.config.js +29 -0
- package/lib/features/tools/edge-creation/di.config.js.map +1 -0
- package/lib/features/tools/edge-creation/edge-creation-tool-feedback.d.ts +26 -0
- package/lib/features/tools/edge-creation/edge-creation-tool-feedback.d.ts.map +1 -0
- package/lib/features/tools/edge-creation/edge-creation-tool-feedback.js +74 -0
- package/lib/features/tools/edge-creation/edge-creation-tool-feedback.js.map +1 -0
- package/lib/features/tools/{edge-creation-tool.d.ts → edge-creation/edge-creation-tool.d.ts} +6 -11
- package/lib/features/tools/edge-creation/edge-creation-tool.d.ts.map +1 -0
- package/lib/features/tools/{edge-creation-tool.js → edge-creation/edge-creation-tool.js} +29 -40
- package/lib/features/tools/edge-creation/edge-creation-tool.js.map +1 -0
- package/lib/features/tools/edge-creation/view.d.ts +10 -0
- package/lib/features/tools/edge-creation/view.d.ts.map +1 -0
- package/lib/features/tools/edge-creation/view.js +43 -0
- package/lib/features/tools/edge-creation/view.js.map +1 -0
- package/lib/features/{mouse-tool → tools/edge-edit}/di.config.d.ts +2 -2
- package/lib/features/tools/edge-edit/di.config.d.ts.map +1 -0
- package/lib/features/tools/edge-edit/di.config.js +35 -0
- package/lib/features/tools/edge-edit/di.config.js.map +1 -0
- package/lib/features/{tool-feedback → tools/edge-edit}/edge-edit-tool-feedback.d.ts +14 -8
- package/lib/features/tools/edge-edit/edge-edit-tool-feedback.d.ts.map +1 -0
- package/lib/features/{tool-feedback → tools/edge-edit}/edge-edit-tool-feedback.js +42 -37
- package/lib/features/tools/edge-edit/edge-edit-tool-feedback.js.map +1 -0
- package/lib/features/tools/{edge-edit-tool.d.ts → edge-edit/edge-edit-tool.d.ts} +7 -9
- package/lib/features/tools/edge-edit/edge-edit-tool.d.ts.map +1 -0
- package/lib/features/tools/{edge-edit-tool.js → edge-edit/edge-edit-tool.js} +28 -33
- package/lib/features/tools/edge-edit/edge-edit-tool.js.map +1 -0
- package/lib/features/tools/enable-default-tools-on-focus-loss.d.ts +21 -0
- package/lib/features/tools/enable-default-tools-on-focus-loss.d.ts.map +1 -1
- package/lib/features/tools/enable-default-tools-on-focus-loss.js +9 -3
- package/lib/features/tools/enable-default-tools-on-focus-loss.js.map +1 -1
- package/lib/features/tools/marquee-selection/di.config.d.ts +19 -0
- package/lib/features/tools/marquee-selection/di.config.d.ts.map +1 -0
- package/lib/features/tools/marquee-selection/di.config.js +34 -0
- package/lib/features/tools/marquee-selection/di.config.js.map +1 -0
- package/lib/features/tools/{marquee-behavior.d.ts → marquee-selection/marquee-behavior.d.ts} +10 -10
- package/lib/features/tools/marquee-selection/marquee-behavior.d.ts.map +1 -0
- package/lib/features/tools/{marquee-behavior.js → marquee-selection/marquee-behavior.js} +2 -2
- package/lib/features/tools/marquee-selection/marquee-behavior.js.map +1 -0
- package/lib/features/tools/marquee-selection/marquee-behavior.spec.d.ts +17 -0
- package/lib/features/tools/marquee-selection/marquee-behavior.spec.d.ts.map +1 -0
- package/lib/features/tools/marquee-selection/marquee-behavior.spec.js +165 -0
- package/lib/features/tools/marquee-selection/marquee-behavior.spec.js.map +1 -0
- package/lib/features/tools/{marquee-mouse-tool.d.ts → marquee-selection/marquee-mouse-tool.d.ts} +4 -6
- package/lib/features/tools/marquee-selection/marquee-mouse-tool.d.ts.map +1 -0
- package/lib/features/tools/{marquee-mouse-tool.js → marquee-selection/marquee-mouse-tool.js} +12 -22
- package/lib/features/tools/marquee-selection/marquee-mouse-tool.js.map +1 -0
- package/lib/features/{tool-feedback → tools/marquee-selection}/marquee-tool-feedback.d.ts +2 -2
- package/lib/features/tools/marquee-selection/marquee-tool-feedback.d.ts.map +1 -0
- package/lib/features/{tool-feedback → tools/marquee-selection}/marquee-tool-feedback.js +8 -10
- package/lib/features/tools/marquee-selection/marquee-tool-feedback.js.map +1 -0
- package/lib/features/tools/marquee-selection/marquee-tool.d.ts +12 -0
- package/lib/features/tools/marquee-selection/marquee-tool.d.ts.map +1 -0
- package/lib/features/tools/{marquee-tool.js → marquee-selection/marquee-tool.js} +8 -20
- package/lib/features/tools/marquee-selection/marquee-tool.js.map +1 -0
- package/lib/features/tools/{model.d.ts → marquee-selection/model.d.ts} +1 -1
- package/lib/features/tools/marquee-selection/model.d.ts.map +1 -0
- package/lib/features/tools/{model.js → marquee-selection/model.js} +2 -2
- package/lib/features/tools/marquee-selection/model.js.map +1 -0
- package/lib/features/tools/{view.d.ts → marquee-selection/view.d.ts} +1 -1
- package/lib/features/tools/marquee-selection/view.d.ts.map +1 -0
- package/lib/features/tools/{view.js → marquee-selection/view.js} +3 -4
- package/lib/features/tools/marquee-selection/view.js.map +1 -0
- package/lib/features/tools/node-creation/di.config.d.ts +19 -0
- package/lib/features/tools/node-creation/di.config.d.ts.map +1 -0
- package/lib/features/{rank/model.js → tools/node-creation/di.config.js} +12 -13
- package/lib/features/tools/node-creation/di.config.js.map +1 -0
- package/lib/features/tools/{node-creation-tool.d.ts → node-creation/node-creation-tool.d.ts} +7 -10
- package/lib/features/tools/node-creation/node-creation-tool.d.ts.map +1 -0
- package/lib/features/tools/{node-creation-tool.js → node-creation/node-creation-tool.js} +17 -30
- package/lib/features/tools/node-creation/node-creation-tool.js.map +1 -0
- package/lib/features/validation/marker-navigator.d.ts +4 -3
- package/lib/features/validation/marker-navigator.d.ts.map +1 -1
- package/lib/features/validation/marker-navigator.js +16 -20
- package/lib/features/validation/marker-navigator.js.map +1 -1
- package/lib/features/validation/marker-navigator.spec.d.ts +3 -0
- package/lib/features/validation/marker-navigator.spec.d.ts.map +1 -0
- package/lib/features/validation/marker-navigator.spec.js +182 -0
- package/lib/features/validation/marker-navigator.spec.js.map +1 -0
- package/lib/features/validation/validate.d.ts +2 -2
- package/lib/features/validation/validate.d.ts.map +1 -1
- package/lib/features/validation/validate.js +12 -17
- package/lib/features/validation/validate.js.map +1 -1
- package/lib/features/viewport/glsp-scroll-mouse-listener.js +3 -4
- package/lib/features/viewport/glsp-scroll-mouse-listener.js.map +1 -1
- package/lib/glsp-sprotty/index.d.ts +1 -1
- package/lib/glsp-sprotty/index.d.ts.map +1 -1
- package/lib/glsp-sprotty/index.js +26 -25
- package/lib/glsp-sprotty/index.js.map +1 -1
- package/lib/glsp-sprotty/types.d.ts +4 -8
- package/lib/glsp-sprotty/types.d.ts.map +1 -1
- package/lib/glsp-sprotty/types.js +1 -1
- package/lib/glsp-sprotty/types.js.map +1 -1
- package/lib/index.d.ts +36 -27
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +58 -46
- package/lib/index.js.map +1 -1
- package/lib/lib/model.js +1 -1
- package/lib/lib/model.js.map +1 -1
- package/lib/model-source/glsp-diagram-server.d.ts.map +1 -1
- package/lib/model-source/glsp-diagram-server.js +5 -3
- package/lib/model-source/glsp-diagram-server.js.map +1 -1
- package/lib/utils/argument-utils.js +3 -3
- package/lib/utils/argument-utils.js.map +1 -1
- package/lib/utils/marker.js +1 -1
- package/lib/utils/marker.js.map +1 -1
- package/lib/utils/smodel-util.spec.d.ts +2 -0
- package/lib/utils/smodel-util.spec.d.ts.map +1 -0
- package/lib/utils/smodel-util.spec.js +184 -0
- package/lib/utils/smodel-util.spec.js.map +1 -0
- package/lib/utils/viewpoint-util.d.ts +20 -1
- package/lib/utils/viewpoint-util.d.ts.map +1 -1
- package/lib/utils/viewpoint-util.js +30 -1
- package/lib/utils/viewpoint-util.js.map +1 -1
- package/lib/views/compartments.js +2 -3
- package/lib/views/compartments.js.map +1 -1
- package/lib/views/glsp-edge-view.js +2 -3
- package/lib/views/glsp-edge-view.js.map +1 -1
- package/lib/views/glsp-projection-view.js +2 -3
- package/lib/views/glsp-projection-view.js.map +1 -1
- package/lib/views/issue-marker-view.js +2 -3
- package/lib/views/issue-marker-view.js.map +1 -1
- package/lib/views/rounded-corner-view.js +2 -3
- package/lib/views/rounded-corner-view.js.map +1 -1
- package/package.json +3 -3
- package/src/base/action-dispatcher.ts +3 -1
- package/src/base/command-stack.ts +55 -3
- package/src/base/di.config.ts +34 -9
- package/src/base/drag-aware-mouse-listener.ts +2 -2
- package/src/base/editor-context-service.ts +28 -13
- package/src/{features/tool-feedback → base/feedback}/css-feedback.ts +1 -1
- package/src/{features/tool-feedback → base/feedback}/feedback-action-dispatcher.ts +31 -23
- package/src/base/{model → feedback}/update-model-command.ts +3 -29
- package/src/base/ranked.ts +42 -0
- package/src/{features/select → base}/selection-service.spec.ts +51 -121
- package/src/{features/select → base}/selection-service.ts +82 -31
- package/src/base/tool-manager/glsp-tool-manager.ts +4 -4
- package/src/{features/rank/model.ts → base/view/key-tool.ts} +9 -13
- package/src/{features/mouse-tool → base/view}/mouse-tool.ts +14 -15
- package/src/{base/container-modules.ts → container-modules.ts} +33 -26
- package/src/features/accessibility/resize-key-tool/resize-key-tool.ts +2 -2
- package/src/features/accessibility/search/search-palette.ts +1 -1
- package/src/features/accessibility/view-key-tools/movement-key-tool.ts +2 -2
- package/src/features/accessibility/view-key-tools/zoom-key-tool.ts +3 -3
- package/src/features/bounds/layouter-test-util.spec.ts +1 -1
- package/src/features/change-bounds/movement-restrictor.ts +1 -1
- package/src/features/context-menu/selection-service-aware-context-menu-mouse-listener.ts +2 -2
- package/src/features/copy-paste/copy-paste-context-menu.ts +1 -1
- package/src/features/edit-label/edit-label-tool.ts +4 -12
- package/src/features/hints/type-hints.ts +2 -2
- package/src/features/hover/hover.ts +2 -1
- package/src/features/layout/di.config.ts +1 -1
- package/src/features/layout/layout-elements-action.spec.ts +1 -3
- package/src/features/layout/layout-elements-action.ts +2 -2
- package/src/features/navigation/navigation-action-handler.ts +1 -1
- package/src/features/routing/di.config.ts +82 -0
- package/src/features/select/di.config.ts +2 -4
- package/src/features/select/{select-feedback-action.ts → select-feedback-command.ts} +2 -38
- package/src/features/select/select-mouse-listener.ts +2 -2
- package/src/features/source-model-watcher/source-model-changed-action-handler.ts +1 -1
- package/src/features/tool-palette/tool-palette.ts +12 -12
- package/src/features/tools/base-glsp-creation-tool.ts +40 -0
- package/src/features/tools/base-glsp-tool.ts +32 -10
- package/src/features/{tool-feedback → tools/change-bounds}/change-bounds-tool-feedback.ts +52 -21
- package/src/features/tools/{change-bounds-tool.ts → change-bounds/change-bounds-tool.ts} +64 -35
- package/src/features/tools/change-bounds/di.config.ts +31 -0
- package/src/features/{tool-feedback → tools/change-bounds}/view.tsx +2 -14
- package/src/features/tools/{delete-tool.ts → deletion/delete-tool.ts} +8 -18
- package/src/features/{mouse-tool → tools/deletion}/di.config.ts +7 -7
- package/src/features/{tool-feedback/creation-tool-feedback.ts → tools/edge-creation/dangling-edge-feedback.ts} +18 -88
- package/src/features/tools/edge-creation/di.config.ts +28 -0
- package/src/features/tools/edge-creation/edge-creation-tool-feedback.ts +89 -0
- package/src/features/tools/{edge-creation-tool.ts → edge-creation/edge-creation-tool.ts} +26 -43
- package/src/features/tools/edge-creation/view.tsx +33 -0
- package/src/features/tools/edge-edit/di.config.ts +41 -0
- package/src/features/{tool-feedback → tools/edge-edit}/edge-edit-tool-feedback.ts +27 -15
- package/src/features/tools/{edge-edit-tool.ts → edge-edit/edge-edit-tool.ts} +29 -27
- package/src/features/tools/enable-default-tools-on-focus-loss.ts +11 -2
- package/src/features/tools/marquee-selection/di.config.ts +35 -0
- package/src/features/tools/{marquee-behavior.ts → marquee-selection/marquee-behavior.ts} +9 -9
- package/src/features/tools/{marquee-mouse-tool.ts → marquee-selection/marquee-mouse-tool.ts} +11 -17
- package/src/features/{tool-feedback → tools/marquee-selection}/marquee-tool-feedback.ts +1 -1
- package/src/features/tools/{marquee-tool.ts → marquee-selection/marquee-tool.ts} +5 -11
- package/{lib/features/tools/di.config.d.ts → src/features/tools/node-creation/di.config.ts} +10 -12
- package/src/features/tools/{node-creation-tool.ts → node-creation/node-creation-tool.ts} +14 -31
- package/src/features/validation/marker-navigator.ts +5 -5
- package/src/features/validation/validate.ts +2 -2
- package/src/features/viewport/glsp-scroll-mouse-listener.ts +1 -1
- package/src/glsp-sprotty/index.ts +1 -1
- package/src/glsp-sprotty/types.ts +2 -4
- package/src/index.ts +63 -49
- package/src/model-source/glsp-diagram-server.ts +7 -1
- package/src/utils/smodel-util.spec.ts +3 -3
- package/src/utils/viewpoint-util.ts +32 -0
- package/lib/base/container-modules.d.ts.map +0 -1
- package/lib/base/container-modules.js.map +0 -1
- package/lib/base/model/update-model-command.d.ts.map +0 -1
- package/lib/base/model/update-model-command.js.map +0 -1
- package/lib/features/mouse-tool/di.config.d.ts.map +0 -1
- package/lib/features/mouse-tool/di.config.js.map +0 -1
- package/lib/features/mouse-tool/mouse-tool.d.ts +0 -22
- package/lib/features/mouse-tool/mouse-tool.d.ts.map +0 -1
- package/lib/features/mouse-tool/mouse-tool.js.map +0 -1
- package/lib/features/rank/model.d.ts.map +0 -1
- package/lib/features/rank/model.js.map +0 -1
- package/lib/features/select/select-feedback-action.d.ts +0 -25
- package/lib/features/select/select-feedback-action.d.ts.map +0 -1
- package/lib/features/select/select-feedback-action.js.map +0 -1
- package/lib/features/select/selection-service.d.ts.map +0 -1
- package/lib/features/select/selection-service.js.map +0 -1
- package/lib/features/tool-feedback/change-bounds-tool-feedback.d.ts.map +0 -1
- package/lib/features/tool-feedback/change-bounds-tool-feedback.js.map +0 -1
- package/lib/features/tool-feedback/creation-tool-feedback.d.ts.map +0 -1
- package/lib/features/tool-feedback/creation-tool-feedback.js.map +0 -1
- package/lib/features/tool-feedback/css-feedback.d.ts.map +0 -1
- package/lib/features/tool-feedback/css-feedback.js.map +0 -1
- package/lib/features/tool-feedback/di.config.d.ts.map +0 -1
- package/lib/features/tool-feedback/di.config.js +0 -53
- package/lib/features/tool-feedback/di.config.js.map +0 -1
- package/lib/features/tool-feedback/edge-edit-tool-feedback.d.ts.map +0 -1
- package/lib/features/tool-feedback/edge-edit-tool-feedback.js.map +0 -1
- package/lib/features/tool-feedback/feedback-action-dispatcher.d.ts.map +0 -1
- package/lib/features/tool-feedback/feedback-action-dispatcher.js.map +0 -1
- package/lib/features/tool-feedback/marquee-tool-feedback.d.ts.map +0 -1
- package/lib/features/tool-feedback/marquee-tool-feedback.js.map +0 -1
- package/lib/features/tool-feedback/model.d.ts.map +0 -1
- package/lib/features/tool-feedback/model.js.map +0 -1
- package/lib/features/tool-feedback/view.d.ts +0 -16
- package/lib/features/tool-feedback/view.d.ts.map +0 -1
- package/lib/features/tool-feedback/view.js.map +0 -1
- package/lib/features/tools/change-bounds-tool.d.ts.map +0 -1
- package/lib/features/tools/change-bounds-tool.js.map +0 -1
- package/lib/features/tools/delete-tool.d.ts.map +0 -1
- package/lib/features/tools/delete-tool.js.map +0 -1
- package/lib/features/tools/di.config.d.ts.map +0 -1
- package/lib/features/tools/di.config.js +0 -66
- package/lib/features/tools/di.config.js.map +0 -1
- package/lib/features/tools/edge-creation-tool.d.ts.map +0 -1
- package/lib/features/tools/edge-creation-tool.js.map +0 -1
- package/lib/features/tools/edge-edit-tool.d.ts.map +0 -1
- package/lib/features/tools/edge-edit-tool.js.map +0 -1
- package/lib/features/tools/glsp-manhattan-edge-router.d.ts.map +0 -1
- package/lib/features/tools/glsp-manhattan-edge-router.js.map +0 -1
- package/lib/features/tools/marquee-behavior.d.ts.map +0 -1
- package/lib/features/tools/marquee-behavior.js.map +0 -1
- package/lib/features/tools/marquee-mouse-tool.d.ts.map +0 -1
- package/lib/features/tools/marquee-mouse-tool.js.map +0 -1
- package/lib/features/tools/marquee-tool.d.ts +0 -14
- package/lib/features/tools/marquee-tool.d.ts.map +0 -1
- package/lib/features/tools/marquee-tool.js.map +0 -1
- package/lib/features/tools/model.d.ts.map +0 -1
- package/lib/features/tools/model.js.map +0 -1
- package/lib/features/tools/node-creation-tool.d.ts.map +0 -1
- package/lib/features/tools/node-creation-tool.js.map +0 -1
- package/lib/features/tools/view.d.ts.map +0 -1
- package/lib/features/tools/view.js.map +0 -1
- package/src/features/tool-feedback/di.config.ts +0 -65
- package/src/features/tools/di.config.ts +0 -77
- /package/lib/features/{tools → routing}/glsp-manhattan-edge-router.d.ts +0 -0
- /package/lib/features/{tools → routing}/glsp-manhattan-edge-router.js +0 -0
- /package/src/{features/tool-feedback/model.ts → base/feedback/feedback-command.ts} +0 -0
- /package/src/features/{tools → routing}/glsp-manhattan-edge-router.ts +0 -0
- /package/src/features/tools/{marquee-behavior.spec.ts → marquee-selection/marquee-behavior.spec.ts} +0 -0
- /package/src/features/tools/{model.ts → marquee-selection/model.ts} +0 -0
- /package/src/features/tools/{view.tsx → marquee-selection/view.tsx} +0 -0
|
@@ -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.
|
|
15
|
+
exports.configureDanglingFeedbackEdge = exports.removeDanglingFeedbackEdge = exports.drawFeedbackEdge = exports.defaultFeedbackEdgeSchema = exports.feedbackEdgeEndId = exports.feedbackEdgeId = exports.FeedbackEdgeEnd = exports.RemoveFeedbackEdgeCommand = exports.RemoveFeedbackEdgeAction = exports.DrawFeedbackEdgeCommand = exports.DrawFeedbackEdgeAction = void 0;
|
|
16
16
|
/********************************************************************************
|
|
17
17
|
* Copyright (c) 2019-2023 EclipseSource and others.
|
|
18
18
|
*
|
|
@@ -29,10 +29,11 @@ exports.removeFeedbackEdge = exports.drawFeedbackEdge = exports.defaultFeedbackE
|
|
|
29
29
|
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
|
|
30
30
|
********************************************************************************/
|
|
31
31
|
const inversify_1 = require("inversify");
|
|
32
|
-
const _glsp_sprotty_1 = require("
|
|
33
|
-
const
|
|
34
|
-
const
|
|
35
|
-
const
|
|
32
|
+
const _glsp_sprotty_1 = require("../../../glsp-sprotty/index");
|
|
33
|
+
const feedback_command_1 = require("../../../base/feedback/feedback-command");
|
|
34
|
+
const smodel_util_1 = require("../../../utils/smodel-util");
|
|
35
|
+
const viewpoint_util_1 = require("../../../utils/viewpoint-util");
|
|
36
|
+
const view_1 = require("./view");
|
|
36
37
|
var DrawFeedbackEdgeAction;
|
|
37
38
|
(function (DrawFeedbackEdgeAction) {
|
|
38
39
|
DrawFeedbackEdgeAction.KIND = 'drawFeedbackEdge';
|
|
@@ -44,8 +45,8 @@ var DrawFeedbackEdgeAction;
|
|
|
44
45
|
return Object.assign({ kind: DrawFeedbackEdgeAction.KIND }, options);
|
|
45
46
|
}
|
|
46
47
|
DrawFeedbackEdgeAction.create = create;
|
|
47
|
-
})(DrawFeedbackEdgeAction
|
|
48
|
-
let DrawFeedbackEdgeCommand = class DrawFeedbackEdgeCommand extends
|
|
48
|
+
})(DrawFeedbackEdgeAction || (exports.DrawFeedbackEdgeAction = DrawFeedbackEdgeAction = {}));
|
|
49
|
+
let DrawFeedbackEdgeCommand = exports.DrawFeedbackEdgeCommand = class DrawFeedbackEdgeCommand extends feedback_command_1.FeedbackCommand {
|
|
49
50
|
constructor(action) {
|
|
50
51
|
super();
|
|
51
52
|
this.action = action;
|
|
@@ -56,12 +57,11 @@ let DrawFeedbackEdgeCommand = class DrawFeedbackEdgeCommand extends model_1.Feed
|
|
|
56
57
|
}
|
|
57
58
|
};
|
|
58
59
|
DrawFeedbackEdgeCommand.KIND = DrawFeedbackEdgeAction.KIND;
|
|
59
|
-
DrawFeedbackEdgeCommand = __decorate([
|
|
60
|
+
exports.DrawFeedbackEdgeCommand = DrawFeedbackEdgeCommand = __decorate([
|
|
60
61
|
(0, inversify_1.injectable)(),
|
|
61
62
|
__param(0, (0, inversify_1.inject)(_glsp_sprotty_1.TYPES.Action)),
|
|
62
63
|
__metadata("design:paramtypes", [Object])
|
|
63
64
|
], DrawFeedbackEdgeCommand);
|
|
64
|
-
exports.DrawFeedbackEdgeCommand = DrawFeedbackEdgeCommand;
|
|
65
65
|
var RemoveFeedbackEdgeAction;
|
|
66
66
|
(function (RemoveFeedbackEdgeAction) {
|
|
67
67
|
RemoveFeedbackEdgeAction.KIND = 'removeFeedbackEdgeCommand';
|
|
@@ -73,18 +73,17 @@ var RemoveFeedbackEdgeAction;
|
|
|
73
73
|
return { kind: RemoveFeedbackEdgeAction.KIND };
|
|
74
74
|
}
|
|
75
75
|
RemoveFeedbackEdgeAction.create = create;
|
|
76
|
-
})(RemoveFeedbackEdgeAction
|
|
77
|
-
let RemoveFeedbackEdgeCommand = class RemoveFeedbackEdgeCommand extends
|
|
76
|
+
})(RemoveFeedbackEdgeAction || (exports.RemoveFeedbackEdgeAction = RemoveFeedbackEdgeAction = {}));
|
|
77
|
+
let RemoveFeedbackEdgeCommand = exports.RemoveFeedbackEdgeCommand = class RemoveFeedbackEdgeCommand extends feedback_command_1.FeedbackCommand {
|
|
78
78
|
execute(context) {
|
|
79
|
-
|
|
79
|
+
removeDanglingFeedbackEdge(context.root);
|
|
80
80
|
return context.root;
|
|
81
81
|
}
|
|
82
82
|
};
|
|
83
83
|
RemoveFeedbackEdgeCommand.KIND = RemoveFeedbackEdgeAction.KIND;
|
|
84
|
-
RemoveFeedbackEdgeCommand = __decorate([
|
|
84
|
+
exports.RemoveFeedbackEdgeCommand = RemoveFeedbackEdgeCommand = __decorate([
|
|
85
85
|
(0, inversify_1.injectable)()
|
|
86
86
|
], RemoveFeedbackEdgeCommand);
|
|
87
|
-
exports.RemoveFeedbackEdgeCommand = RemoveFeedbackEdgeCommand;
|
|
88
87
|
class FeedbackEdgeEnd extends _glsp_sprotty_1.SDanglingAnchor {
|
|
89
88
|
constructor(sourceId, elementTypeId, feedbackEdge = undefined, type = FeedbackEdgeEnd.TYPE) {
|
|
90
89
|
super();
|
|
@@ -94,77 +93,8 @@ class FeedbackEdgeEnd extends _glsp_sprotty_1.SDanglingAnchor {
|
|
|
94
93
|
this.type = type;
|
|
95
94
|
}
|
|
96
95
|
}
|
|
97
|
-
FeedbackEdgeEnd.TYPE = 'feedback-edge-end';
|
|
98
96
|
exports.FeedbackEdgeEnd = FeedbackEdgeEnd;
|
|
99
|
-
|
|
100
|
-
constructor(anchorRegistry) {
|
|
101
|
-
super();
|
|
102
|
-
this.anchorRegistry = anchorRegistry;
|
|
103
|
-
}
|
|
104
|
-
mouseMove(target, event) {
|
|
105
|
-
const root = target.root;
|
|
106
|
-
const edgeEnd = root.index.getById(feedbackEdgeEndId(root));
|
|
107
|
-
if (!(edgeEnd instanceof FeedbackEdgeEnd) || !edgeEnd.feedbackEdge) {
|
|
108
|
-
return [];
|
|
109
|
-
}
|
|
110
|
-
const edge = edgeEnd.feedbackEdge;
|
|
111
|
-
const position = (0, viewpoint_util_1.getAbsolutePosition)(edgeEnd, event);
|
|
112
|
-
const endAtMousePosition = (0, _glsp_sprotty_1.findChildrenAtPosition)(target.root, position)
|
|
113
|
-
.reverse()
|
|
114
|
-
.find(element => (0, _glsp_sprotty_1.isConnectable)(element) && element.canConnect(edge, 'target'));
|
|
115
|
-
if (endAtMousePosition instanceof _glsp_sprotty_1.SConnectableElement && edge.source && (0, _glsp_sprotty_1.isBoundsAware)(edge.source)) {
|
|
116
|
-
const anchor = this.computeAbsoluteAnchor(endAtMousePosition, _glsp_sprotty_1.Bounds.center((0, viewpoint_util_1.toAbsoluteBounds)(edge.source)));
|
|
117
|
-
if (_glsp_sprotty_1.Point.euclideanDistance(anchor, edgeEnd.position) > 1) {
|
|
118
|
-
return [_glsp_sprotty_1.MoveAction.create([{ elementId: edgeEnd.id, toPosition: anchor }], { animate: false })];
|
|
119
|
-
}
|
|
120
|
-
}
|
|
121
|
-
else {
|
|
122
|
-
return [_glsp_sprotty_1.MoveAction.create([{ elementId: edgeEnd.id, toPosition: position }], { animate: false })];
|
|
123
|
-
}
|
|
124
|
-
return [];
|
|
125
|
-
}
|
|
126
|
-
computeAbsoluteAnchor(element, absoluteReferencePoint, offset) {
|
|
127
|
-
const referencePointInParent = absoluteToParent(element, absoluteReferencePoint);
|
|
128
|
-
const anchorComputer = this.anchorRegistry.get(_glsp_sprotty_1.PolylineEdgeRouter.KIND, element.anchorKind);
|
|
129
|
-
let anchor = anchorComputer.getAnchor(element, referencePointInParent, offset);
|
|
130
|
-
// The anchor is computed in the local coordinate system of the element.
|
|
131
|
-
// If the element is a nested child element we have to add the absolute position of its parent to the anchor.
|
|
132
|
-
if (element.parent !== element.root) {
|
|
133
|
-
const parent = (0, _glsp_sprotty_1.findParentByFeature)(element.parent, _glsp_sprotty_1.isBoundsAware);
|
|
134
|
-
if (parent) {
|
|
135
|
-
const absoluteParentPosition = (0, viewpoint_util_1.toAbsoluteBounds)(parent);
|
|
136
|
-
anchor = _glsp_sprotty_1.Point.add(absoluteParentPosition, anchor);
|
|
137
|
-
}
|
|
138
|
-
}
|
|
139
|
-
return anchor;
|
|
140
|
-
}
|
|
141
|
-
}
|
|
142
|
-
exports.FeedbackEdgeEndMovingMouseListener = FeedbackEdgeEndMovingMouseListener;
|
|
143
|
-
/**
|
|
144
|
-
* Convert a point, specified in absolute coordinates, to a point relative
|
|
145
|
-
* to the parent of the specified child element.
|
|
146
|
-
* @param element the child element
|
|
147
|
-
* @param absolutePoint a point in absolute coordinates
|
|
148
|
-
* @returns the equivalent point, relative to the element's parent coordinates
|
|
149
|
-
*/
|
|
150
|
-
function absoluteToParent(element, absolutePoint) {
|
|
151
|
-
if ((0, _glsp_sprotty_1.isBoundsAware)(element.parent)) {
|
|
152
|
-
return absoluteToLocal(element.parent, absolutePoint);
|
|
153
|
-
}
|
|
154
|
-
// If the parent is not bounds-aware, assume it's at 0; 0 and proceed
|
|
155
|
-
return absoluteToLocal(element, absolutePoint);
|
|
156
|
-
}
|
|
157
|
-
/**
|
|
158
|
-
* Convert a point, specified in absolute coordinates, to a point relative
|
|
159
|
-
* to the specified element.
|
|
160
|
-
* @param element the element
|
|
161
|
-
* @param absolutePoint a point in absolute coordinates
|
|
162
|
-
* @returns the equivalent point, relative to the element's coordinates
|
|
163
|
-
*/
|
|
164
|
-
function absoluteToLocal(element, absolutePoint) {
|
|
165
|
-
const absoluteElementBounds = (0, viewpoint_util_1.toAbsoluteBounds)(element);
|
|
166
|
-
return { x: absolutePoint.x - absoluteElementBounds.x, y: absolutePoint.y - absoluteElementBounds.y };
|
|
167
|
-
}
|
|
97
|
+
FeedbackEdgeEnd.TYPE = 'feedback-edge-end';
|
|
168
98
|
function feedbackEdgeId(root) {
|
|
169
99
|
return root.id + '_feedback_edge';
|
|
170
100
|
}
|
|
@@ -199,7 +129,7 @@ function drawFeedbackEdge(context, sourceId, elementTypeId, edgeTemplate) {
|
|
|
199
129
|
}
|
|
200
130
|
}
|
|
201
131
|
exports.drawFeedbackEdge = drawFeedbackEdge;
|
|
202
|
-
function
|
|
132
|
+
function removeDanglingFeedbackEdge(root) {
|
|
203
133
|
const feedbackEdge = root.index.getById(feedbackEdgeId(root));
|
|
204
134
|
const feedbackEdgeEnd = root.index.getById(feedbackEdgeEndId(root));
|
|
205
135
|
if (feedbackEdge instanceof _glsp_sprotty_1.SChildElement) {
|
|
@@ -209,5 +139,13 @@ function removeFeedbackEdge(root) {
|
|
|
209
139
|
root.remove(feedbackEdgeEnd);
|
|
210
140
|
}
|
|
211
141
|
}
|
|
212
|
-
exports.
|
|
213
|
-
|
|
142
|
+
exports.removeDanglingFeedbackEdge = removeDanglingFeedbackEdge;
|
|
143
|
+
function configureDanglingFeedbackEdge(context) {
|
|
144
|
+
if (!context.isBound(DrawFeedbackEdgeCommand) && !context.isBound(RemoveFeedbackEdgeCommand) && !context.isBound(view_1.FeedbackEdgeEndView)) {
|
|
145
|
+
(0, _glsp_sprotty_1.configureCommand)(context, DrawFeedbackEdgeCommand);
|
|
146
|
+
(0, _glsp_sprotty_1.configureCommand)(context, RemoveFeedbackEdgeCommand);
|
|
147
|
+
(0, _glsp_sprotty_1.configureView)(context, FeedbackEdgeEnd.TYPE, view_1.FeedbackEdgeEndView);
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
exports.configureDanglingFeedbackEdge = configureDanglingFeedbackEdge;
|
|
151
|
+
//# sourceMappingURL=dangling-edge-feedback.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dangling-edge-feedback.js","sourceRoot":"","sources":["../../../../src/features/tools/edge-creation/dangling-edge-feedback.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA;;;;;;;;;;;;;;kFAckF;AAClF,yCAA+C;AAC/C,iDAgBuB;AACvB,8EAA0E;AAC1E,4DAAwD;AACxD,kEAAmE;AACnE,iCAA6C;AAS7C,IAAiB,sBAAsB,CAiBtC;AAjBD,WAAiB,sBAAsB;IACtB,2BAAI,GAAG,kBAAkB,CAAC;IAEvC,SAAgB,EAAE,CAAC,MAAW;QAC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CAAC,eAAe,CAAC,CAAC;KAChC;AACL,CAAC;AATD,gEASC;AAED,SAAgB,6BAA6B,CAAC,OAAuB;IACjE,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,uBAAuB,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,yBAAyB,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,0BAAmB,CAAC,EAAE;QACnI,IAAA,gCAAgB,EAAC,OAAO,EAAE,uBAAuB,CAAC,CAAC;QACnD,IAAA,gCAAgB,EAAC,OAAO,EAAE,yBAAyB,CAAC,CAAC;QACrD,IAAA,6BAAa,EAAC,OAAO,EAAE,eAAe,CAAC,IAAI,EAAE,0BAAmB,CAAC,CAAC;KACrE;AACL,CAAC;AAND,sEAMC"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/********************************************************************************
|
|
2
|
+
* Copyright (c) 2019-2023 EclipseSource and others.
|
|
3
|
+
*
|
|
4
|
+
* This program and the accompanying materials are made available under the
|
|
5
|
+
* terms of the Eclipse Public License v. 2.0 which is available at
|
|
6
|
+
* http://www.eclipse.org/legal/epl-2.0.
|
|
7
|
+
*
|
|
8
|
+
* This Source Code may also be made available under the following Secondary
|
|
9
|
+
* Licenses when the conditions for such availability set forth in the Eclipse
|
|
10
|
+
* Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
11
|
+
* with the GNU Classpath Exception which is available at
|
|
12
|
+
* https://www.gnu.org/software/classpath/license.html.
|
|
13
|
+
*
|
|
14
|
+
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
|
|
15
|
+
********************************************************************************/
|
|
16
|
+
import { ContainerModule } from 'inversify';
|
|
17
|
+
declare const edgeCreationToolModule: ContainerModule;
|
|
18
|
+
export default edgeCreationToolModule;
|
|
19
|
+
//# sourceMappingURL=di.config.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"di.config.d.ts","sourceRoot":"","sources":["../../../../src/features/tools/edge-creation/di.config.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAClF,OAAO,EAAE,eAAe,EAAE,MAAM,WAAW,CAAC;AAK5C,QAAA,MAAM,sBAAsB,iBAK1B,CAAC;AAEH,eAAe,sBAAsB,CAAC"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
/********************************************************************************
|
|
4
|
+
* Copyright (c) 2019-2023 EclipseSource and others.
|
|
5
|
+
*
|
|
6
|
+
* This program and the accompanying materials are made available under the
|
|
7
|
+
* terms of the Eclipse Public License v. 2.0 which is available at
|
|
8
|
+
* http://www.eclipse.org/legal/epl-2.0.
|
|
9
|
+
*
|
|
10
|
+
* This Source Code may also be made available under the following Secondary
|
|
11
|
+
* Licenses when the conditions for such availability set forth in the Eclipse
|
|
12
|
+
* Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
13
|
+
* with the GNU Classpath Exception which is available at
|
|
14
|
+
* https://www.gnu.org/software/classpath/license.html.
|
|
15
|
+
*
|
|
16
|
+
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
|
|
17
|
+
********************************************************************************/
|
|
18
|
+
const inversify_1 = require("inversify");
|
|
19
|
+
const _glsp_sprotty_1 = require("../../../glsp-sprotty/index");
|
|
20
|
+
const dangling_edge_feedback_1 = require("./dangling-edge-feedback");
|
|
21
|
+
const edge_creation_tool_1 = require("./edge-creation-tool");
|
|
22
|
+
const edgeCreationToolModule = new inversify_1.ContainerModule((bind, unbind, isBound, rebind) => {
|
|
23
|
+
const context = { bind, unbind, isBound, rebind };
|
|
24
|
+
(0, _glsp_sprotty_1.bindAsService)(context, _glsp_sprotty_1.TYPES.ITool, edge_creation_tool_1.EdgeCreationTool);
|
|
25
|
+
(0, _glsp_sprotty_1.configureActionHandler)(context, _glsp_sprotty_1.TriggerEdgeCreationAction.KIND, edge_creation_tool_1.EdgeCreationTool);
|
|
26
|
+
(0, dangling_edge_feedback_1.configureDanglingFeedbackEdge)(context);
|
|
27
|
+
});
|
|
28
|
+
exports.default = edgeCreationToolModule;
|
|
29
|
+
//# sourceMappingURL=di.config.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"di.config.js","sourceRoot":"","sources":["../../../../src/features/tools/edge-creation/di.config.ts"],"names":[],"mappings":";;AAAA;;;;;;;;;;;;;;kFAckF;AAClF,yCAA4C;AAC5C,iDAAwG;AACxG,qEAAyE;AACzE,6DAAwD;AAExD,MAAM,sBAAsB,GAAG,IAAI,2BAAe,CAAC,CAAC,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,EAAE;IACjF,MAAM,OAAO,GAAG,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,CAAC;IAClD,IAAA,6BAAa,EAAC,OAAO,EAAE,qBAAK,CAAC,KAAK,EAAE,qCAAgB,CAAC,CAAC;IACtD,IAAA,sCAAsB,EAAC,OAAO,EAAE,yCAAyB,CAAC,IAAI,EAAE,qCAAgB,CAAC,CAAC;IAClF,IAAA,sDAA6B,EAAC,OAAO,CAAC,CAAC;AAC3C,CAAC,CAAC,CAAC;AAEH,kBAAe,sBAAsB,CAAC"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/********************************************************************************
|
|
2
|
+
* Copyright (c) 2019-2023 EclipseSource and others.
|
|
3
|
+
*
|
|
4
|
+
* This program and the accompanying materials are made available under the
|
|
5
|
+
* terms of the Eclipse Public License v. 2.0 which is available at
|
|
6
|
+
* http://www.eclipse.org/legal/epl-2.0.
|
|
7
|
+
*
|
|
8
|
+
* This Source Code may also be made available under the following Secondary
|
|
9
|
+
* Licenses when the conditions for such availability set forth in the Eclipse
|
|
10
|
+
* Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
11
|
+
* with the GNU Classpath Exception which is available at
|
|
12
|
+
* https://www.gnu.org/software/classpath/license.html.
|
|
13
|
+
*
|
|
14
|
+
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
|
|
15
|
+
********************************************************************************/
|
|
16
|
+
import { Action, AnchorComputerRegistry, Disposable, MouseListener, Point, SConnectableElement, SModelElement } from '../../../glsp-sprotty/index';
|
|
17
|
+
import { IFeedbackActionDispatcher } from '../../../base/feedback/feedback-action-dispatcher';
|
|
18
|
+
export declare class FeedbackEdgeEndMovingMouseListener extends MouseListener implements Disposable {
|
|
19
|
+
protected anchorRegistry: AnchorComputerRegistry;
|
|
20
|
+
protected feedbackDispatcher: IFeedbackActionDispatcher;
|
|
21
|
+
constructor(anchorRegistry: AnchorComputerRegistry, feedbackDispatcher: IFeedbackActionDispatcher);
|
|
22
|
+
mouseMove(target: SModelElement, event: MouseEvent): Action[];
|
|
23
|
+
protected computeAbsoluteAnchor(element: SConnectableElement, absoluteReferencePoint: Point, offset?: number): Point;
|
|
24
|
+
dispose(): void;
|
|
25
|
+
}
|
|
26
|
+
//# sourceMappingURL=edge-creation-tool-feedback.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"edge-creation-tool-feedback.d.ts","sourceRoot":"","sources":["../../../../src/features/tools/edge-creation/edge-creation-tool-feedback.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAClF,OAAO,EACH,MAAM,EACN,sBAAsB,EAEtB,UAAU,EACV,aAAa,EAEb,KAAK,EAEL,mBAAmB,EACnB,aAAa,EAKhB,MAAM,eAAe,CAAC;AACvB,OAAO,EAAE,yBAAyB,EAAE,MAAM,mDAAmD,CAAC;AAI9F,qBAAa,kCAAmC,SAAQ,aAAc,YAAW,UAAU;IAC3E,SAAS,CAAC,cAAc,EAAE,sBAAsB;IAAE,SAAS,CAAC,kBAAkB,EAAE,yBAAyB;gBAA/F,cAAc,EAAE,sBAAsB,EAAY,kBAAkB,EAAE,yBAAyB;IAI5G,SAAS,CAAC,MAAM,EAAE,aAAa,EAAE,KAAK,EAAE,UAAU,GAAG,MAAM,EAAE;IA6BtE,SAAS,CAAC,qBAAqB,CAAC,OAAO,EAAE,mBAAmB,EAAE,sBAAsB,EAAE,KAAK,EAAE,MAAM,CAAC,EAAE,MAAM,GAAG,KAAK;IAgBpH,OAAO,IAAI,IAAI;CAGlB"}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.FeedbackEdgeEndMovingMouseListener = void 0;
|
|
4
|
+
/********************************************************************************
|
|
5
|
+
* Copyright (c) 2019-2023 EclipseSource and others.
|
|
6
|
+
*
|
|
7
|
+
* This program and the accompanying materials are made available under the
|
|
8
|
+
* terms of the Eclipse Public License v. 2.0 which is available at
|
|
9
|
+
* http://www.eclipse.org/legal/epl-2.0.
|
|
10
|
+
*
|
|
11
|
+
* This Source Code may also be made available under the following Secondary
|
|
12
|
+
* Licenses when the conditions for such availability set forth in the Eclipse
|
|
13
|
+
* Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
14
|
+
* with the GNU Classpath Exception which is available at
|
|
15
|
+
* https://www.gnu.org/software/classpath/license.html.
|
|
16
|
+
*
|
|
17
|
+
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
|
|
18
|
+
********************************************************************************/
|
|
19
|
+
const _glsp_sprotty_1 = require("../../../glsp-sprotty/index");
|
|
20
|
+
const viewpoint_util_1 = require("../../../utils/viewpoint-util");
|
|
21
|
+
const dangling_edge_feedback_1 = require("./dangling-edge-feedback");
|
|
22
|
+
class FeedbackEdgeEndMovingMouseListener extends _glsp_sprotty_1.MouseListener {
|
|
23
|
+
constructor(anchorRegistry, feedbackDispatcher) {
|
|
24
|
+
super();
|
|
25
|
+
this.anchorRegistry = anchorRegistry;
|
|
26
|
+
this.feedbackDispatcher = feedbackDispatcher;
|
|
27
|
+
}
|
|
28
|
+
mouseMove(target, event) {
|
|
29
|
+
const root = target.root;
|
|
30
|
+
const edgeEnd = root.index.getById((0, dangling_edge_feedback_1.feedbackEdgeEndId)(root));
|
|
31
|
+
if (!(edgeEnd instanceof dangling_edge_feedback_1.FeedbackEdgeEnd) || !edgeEnd.feedbackEdge) {
|
|
32
|
+
return [];
|
|
33
|
+
}
|
|
34
|
+
const edge = edgeEnd.feedbackEdge;
|
|
35
|
+
const position = (0, viewpoint_util_1.getAbsolutePosition)(edgeEnd, event);
|
|
36
|
+
const endAtMousePosition = (0, _glsp_sprotty_1.findChildrenAtPosition)(target.root, position)
|
|
37
|
+
.reverse()
|
|
38
|
+
.find(element => (0, _glsp_sprotty_1.isConnectable)(element) && element.canConnect(edge, 'target'));
|
|
39
|
+
if (endAtMousePosition instanceof _glsp_sprotty_1.SConnectableElement && edge.source && (0, _glsp_sprotty_1.isBoundsAware)(edge.source)) {
|
|
40
|
+
const anchor = this.computeAbsoluteAnchor(endAtMousePosition, _glsp_sprotty_1.Bounds.center((0, viewpoint_util_1.toAbsoluteBounds)(edge.source)));
|
|
41
|
+
if (_glsp_sprotty_1.Point.euclideanDistance(anchor, edgeEnd.position) > 1) {
|
|
42
|
+
this.feedbackDispatcher.registerFeedback(this, [
|
|
43
|
+
_glsp_sprotty_1.MoveAction.create([{ elementId: edgeEnd.id, toPosition: anchor }], { animate: false })
|
|
44
|
+
]);
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
else {
|
|
48
|
+
this.feedbackDispatcher.registerFeedback(this, [
|
|
49
|
+
_glsp_sprotty_1.MoveAction.create([{ elementId: edgeEnd.id, toPosition: position }], { animate: false })
|
|
50
|
+
]);
|
|
51
|
+
}
|
|
52
|
+
return [];
|
|
53
|
+
}
|
|
54
|
+
computeAbsoluteAnchor(element, absoluteReferencePoint, offset) {
|
|
55
|
+
const referencePointInParent = (0, viewpoint_util_1.absoluteToParent)(element, absoluteReferencePoint);
|
|
56
|
+
const anchorComputer = this.anchorRegistry.get(_glsp_sprotty_1.PolylineEdgeRouter.KIND, element.anchorKind);
|
|
57
|
+
let anchor = anchorComputer.getAnchor(element, referencePointInParent, offset);
|
|
58
|
+
// The anchor is computed in the local coordinate system of the element.
|
|
59
|
+
// If the element is a nested child element we have to add the absolute position of its parent to the anchor.
|
|
60
|
+
if (element.parent !== element.root) {
|
|
61
|
+
const parent = (0, _glsp_sprotty_1.findParentByFeature)(element.parent, _glsp_sprotty_1.isBoundsAware);
|
|
62
|
+
if (parent) {
|
|
63
|
+
const absoluteParentPosition = (0, viewpoint_util_1.toAbsoluteBounds)(parent);
|
|
64
|
+
anchor = _glsp_sprotty_1.Point.add(absoluteParentPosition, anchor);
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
return anchor;
|
|
68
|
+
}
|
|
69
|
+
dispose() {
|
|
70
|
+
this.feedbackDispatcher.deregisterFeedback(this);
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
exports.FeedbackEdgeEndMovingMouseListener = FeedbackEdgeEndMovingMouseListener;
|
|
74
|
+
//# sourceMappingURL=edge-creation-tool-feedback.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"edge-creation-tool-feedback.js","sourceRoot":"","sources":["../../../../src/features/tools/edge-creation/edge-creation-tool-feedback.ts"],"names":[],"mappings":";;;AAAA;;;;;;;;;;;;;;kFAckF;AAClF,iDAeuB;AAEvB,kEAAwG;AACxG,qEAA8E;AAE9E,MAAa,kCAAmC,SAAQ,6BAAa;IACjE,YAAsB,cAAsC,EAAY,kBAA6C;QACjH,KAAK,EAAE,CAAC;QADU,mBAAc,GAAd,cAAc,CAAwB;QAAY,uBAAkB,GAAlB,kBAAkB,CAA2B;IAErH,CAAC;IAEQ,SAAS,CAAC,MAAqB,EAAE,KAAiB;QACvD,MAAM,IAAI,GAAG,MAAM,CAAC,IAAI,CAAC;QACzB,MAAM,OAAO,GAAG,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,IAAA,0CAAiB,EA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EAAE,OAAO,CAAC,EAAE,EAAE,UAAU,EAAE,QAAQ,EAAE,CAAC,EAAE,EAAE,OAAO,EAAE,KAAK,EAAE,CAAC;aAC3F,CAAC,CAAC;SACN;QAED,OAAO,EAAE,CAAC;IACd,CAAC;IAES,qBAAqB,CAAC,OAA4B,EAAE,sBAA6B,EAAE,MAAe;QACxG,MAAM,sBAAsB,GAAG,IAAA,iCAAgB,EAAC,OAAO,EAAE,sBAAsB,CAAC,CAAC;QACjF,MAAM,cAAc,GAAG,IAAI,CAAC,cAAc,CAAC,GAAG,CAAC,kCAAkB,CAAC,IAAI,EAAE,OAAO,CAAC,UAAU,CAAC,CAAC;QAC5F,IAAI,MAAM,GAAG,cAAc,CAAC,SAAS,CAAC,OAAO,EAAE,sBAAsB,EAAE,MAAM,CAAC,CAAC;QAC/E,wEAAwE;QACxE,6GAA6G;QAC7G,IAAI,OAAO,CAAC,MAAM,KAAK,OAAO,CAAC,IAAI,EAAE;YACjC,MAAM,MAAM,GAAG,IAAA,mCAAmB,EAAC,OAAO,CAAC,MAAM,EAAE,6BAAa,CAAC,CAAC;YAClE,IAAI,MAAM,EAAE;gBACR,MAAM,sBAAsB,GAAG,IAAA,iCAAgB,EAAC,MAAM,CAAC,CAAC;gBACxD,MAAM,GAAG,qBAAK,CAAC,GAAG,CAAC,sBAAsB,EAAE,MAAM,CAAC,CAAC;aACtD;SACJ;QACD,OAAO,MAAM,CAAC;IAClB,CAAC;IAED,OAAO;QACH,IAAI,CAAC,kBAAkB,CAAC,kBAAkB,CAAC,IAAI,CAAC,CAAC;IACrD,CAAC;CACJ;AArDD,gFAqDC"}
|
package/lib/features/tools/{edge-creation-tool.d.ts → edge-creation/edge-creation-tool.d.ts}
RENAMED
|
@@ -1,20 +1,15 @@
|
|
|
1
|
-
import { Action, AnchorComputerRegistry,
|
|
2
|
-
import { DragAwareMouseListener } from '
|
|
3
|
-
import {
|
|
4
|
-
import { BaseGLSPTool } from './base-glsp-tool';
|
|
1
|
+
import { Action, AnchorComputerRegistry, SEdge, SModelElement, TriggerEdgeCreationAction } from '../../../glsp-sprotty/index';
|
|
2
|
+
import { DragAwareMouseListener } from '../../../base/drag-aware-mouse-listener';
|
|
3
|
+
import { BaseGLSPCreationTool } from '../base-glsp-creation-tool';
|
|
5
4
|
/**
|
|
6
5
|
* Tool to create connections in a Diagram, by selecting a source and target node.
|
|
7
6
|
*/
|
|
8
|
-
export declare class EdgeCreationTool extends
|
|
7
|
+
export declare class EdgeCreationTool extends BaseGLSPCreationTool<TriggerEdgeCreationAction> {
|
|
9
8
|
static ID: string;
|
|
10
9
|
protected anchorRegistry: AnchorComputerRegistry;
|
|
11
|
-
protected
|
|
12
|
-
protected creationToolMouseListener: EdgeCreationToolMouseListener;
|
|
13
|
-
protected feedbackEndMovingMouseListener: FeedbackEdgeEndMovingMouseListener;
|
|
10
|
+
protected isTriggerAction: typeof TriggerEdgeCreationAction.is;
|
|
14
11
|
get id(): string;
|
|
15
|
-
|
|
16
|
-
disable(): void;
|
|
17
|
-
handle(action: Action): Action | void;
|
|
12
|
+
doEnable(): void;
|
|
18
13
|
}
|
|
19
14
|
export declare class EdgeCreationToolMouseListener extends DragAwareMouseListener {
|
|
20
15
|
protected triggerAction: TriggerEdgeCreationAction;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"edge-creation-tool.d.ts","sourceRoot":"","sources":["../../../../src/features/tools/edge-creation/edge-creation-tool.ts"],"names":[],"mappings":"AAgBA,OAAO,EACH,MAAM,EACN,sBAAsB,EAGtB,KAAK,EACL,aAAa,EACb,yBAAyB,EAI5B,MAAM,eAAe,CAAC;AACvB,OAAO,EAAE,sBAAsB,EAAE,MAAM,yCAAyC,CAAC;AAGjF,OAAO,EAAE,oBAAoB,EAAE,MAAM,4BAA4B,CAAC;AAIlE;;GAEG;AACH,qBACa,gBAAiB,SAAQ,oBAAoB,CAAC,yBAAyB,CAAC;IACjF,MAAM,CAAC,EAAE,SAAsB;IAEC,SAAS,CAAC,cAAc,EAAE,sBAAsB,CAAC;IAEjF,SAAS,CAAC,eAAe,sCAAgC;IAEzD,IAAI,EAAE,IAAI,MAAM,CAEf;IAED,QAAQ,IAAI,IAAI;CAYnB;AAED,qBACa,6BAA8B,SAAQ,sBAAsB;IAOzD,SAAS,CAAC,aAAa,EAAE,yBAAyB;IAAE,SAAS,CAAC,IAAI,EAAE,gBAAgB;IANhG,SAAS,CAAC,MAAM,CAAC,EAAE,MAAM,CAAC;IAC1B,SAAS,CAAC,MAAM,CAAC,EAAE,MAAM,CAAC;IAC1B,SAAS,CAAC,aAAa,CAAC,EAAE,aAAa,CAAC;IACxC,SAAS,CAAC,aAAa,UAAS;IAChC,SAAS,CAAC,SAAS,EAAE,KAAK,CAAC;gBAEL,aAAa,EAAE,yBAAyB,EAAY,IAAI,EAAE,gBAAgB;IAMhG,SAAS,CAAC,YAAY,IAAI,IAAI;IAQrB,kBAAkB,CAAC,QAAQ,EAAE,aAAa,EAAE,KAAK,EAAE,UAAU,GAAG,MAAM,EAAE;IAoCjF,SAAS,CAAC,gBAAgB,IAAI,OAAO;IAIrC,SAAS,CAAC,gBAAgB,IAAI,OAAO;IAI5B,SAAS,CAAC,MAAM,EAAE,aAAa,EAAE,KAAK,EAAE,UAAU,GAAG,MAAM,EAAE;IAsBtE,SAAS,CAAC,eAAe,CAAC,OAAO,EAAE,aAAa,GAAG,SAAS,GAAG,OAAO;IAItE,SAAS,CAAC,eAAe,CAAC,OAAO,EAAE,aAAa,GAAG,SAAS,GAAG,OAAO;CAGzE"}
|
|
@@ -27,38 +27,29 @@ exports.EdgeCreationToolMouseListener = exports.EdgeCreationTool = void 0;
|
|
|
27
27
|
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
|
|
28
28
|
********************************************************************************/
|
|
29
29
|
const inversify_1 = require("inversify");
|
|
30
|
-
const _glsp_sprotty_1 = require("
|
|
31
|
-
const drag_aware_mouse_listener_1 = require("
|
|
32
|
-
const
|
|
33
|
-
const
|
|
34
|
-
const
|
|
30
|
+
const _glsp_sprotty_1 = require("../../../glsp-sprotty/index");
|
|
31
|
+
const drag_aware_mouse_listener_1 = require("../../../base/drag-aware-mouse-listener");
|
|
32
|
+
const css_feedback_1 = require("../../../base/feedback/css-feedback");
|
|
33
|
+
const base_glsp_creation_tool_1 = require("../base-glsp-creation-tool");
|
|
34
|
+
const dangling_edge_feedback_1 = require("./dangling-edge-feedback");
|
|
35
|
+
const edge_creation_tool_feedback_1 = require("./edge-creation-tool-feedback");
|
|
35
36
|
/**
|
|
36
37
|
* Tool to create connections in a Diagram, by selecting a source and target node.
|
|
37
38
|
*/
|
|
38
|
-
let EdgeCreationTool = EdgeCreationTool_1 = class EdgeCreationTool extends
|
|
39
|
+
let EdgeCreationTool = exports.EdgeCreationTool = EdgeCreationTool_1 = class EdgeCreationTool extends base_glsp_creation_tool_1.BaseGLSPCreationTool {
|
|
40
|
+
constructor() {
|
|
41
|
+
super(...arguments);
|
|
42
|
+
this.isTriggerAction = _glsp_sprotty_1.TriggerEdgeCreationAction.is;
|
|
43
|
+
}
|
|
39
44
|
get id() {
|
|
40
45
|
return EdgeCreationTool_1.ID;
|
|
41
46
|
}
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
this.feedbackEndMovingMouseListener = new creation_tool_feedback_1.FeedbackEdgeEndMovingMouseListener(this.anchorRegistry);
|
|
49
|
-
this.mouseTool.register(this.feedbackEndMovingMouseListener);
|
|
50
|
-
this.dispatchFeedback([(0, css_feedback_1.cursorFeedbackAction)(css_feedback_1.CursorCSS.OPERATION_NOT_ALLOWED)]);
|
|
51
|
-
}
|
|
52
|
-
disable() {
|
|
53
|
-
this.mouseTool.deregister(this.creationToolMouseListener);
|
|
54
|
-
this.mouseTool.deregister(this.feedbackEndMovingMouseListener);
|
|
55
|
-
this.deregisterFeedback([creation_tool_feedback_1.RemoveFeedbackEdgeAction.create(), (0, css_feedback_1.cursorFeedbackAction)()]);
|
|
56
|
-
}
|
|
57
|
-
handle(action) {
|
|
58
|
-
if (_glsp_sprotty_1.TriggerEdgeCreationAction.is(action)) {
|
|
59
|
-
this.triggerAction = action;
|
|
60
|
-
return _glsp_sprotty_1.EnableToolsAction.create([this.id]);
|
|
61
|
-
}
|
|
47
|
+
doEnable() {
|
|
48
|
+
const mouseMovingFeedback = new edge_creation_tool_feedback_1.FeedbackEdgeEndMovingMouseListener(this.anchorRegistry, this.feedbackDispatcher);
|
|
49
|
+
this.toDisposeOnDisable.push(mouseMovingFeedback, this.mouseTool.registerListener(new EdgeCreationToolMouseListener(this.triggerAction, this)), this.mouseTool.registerListener(mouseMovingFeedback), this.registerFeedback([(0, css_feedback_1.cursorFeedbackAction)(css_feedback_1.CursorCSS.OPERATION_NOT_ALLOWED)], this, [
|
|
50
|
+
dangling_edge_feedback_1.RemoveFeedbackEdgeAction.create(),
|
|
51
|
+
(0, css_feedback_1.cursorFeedbackAction)()
|
|
52
|
+
]));
|
|
62
53
|
}
|
|
63
54
|
};
|
|
64
55
|
EdgeCreationTool.ID = 'tool_create_edge';
|
|
@@ -66,11 +57,10 @@ __decorate([
|
|
|
66
57
|
(0, inversify_1.inject)(_glsp_sprotty_1.AnchorComputerRegistry),
|
|
67
58
|
__metadata("design:type", _glsp_sprotty_1.AnchorComputerRegistry)
|
|
68
59
|
], EdgeCreationTool.prototype, "anchorRegistry", void 0);
|
|
69
|
-
EdgeCreationTool = EdgeCreationTool_1 = __decorate([
|
|
60
|
+
exports.EdgeCreationTool = EdgeCreationTool = EdgeCreationTool_1 = __decorate([
|
|
70
61
|
(0, inversify_1.injectable)()
|
|
71
62
|
], EdgeCreationTool);
|
|
72
|
-
exports.
|
|
73
|
-
let EdgeCreationToolMouseListener = class EdgeCreationToolMouseListener extends drag_aware_mouse_listener_1.DragAwareMouseListener {
|
|
63
|
+
let EdgeCreationToolMouseListener = exports.EdgeCreationToolMouseListener = class EdgeCreationToolMouseListener extends drag_aware_mouse_listener_1.DragAwareMouseListener {
|
|
74
64
|
constructor(triggerAction, tool) {
|
|
75
65
|
super();
|
|
76
66
|
this.triggerAction = triggerAction;
|
|
@@ -84,7 +74,7 @@ let EdgeCreationToolMouseListener = class EdgeCreationToolMouseListener extends
|
|
|
84
74
|
this.target = undefined;
|
|
85
75
|
this.currentTarget = undefined;
|
|
86
76
|
this.allowedTarget = false;
|
|
87
|
-
this.tool.
|
|
77
|
+
this.tool.registerFeedback([dangling_edge_feedback_1.RemoveFeedbackEdgeAction.create()]);
|
|
88
78
|
}
|
|
89
79
|
nonDraggingMouseUp(_element, event) {
|
|
90
80
|
const result = [];
|
|
@@ -92,8 +82,8 @@ let EdgeCreationToolMouseListener = class EdgeCreationToolMouseListener extends
|
|
|
92
82
|
if (!this.isSourceSelected()) {
|
|
93
83
|
if (this.currentTarget && this.allowedTarget) {
|
|
94
84
|
this.source = this.currentTarget.id;
|
|
95
|
-
this.tool.
|
|
96
|
-
|
|
85
|
+
this.tool.registerFeedback([
|
|
86
|
+
dangling_edge_feedback_1.DrawFeedbackEdgeAction.create({ elementTypeId: this.triggerAction.elementTypeId, sourceId: this.source })
|
|
97
87
|
]);
|
|
98
88
|
}
|
|
99
89
|
}
|
|
@@ -103,18 +93,18 @@ let EdgeCreationToolMouseListener = class EdgeCreationToolMouseListener extends
|
|
|
103
93
|
}
|
|
104
94
|
}
|
|
105
95
|
if (this.source && this.target) {
|
|
106
|
-
result.push(_glsp_sprotty_1.CreateEdgeOperation.create({
|
|
107
|
-
elementTypeId: this.triggerAction.elementTypeId,
|
|
108
|
-
sourceElementId: this.source,
|
|
109
|
-
targetElementId: this.target,
|
|
110
|
-
args: this.triggerAction.args
|
|
111
|
-
}));
|
|
112
96
|
if (!(0, _glsp_sprotty_1.isCtrlOrCmd)(event)) {
|
|
113
97
|
result.push(_glsp_sprotty_1.EnableDefaultToolsAction.create());
|
|
114
98
|
}
|
|
115
99
|
else {
|
|
116
100
|
this.reinitialize();
|
|
117
101
|
}
|
|
102
|
+
result.push(_glsp_sprotty_1.CreateEdgeOperation.create({
|
|
103
|
+
elementTypeId: this.triggerAction.elementTypeId,
|
|
104
|
+
sourceElementId: this.source,
|
|
105
|
+
targetElementId: this.target,
|
|
106
|
+
args: this.triggerAction.args
|
|
107
|
+
}));
|
|
118
108
|
}
|
|
119
109
|
}
|
|
120
110
|
else if (event.button === 2) {
|
|
@@ -157,9 +147,8 @@ let EdgeCreationToolMouseListener = class EdgeCreationToolMouseListener extends
|
|
|
157
147
|
return element !== undefined && (0, _glsp_sprotty_1.isConnectable)(element) && element.canConnect(this.proxyEdge, 'target');
|
|
158
148
|
}
|
|
159
149
|
};
|
|
160
|
-
EdgeCreationToolMouseListener = __decorate([
|
|
150
|
+
exports.EdgeCreationToolMouseListener = EdgeCreationToolMouseListener = __decorate([
|
|
161
151
|
(0, inversify_1.injectable)(),
|
|
162
152
|
__metadata("design:paramtypes", [Object, EdgeCreationTool])
|
|
163
153
|
], EdgeCreationToolMouseListener);
|
|
164
|
-
exports.EdgeCreationToolMouseListener = EdgeCreationToolMouseListener;
|
|
165
154
|
//# sourceMappingURL=edge-creation-tool.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"edge-creation-tool.js","sourceRoot":"","sources":["../../../../src/features/tools/edge-creation/edge-creation-tool.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA;;;;;;;;;;;;;;kFAckF;AAClF,yCAA+C;AAC/C,iDAWuB;AACvB,uFAAiF;AAEjF,sEAAsF;AACtF,wEAAkE;AAClE,qEAA4F;AAC5F,+EAAmF;AAEnF;;GAEG;AAEI,IAAM,gBAAgB,mDAAtB,MAAM,gBAAiB,SAAQ,8CAA+C;IAA9E;;QAKO,oBAAe,GAAG,yCAAyB,CAAC,EAAE,CAAC;IAkB7D,CAAC;IAhBG,IAAI,EAAE;QACF,OAAO,kBAAgB,CAAC,EAAE,CAAC;IAC/B,CAAC;IAED,QAAQ;QACJ,MAAM,m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CAAC;SAClE;QACD,OAAO,EAAE,CAAC;IACd,CAAC;IAES,eAAe,CAAC,OAAkC;QACxD,OAAO,OAAO,KAAK,SAAS,IAAI,IAAA,6BAAa,EAAC,OAAO,CAAC,IAAI,OAAO,CAAC,UAAU,CAAC,IAAI,CAAC,SAAS,EAAE,QAAQ,CAAC,CAAC;IAC3G,CAAC;IAES,eAAe,CAAC,OAAkC;QACxD,OAAO,OAAO,KAAK,SAAS,IAAI,IAAA,6BAAa,EAAC,OAAO,CAAC,IAAI,OAAO,CAAC,UAAU,CAAC,IAAI,CAAC,SAAS,EAAE,QAAQ,CAAC,CAAC;IAC3G,CAAC;CACJ,CAAA;wCA9FY,6BAA6B;IADzC,IAAA,sBAAU,GAAE;6CAQuE,gBAAgB;GAPvF,6BAA6B,CA8FzC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { VNode } from 'snabbdom';
|
|
2
|
+
import { IView, RenderingContext, SModelElement } from '../../../glsp-sprotty/index';
|
|
3
|
+
/**
|
|
4
|
+
* This view is used for the invisible end of the feedback edge.
|
|
5
|
+
* A feedback edge is shown as a visual feedback when creating edges.
|
|
6
|
+
*/
|
|
7
|
+
export declare class FeedbackEdgeEndView implements IView {
|
|
8
|
+
render(model: Readonly<SModelElement>, context: RenderingContext): VNode;
|
|
9
|
+
}
|
|
10
|
+
//# sourceMappingURL=view.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"view.d.ts","sourceRoot":"","sources":["../../../../src/features/tools/edge-creation/view.tsx"],"names":[],"mappings":"AAgBA,OAAO,EAAE,KAAK,EAAE,MAAM,UAAU,CAAC;AACjC,OAAO,EAAE,KAAK,EAAS,gBAAgB,EAAE,aAAa,EAAO,MAAM,eAAe,CAAC;AAKnF;;;GAGG;AACH,qBACa,mBAAoB,YAAW,KAAK;IAC7C,MAAM,CAAC,KAAK,EAAE,QAAQ,CAAC,aAAa,CAAC,EAAE,OAAO,EAAE,gBAAgB,GAAG,KAAK;CAI3E"}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
|
+
exports.FeedbackEdgeEndView = void 0;
|
|
10
|
+
/********************************************************************************
|
|
11
|
+
* Copyright (c) 2019-2023 EclipseSource and others.
|
|
12
|
+
*
|
|
13
|
+
* This program and the accompanying materials are made available under the
|
|
14
|
+
* terms of the Eclipse Public License v. 2.0 which is available at
|
|
15
|
+
* http://www.eclipse.org/legal/epl-2.0.
|
|
16
|
+
*
|
|
17
|
+
* This Source Code may also be made available under the following Secondary
|
|
18
|
+
* Licenses when the conditions for such availability set forth in the Eclipse
|
|
19
|
+
* Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
20
|
+
* with the GNU Classpath Exception which is available at
|
|
21
|
+
* https://www.gnu.org/software/classpath/license.html.
|
|
22
|
+
*
|
|
23
|
+
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
|
|
24
|
+
********************************************************************************/
|
|
25
|
+
const inversify_1 = require("inversify");
|
|
26
|
+
const _glsp_sprotty_1 = require("../../../glsp-sprotty/index");
|
|
27
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
28
|
+
const JSX = { createElement: _glsp_sprotty_1.svg };
|
|
29
|
+
/**
|
|
30
|
+
* This view is used for the invisible end of the feedback edge.
|
|
31
|
+
* A feedback edge is shown as a visual feedback when creating edges.
|
|
32
|
+
*/
|
|
33
|
+
let FeedbackEdgeEndView = exports.FeedbackEdgeEndView = class FeedbackEdgeEndView {
|
|
34
|
+
render(model, context) {
|
|
35
|
+
var _a;
|
|
36
|
+
const position = (_a = model.position) !== null && _a !== void 0 ? _a : _glsp_sprotty_1.Point.ORIGIN;
|
|
37
|
+
return JSX.createElement("g", { x: position.x, y: position.y });
|
|
38
|
+
}
|
|
39
|
+
};
|
|
40
|
+
exports.FeedbackEdgeEndView = FeedbackEdgeEndView = __decorate([
|
|
41
|
+
(0, inversify_1.injectable)()
|
|
42
|
+
], FeedbackEdgeEndView);
|
|
43
|
+
//# sourceMappingURL=view.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"view.js","sourceRoot":"","sources":["../../../../src/features/tools/edge-creation/view.tsx"],"names":[],"mappings":";;;;;;;;;AAAA;;;;;;;;;;;;;;kFAckF;AAClF,yCAAuC;AAEvC,iDAAmF;AAEnF,6DAA6D;AAC7D,MAAM,GAAG,GAAG,EAAE,aAAa,EAAE,mBAAG,EAAE,CAAC;AAEnC;;;GAGG;AAEI,IAAM,mBAAmB,iCAAzB,MAAM,mBAAmB;IAC5B,MAAM,CAAC,KAA8B,EAAE,OAAyB;;QAC5D,MAAM,QAAQ,GAAU,MAAC,KAAa,CAAC,QAAQ,mCAAI,qBAAK,CAAC,MAAM,CAAC;QAChE,OAAO,yBAAG,CAAC,EAAE,QAAQ,CAAC,CAAC,EAAE,CAAC,EAAE,QAAQ,CAAC,CAAC,GAAI,CAAC;IAC/C,CAAC;CACJ,CAAA;8BALY,mBAAmB;IAD/B,IAAA,sBAAU,GAAE;GACA,mBAAmB,CAK/B"}
|
|
@@ -14,6 +14,6 @@
|
|
|
14
14
|
* SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0
|
|
15
15
|
********************************************************************************/
|
|
16
16
|
import { ContainerModule } from 'inversify';
|
|
17
|
-
declare const
|
|
18
|
-
export default
|
|
17
|
+
declare const edgeEditToolModule: ContainerModule;
|
|
18
|
+
export default edgeEditToolModule;
|
|
19
19
|
//# sourceMappingURL=di.config.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"di.config.d.ts","sourceRoot":"","sources":["../../../../src/features/tools/edge-edit/di.config.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;kFAckF;AAClF,OAAO,EAAE,eAAe,EAAE,MAAM,WAAW,CAAC;AAW5C,QAAA,MAAM,kBAAkB,iBAYtB,CAAC;AAEH,eAAe,kBAAkB,CAAC"}
|