Skip to content

Commit

Permalink
Merge branch 'main' into feat/ports
Browse files Browse the repository at this point in the history
  • Loading branch information
hlxid committed Sep 14, 2023
2 parents 1217c75 + 418a1f1 commit eff13af
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/common/helpUi.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ export class HelpUI extends AbstractUIExtension {
<p><kbd>Del</kbd>: Delete selected elements</p>
<p><kbd>T</kbd>: Toggle Label Type Edit UI</p>
<p><kbd>CTRL</kbd>+<kbd>O</kbd>: Load diagram from json</p>
<p><kbd>CTRL</kbd>+<kbd>Alt</kbd>+<kbd>O</kbd>: Open default diagram</p>
<p><kbd>CTRL</kbd>+<kbd>Shift</kbd>+<kbd>O</kbd>: Open default diagram</p>
<p><kbd>CTRL</kbd>+<kbd>S</kbd>: Save diagram to json</p>
<p><kbd>CTRL</kbd>+<kbd>L</kbd>: Automatically layout diagram</p>
</div>
Expand Down
4 changes: 2 additions & 2 deletions src/features/dfdElements/edges.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -34,13 +34,13 @@ export class ArrowEdgeImpl extends DynamicChildrenEdge implements WithEditableLa
}

removeChildren(schema: ArrowEdge): void {
const label = schema.children?.find((element) => element.type === "label") as SLabel | undefined;
const label = schema.children?.find((element) => element.type.startsWith("label")) as SLabel | undefined;
schema.text = label?.text ?? "";
schema.children = [];
}

get editableLabel() {
const label = this.children.find((element) => element.type === "label");
const label = this.children.find((element) => element.type.startsWith("label"));
if (label && isEditableLabel(label)) {
return label;
}
Expand Down
3 changes: 3 additions & 0 deletions src/features/dfdElements/styles.css
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,9 @@ text {
font-size: 11pt;
text-anchor: middle;
dominant-baseline: central;

-webkit-user-select: none;
user-select: none;
}

/* elements with the sprotty-missing class use a node type that has not been registered.
Expand Down

0 comments on commit eff13af

Please sign in to comment.