Skip to content

Commit

Permalink
feat(settings): assign settings obj, instead of passing link
Browse files Browse the repository at this point in the history
feat(tools): remove old comment
  • Loading branch information
EGRrqq committed Feb 12, 2024
1 parent 60c5699 commit 50ec457
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,10 @@ export class ElementDataController implements IElementDataController {

constructor(ctx: CanvasRenderingContext2D, settings: IStrokeSettings) {
this.#ctx = ctx;
this.#settings = settings;

//@ts-ignore
this.#settings = {};
Object.assign(this.#settings, settings);

this.#generateId(3);
}
Expand Down
3 changes: 0 additions & 3 deletions src/canvasController/tools/pen.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
import { IStrokeSettings, IStrokeTool } from "./IStrokeTool";

// todo:
// option for specific tool settings, like line stroke, color etc.
// like draw(x, y, { lineWidth: 3, strokeStyle: #fff })
export class Pen implements IStrokeTool {
#context: CanvasRenderingContext2D;
#type = "pen";
Expand Down

0 comments on commit 50ec457

Please sign in to comment.