Skip to content

Commit

Permalink
diagram/update_style: add .Image and .MultilineText
Browse files Browse the repository at this point in the history
  • Loading branch information
ray-pH committed Feb 14, 2024
1 parent 6939504 commit e165611
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/diagram.ts
Original file line number Diff line number Diff line change
Expand Up @@ -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));
Expand Down

0 comments on commit e165611

Please sign in to comment.