diff --git a/frontend/components/screen/panels/UnifiedPropertiesPanel.tsx b/frontend/components/screen/panels/UnifiedPropertiesPanel.tsx index 178eb8a2..d790dfaa 100644 --- a/frontend/components/screen/panels/UnifiedPropertiesPanel.tsx +++ b/frontend/components/screen/panels/UnifiedPropertiesPanel.tsx @@ -401,38 +401,30 @@ export const UnifiedPropertiesPanel: React.FC = ({ )} - {/* Grid Columns + Z-Index (같은 행) */} + {/* Width + Z-Index (같은 행) */}
- {(selectedComponent as any).gridColumns !== undefined && ( -
- -
- { - const value = parseInt(e.target.value, 10); - const maxColumns = gridSettings?.columns || 12; - if (!isNaN(value) && value >= 1 && value <= maxColumns) { - handleUpdate("gridColumns", value); - - // width를 퍼센트로 계산하여 업데이트 - const widthPercent = (value / maxColumns) * 100; - handleUpdate("style.width", `${widthPercent}%`); - } - }} - className="h-6 w-full px-2 py-0 text-xs" - style={{ fontSize: "12px" }} - /> - - /{gridSettings?.columns || 12} - -
+
+ +
+ { + const value = parseInt(e.target.value, 10); + if (!isNaN(value) && value >= 10) { + // 10px 단위로 스냅 + const snappedValue = Math.round(value / 10) * 10; + handleUpdate("size.width", snappedValue); + } + }} + className="h-6 w-full px-2 py-0 text-xs" + style={{ fontSize: "12px" }} + />
- )} +