diff options
Diffstat (limited to '')
-rw-r--r-- | public/js/extra.js | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/public/js/extra.js b/public/js/extra.js index b731770f..48e474a7 100644 --- a/public/js/extra.js +++ b/public/js/extra.js @@ -258,6 +258,9 @@ function finishView(view) { $ele.addClass('sequence-diagram'); $value.children().unwrap().unwrap(); + var svg = $ele.find('> svg'); + svg[0].setAttribute('viewBox', '0 0 ' + svg.attr('width') + ' ' + svg.attr('height')); + svg[0].setAttribute('preserveAspectRatio', 'xMidYMid meet'); } catch (err) { console.warn(err); } |