SVG: scoped is passed as metadata

Instead of using a svg class to pass scope information
use notebook metadata.

Suggested by Matthias Bussonnier
This commit is contained in:
Pablo de Oliveira 2013-09-25 19:15:14 +02:00
parent 4c49abd2ae
commit 86dce97804

View File

@ -498,7 +498,7 @@ var IPython = (function (IPython) {
wrapper.append(svg);
var svg_element = wrapper.children()[0];
if (svg_element.classList.contains('ipython-scoped')) {
if (md['scoped']) {
// To avoid style or use collisions between multiple svg figures,
// svg figures are wrapped inside an iframe.
var iframe = $('<iframe/>')