findRoot method
RenderSVGContainer?
findRoot()
Implementation
RenderSVGContainer? findRoot() {
if (_rootRenderSVGContainer != null) {
return _rootRenderSVGContainer;
}
var parent = renderStyle.target.parentElement?.renderer;
while (parent is RenderBoxModel) {
if (parent is RenderSVGContainer) {
_rootRenderSVGContainer = parent;
return parent;
}
parent = parent.renderStyle.target.parentElement?.renderer;
}
return null;
}