diff options
author | Cheng-Han, Wu | 2016-06-17 16:27:37 +0800 |
---|---|---|
committer | Cheng-Han, Wu | 2016-06-17 16:27:37 +0800 |
commit | 71f61b7f840b7e557d44b130e69fdb3c9e24d6d9 (patch) | |
tree | c1251feaebefaa2f8e663680bbd45e506c845675 /public/js | |
parent | 5d031098274ddfd89d1d8476f896b881845f059a (diff) |
Update all client dependencies and cdn versions, workaround sequence-diagram svg to be resizable
Diffstat (limited to 'public/js')
-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); } |