code: function savePNG(svg, scaleFactor) {
      svg.selectAll(classes.join(', ')).each(function inlineProps() {
          const element = this;
          const computedStyle = getComputedStyle(element, null);
  
          // loop through and compute inline svg styles
          for (let i = 0; i < computedStyle.length; i += 1) {
              const property = computedStyle.item(i);
              const value = computedStyle.getPropertyValue(property);
              element.style[property] = value;
          }
      });
  
      saveSvgAsPng(
          svg.node(),
          `${svg
              .select('title')
              .text()
              .replace(/\s/g, '-')
              .toLowerCase()}.png`,
          { scale: scaleFactor },
      );
  }
docs: /* istanbul ignore next