fix build
This commit is contained in:
@@ -1,9 +1,9 @@
|
||||
import { useEffect, useRef } from "react";
|
||||
import { useRef } from "react";
|
||||
import { RegularPolygon } from "react-konva";
|
||||
import Konva from "konva";
|
||||
import type { ShapeProps } from "./types";
|
||||
|
||||
const TriangleShape = ({ obj, isSelected, transformerRef, onSelect, onUpdate, draggable }: ShapeProps) => {
|
||||
const TriangleShape = ({ obj, isSelected, onSelect, onUpdate, draggable }: ShapeProps) => {
|
||||
const shapeRef = useRef<Konva.RegularPolygon>(null);
|
||||
|
||||
// Transformer is managed in EditorCanvas for multi-select support
|
||||
@@ -23,13 +23,13 @@ const TriangleShape = ({ obj, isSelected, transformerRef, onSelect, onUpdate, dr
|
||||
radius={radius}
|
||||
fill={isMask ? "transparent" : obj.fill}
|
||||
stroke={
|
||||
isSelected
|
||||
? "#3b82f6"
|
||||
: (isMask && showGuide)
|
||||
? "#ff6b6b"
|
||||
: (isMask && !showGuide)
|
||||
? "transparent"
|
||||
: obj.stroke
|
||||
isSelected
|
||||
? "#3b82f6"
|
||||
: (isMask && showGuide)
|
||||
? "#ff6b6b"
|
||||
: (isMask && !showGuide)
|
||||
? "transparent"
|
||||
: obj.stroke
|
||||
}
|
||||
strokeWidth={isSelected ? 3 : (isMask && showGuide ? 2 : (obj.strokeWidth ?? 0))}
|
||||
dash={isMask && showGuide ? [10, 5] : undefined}
|
||||
|
||||
Reference in New Issue
Block a user