From 0e3acedf2d04e369f3fb07ec7f0b36023b8da15a Mon Sep 17 00:00:00 2001 From: ysCha Date: Mon, 27 Apr 2026 17:43:35 +0900 Subject: [PATCH] =?UTF-8?q?=ED=8F=89=EB=A9=B4=EB=8F=84=20=ED=99=95?= =?UTF-8?q?=EC=A0=95=20=EC=8B=9C=20=ED=99=95=EC=9D=B8=20=EB=8B=A4=EC=9D=B4?= =?UTF-8?q?=EC=96=BC=EB=A1=9C=EA=B7=B8=20=EC=B6=94=EA=B0=80=20(=EB=B2=84?= =?UTF-8?q?=ED=8A=BC/Enter=20=ED=82=A4)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../modal/placementShape/PlacementShapeDrawing.jsx | 13 ++++++++++++- src/hooks/surface/usePlacementShapeDrawing.js | 10 +++++++++- 2 files changed, 21 insertions(+), 2 deletions(-) diff --git a/src/components/floor-plan/modal/placementShape/PlacementShapeDrawing.jsx b/src/components/floor-plan/modal/placementShape/PlacementShapeDrawing.jsx index 95758b8c..05756f63 100644 --- a/src/components/floor-plan/modal/placementShape/PlacementShapeDrawing.jsx +++ b/src/components/floor-plan/modal/placementShape/PlacementShapeDrawing.jsx @@ -9,11 +9,13 @@ import { OUTER_LINE_TYPE } from '@/store/outerLineAtom' import OuterLineWall from '@/components/floor-plan/modal/lineTypes/OuterLineWall' import { usePlacementShapeDrawing } from '@/hooks/surface/usePlacementShapeDrawing' import { usePopup } from '@/hooks/usePopup' +import { useSwal } from '@/hooks/useSwal' import Image from 'next/image' export default function PlacementShapeDrawing({ id, pos = { x: 50, y: 230 } }) { const { getMessage } = useMessage() const { closePopup } = usePopup() + const { swalFire } = useSwal() const [buttonAct, setButtonAct] = useState(1) const [useCalcPad, setUseCalcPad] = useState(false) const types = [ @@ -155,7 +157,16 @@ export default function PlacementShapeDrawing({ id, pos = { x: 50, y: 230 } }) { - diff --git a/src/hooks/surface/usePlacementShapeDrawing.js b/src/hooks/surface/usePlacementShapeDrawing.js index 3a6d1c05..efb233be 100644 --- a/src/hooks/surface/usePlacementShapeDrawing.js +++ b/src/hooks/surface/usePlacementShapeDrawing.js @@ -22,6 +22,8 @@ import { import { usePolygon } from '@/hooks/usePolygon' import { POLYGON_TYPE } from '@/common/common' import { usePopup } from '@/hooks/usePopup' +import { useSwal } from '@/hooks/useSwal' +import { useMessage } from '@/hooks/useMessage' import { useSurfaceShapeBatch } from './useSurfaceShapeBatch' import { roofDisplaySelector } from '@/store/settingAtom' @@ -48,6 +50,8 @@ export function usePlacementShapeDrawing(id) { const { setSurfaceShapePattern } = useRoofFn() const { changeSurfaceLineType } = useSurfaceShapeBatch({}) const { handleSelectableObjects } = useObject() + const { swalFire } = useSwal() + const { getMessage } = useMessage() const verticalHorizontalMode = useRecoilValue(verticalHorizontalModeState) const adsorptionRange = useRecoilValue(adsorptionRangeState) @@ -1089,7 +1093,11 @@ export function usePlacementShapeDrawing(id) { const enterCheck = (e) => { if (e.key === 'Enter') { - handleFix() + swalFire({ + type: 'confirm', + text: getMessage('modal.cover.outline.fix.confirm'), + confirmFn: handleFix, + }) } } -- 2.47.2