From c501896f590cab2c61306b64e62da8261d6fc30b Mon Sep 17 00:00:00 2001 From: "hyojun.choi" Date: Thu, 15 Jan 2026 09:55:52 +0900 Subject: [PATCH] =?UTF-8?q?=EC=84=A0=20=EC=9E=91=EC=84=B1=20=EC=8B=9C=20?= =?UTF-8?q?=EA=B8=B0=EB=B3=B8=20attributes.planeSize=20=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/hooks/useLine.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/hooks/useLine.js b/src/hooks/useLine.js index 30cc9ba9..3e1d72e6 100644 --- a/src/hooks/useLine.js +++ b/src/hooks/useLine.js @@ -10,7 +10,7 @@ import { } from '@/store/canvasAtom' import { QLine } from '@/components/fabric/QLine' import { basicSettingState } from '@/store/settingAtom' -import { calcLineActualSizeByLineLength } from '@/util/qpolygon-utils' +import { calcLineActualSizeByLineLength, calcLinePlaneSize } from '@/util/qpolygon-utils' import { getDegreeByChon } from '@/util/canvas-util' import { useText } from '@/hooks/useText' import { fontSelector } from '@/store/fontAtom' @@ -31,6 +31,7 @@ export const useLine = () => { const addLine = (points = [], options) => { const line = new QLine(points, { ...options, + attributes: {}, fontSize: lengthText.fontSize.value, fontFamily: lengthText.fontFamily.value, }) @@ -38,7 +39,7 @@ export const useLine = () => { if (line.length < 1) { return null } - + line.attributes.planeSize = calcLinePlaneSize(line) canvas?.add(line) return line }