d3.demo.container = function() { "use strict"; var shape = d3.demo.shape(), children = [], flowbox = null; function container(selection) { shape.call(shape, selection); d3.select(shape.node).classed("container", true); flowbox = d3.demo.flowbox().shape(shape).x(5).y(30); d3.select(shape.node).call(flowbox); container.node = shape.node; container.render = function() { flowbox.children(children).render(); setTimeout(shape.render, 250); // give flow time to run before rendering }; container.render(); } container.children = function(value) { if (!arguments.length) { return children; } children = value; return this; }; return d3_shape_rebind(container, shape); };