Skip to content

Commit

Permalink
ensure json is preformatted.
Browse files Browse the repository at this point in the history
  • Loading branch information
wildone committed Jul 31, 2024
1 parent 713205d commit 407b699
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/js/panel._utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ window.Widgets.Panel.Utils = {};
minHeight: 20,
lineSpacing: 50,
indentSpacing: 40,
tooltipContent: 'summary', //'summary' or 'json'
tooltipContent: 'json', //'summary' or 'json'
itemFont: '18px',
edgeFontSize: '14px',
edgeFontFamily: 'Wire One',
Expand Down Expand Up @@ -334,7 +334,7 @@ window.Widgets.Panel.Utils = {};
let desc_string = pgraph_style;
// If Tooltip is JSON, then highlight, otherwise setup return string
if (ns.options.tooltipContent == 'json') {
return desc_string += ns.syntaxHighlight(jason);
return desc_string += '<pre>' + ns.syntaxHighlight(jason) + '</pre>';
}
// setup
// add heading
Expand Down

0 comments on commit 407b699

Please sign in to comment.