text component

This commit is contained in:
hamid zarghami
2025-11-20 08:35:50 +03:30
parent 3b47e29ba4
commit 3454129dca
7 changed files with 321 additions and 13 deletions
@@ -1,7 +1,6 @@
import { Trash } from "iconsax-react";
import type { EditorObject } from "../../store/editorStore";
import {
TextSettings,
ShapeSettings,
LineSettings,
SizeSettings,
@@ -10,6 +9,7 @@ import {
TransformSettings,
GridSettings,
} from "./settings";
import TextInstruction from "./instructions/TextInstruction";
type ObjectSettingsProps = {
selectedObject: EditorObject;
@@ -30,7 +30,7 @@ const ObjectSettings = ({ selectedObject, onUpdate, onDelete }: ObjectSettingsPr
</button>
</div>
{selectedObject.type === "text" && <TextSettings selectedObject={selectedObject} onUpdate={onUpdate} />}
{selectedObject.type === "text" && <TextInstruction />}
{(selectedObject.type === "rectangle" || selectedObject.type === "circle") && (
<ShapeSettings selectedObject={selectedObject} onUpdate={onUpdate} />