Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
mounted() {
document.addEventListener('keydown', event => {
moveShapeByKeypress(
event.key,
store.getters.highlightedShape,
this.pushToUndoStack,
);
});
this.graph = new dia.Graph();
store.commit('setGraph', this.graph);
this.graph.set('interactiveFunc', cellView => {
return {
elementMove: cellView.model.get('elementMove'),
};
});
this.paperManager = PaperManager.factory(this.$refs.paper, this.graph.get('interactiveFunc'), this.graph);
this.paper = this.paperManager.paper;
this.handleResize();
window.addEventListener('resize', this.handleResize);
store.commit('setPaper', this.paperManager.paper);
this.paperManager.addEventHandler('blank:pointerclick', () => {
beforeEach(() => {
graph = new dia.Graph();
});
beforeEach(() => {
graph = new dia.Graph();
});