diff --git a/src/components/Roof2.jsx b/src/components/Roof2.jsx
index d5e511aa..787ea08d 100644
--- a/src/components/Roof2.jsx
+++ b/src/components/Roof2.jsx
@@ -6,7 +6,7 @@ import QRect from '@/components/fabric/QRect'
import QPolygon from '@/components/fabric/QPolygon'
import RangeSlider from './ui/RangeSlider'
-import { useRecoilState, useRecoilValue } from 'recoil'
+import { useRecoilState } from 'recoil'
import { canvasSizeState, fontSizeState, sortedPolygonArray } from '@/store/canvasAtom'
import { QLine } from '@/components/fabric/QLine'
@@ -179,8 +179,19 @@ 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 },
+ ]
if (canvas) {
- const polygon = new QPolygon(type4, {
+ const polygon = new QPolygon(eightPoint, {
fill: 'transparent',
stroke: 'black',
strokeWidth: 1,
@@ -226,7 +237,7 @@ export default function Roof2() {
}
const addBackgroundInPolygon = (polygon) => {
- fabric.Image.fromURL('assets/img/check2.png', function (img) {
+ fabric.Image.fromURL('assets/img/check2.png', function(img) {
// 패턴 객체를 생성합니다.
const pattern = new fabric.Pattern({
source: img.getElement(),
@@ -260,7 +271,8 @@ export default function Roof2() {
{canvas && (
<>
-