diff options
| author | Maze Winther <mazewinther@gmail.com> | 2026-04-29 18:31:24 +0200 |
|---|---|---|
| committer | Maze Winther <mazewinther@gmail.com> | 2026-05-02 03:27:23 +0200 |
| commit | 97f8d1968f186028e41f83b04c0897130e6c69f4 (patch) | |
| tree | cb951cbfcfa004f53ab3d7a06021fc43942ac04b /apps/web/src/masks/definitions/split.ts | |
| parent | ae1292a14bf5c29544a5f7a49e65b994410f87de (diff) | |
| download | opencut-97f8d1968f186028e41f83b04c0897130e6c69f4.tar.gz | |
refactor: type mask handle identifiers
Made-with: Cursor
Diffstat (limited to 'apps/web/src/masks/definitions/split.ts')
| -rw-r--r-- | apps/web/src/masks/definitions/split.ts | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/apps/web/src/masks/definitions/split.ts b/apps/web/src/masks/definitions/split.ts index de67b876..138db91d 100644 --- a/apps/web/src/masks/definitions/split.ts +++ b/apps/web/src/masks/definitions/split.ts @@ -128,7 +128,7 @@ function computeSplitMaskParamUpdate({ bounds, canvasSize, }: MaskParamUpdateArgs<SplitMaskParams>): Partial<SplitMaskParams> { - if (handleId === "position") { + if (handleId.kind === "position") { const rawX = startParams.centerX + deltaX / bounds.width; const rawY = startParams.centerY + deltaY / bounds.height; @@ -143,7 +143,7 @@ function computeSplitMaskParamUpdate({ }; } - if (handleId === "feather") { + if (handleId.kind === "feather") { const angleRad = (startParams.rotation * Math.PI) / 180; return computeFeatherUpdate({ startFeather: startParams.feather, @@ -154,7 +154,7 @@ function computeSplitMaskParamUpdate({ }); } - if (handleId === "rotation") { + if (handleId.kind === "rotation") { const pivotX = bounds.cx + startParams.centerX * bounds.width; const pivotY = bounds.cy + startParams.centerY * bounds.height; const startAngle = |
