fix: correct global composite operation assignment in TextNode to ensure proper blend mode handling

This commit is contained in:
Maze Winther 2026-02-22 17:26:18 +01:00
parent d4c83c0a08
commit dc406c2579
1 changed files with 3 additions and 2 deletions

View File

@ -184,10 +184,11 @@ export class TextNode extends BaseNode<TextNodeParams> {
});
const prevAlpha = renderer.context.globalAlpha;
renderer.context.globalCompositeOperation =
renderer.context.globalCompositeOperation = (
this.params.blendMode && this.params.blendMode !== "normal"
? this.params.blendMode
: "source-over";
: "source-over"
) as GlobalCompositeOperation;
renderer.context.globalAlpha = this.params.opacity;
if (this.params.backgroundColor && lineCount > 0) {