diff --git a/src/components/Roof2.jsx b/src/components/Roof2.jsx index f8ffdd8f..eadb2c33 100644 --- a/src/components/Roof2.jsx +++ b/src/components/Roof2.jsx @@ -12,7 +12,7 @@ import { QLine } from '@/components/fabric/QLine' import { getTests, getCanvasState, insertCanvasState } from '@/lib/canvas' export default function Roof2() { - const { canvas, handleRedo, handleUndo, setCanvasBackgroundWithDots, saveImage, addCanvas, changeCanvas } = useCanvas('canvas') + const { canvas, handleRedo, handleUndo, setCanvasBackgroundWithDots, saveImage, addCanvas } = useCanvas('canvas') //canvas 기본 사이즈 const [canvasSize, setCanvasSize] = useRecoilState(canvasSizeState) @@ -174,8 +174,31 @@ export default function Roof2() { { x: 1088, y: 991 }, { x: 1088, y: 42 }, ] + + const eightPoint = [ + { x: 240, y: 130 }, + { x: 240, y: 630 }, + { x: 640, y: 630 }, + { x: 640, y: 480 }, + { x: 440, y: 480 }, + { x: 440, y: 280 }, + { x: 740, y: 280 }, + { x: 740, y: 130 }, + ] + + const eightPoint2 = [ + { x: 197, y: 215 }, + { x: 197, y: 815 }, + { x: 397, y: 815 }, + { x: 397, y: 1115 }, + { x: 697, y: 1115 }, + { x: 697, y: 815 }, + { x: 897, y: 815 }, + { x: 897, y: 215 }, + ] + if (canvas) { - const polygon = new QPolygon(type4, { + const polygon = new QPolygon(eightPoint, { fill: 'transparent', stroke: 'black', strokeWidth: 1, @@ -212,7 +235,7 @@ export default function Roof2() { [200, 200, 500, 500], { stroke: 'black', - strokeWidth: 1, + strokeWidth: 5, fontSize: fontSize, selectable: true, }, @@ -378,11 +401,14 @@ export default function Roof2() { - */} +