Skip to content

Commit

Permalink
fix arrow bug
Browse files Browse the repository at this point in the history
  • Loading branch information
ChrisShank committed Nov 18, 2024
1 parent 96baba2 commit d871582
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/arrows/abstract-arrow.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,6 @@ export class AbstractArrow extends HTMLElement {
#sourceHandler = (e: Event) => {
const geometry = e.target as FolkGeometry;
this.#sourceRect = geometry.getClientRect();
console.log();
this.#update();
};

Expand Down Expand Up @@ -117,7 +116,7 @@ export class AbstractArrow extends HTMLElement {

if (this.#sourceElement === null) {
throw new Error('source is not a valid element');
} else if (false) {
} else if (this.#sourceElement instanceof FolkGeometry) {
this.#sourceElement.addEventListener('resize', this.#sourceHandler);
this.#sourceElement.addEventListener('move', this.#sourceHandler);
} else {
Expand Down Expand Up @@ -152,7 +151,7 @@ export class AbstractArrow extends HTMLElement {

if (!this.#targetElement) {
throw new Error('target is not a valid element');
} else if (false) {
} else if (this.#targetElement instanceof FolkGeometry) {
this.#targetElement.addEventListener('resize', this.#targetHandler);
this.#targetElement.addEventListener('move', this.#targetHandler);
} else {
Expand Down

0 comments on commit d871582

Please sign in to comment.