Skip to content

Commit

Permalink
update Router.js so that double-clicking an element with a url will o…
Browse files Browse the repository at this point in the history
…pen the url in a new window
  • Loading branch information
Dean Rather committed Feb 7, 2024
1 parent d9481d5 commit c9e4a85
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions modules/Router.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ export class Router {

handleElementDoubleClick = (event, elementId) => {
const element = structurizr.workspace.findElementById(elementId)

if(element.url) window.open(element.url, '_blank');

switch (element.type) {
case structurizr.constants.SOFTWARE_SYSTEM_ELEMENT_TYPE:
Expand Down

0 comments on commit c9e4a85

Please sign in to comment.