From e1656111653d5857a54a4084e8e21fca0e09c2d0 Mon Sep 17 00:00:00 2001 From: Rayhan Alghiffari Azizi Date: Wed, 14 Feb 2024 09:41:34 +0700 Subject: [PATCH] diagram/update_style: add .Image and .MultilineText --- src/diagram.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/diagram.ts b/src/diagram.ts index b0c38f8..e90e94f 100644 --- a/src/diagram.ts +++ b/src/diagram.ts @@ -319,7 +319,10 @@ export class Diagram { let newd : Diagram = this.copy_if_not_mutable(); if (excludedType?.includes(newd.type)) { return newd; - } else if (newd.type == DiagramType.Polygon || newd.type == DiagramType.Curve || newd.type == DiagramType.Text) { + } else if (newd.type == DiagramType.Polygon || newd.type == DiagramType.Curve + || newd.type == DiagramType.Text || newd.type == DiagramType.Image + || newd.type == DiagramType.MultilineText + ) { newd.style[stylename] = stylevalue; } else if (newd.type == DiagramType.Diagram) { // newd.children = newd.children.map(c => c.update_style(stylename, stylevalue, excludedType));