/**
 * Wrap the highcharts SVG function with this to embed Montserrat 300 so the
 * graph downloads don't look like garbage.
 */
Highcharts.wrap(Highcharts, 'downloadSVGLocal', function(
  p,
  svg,
  options,
  failCallback,
  successCallback
) {
  p(
    svg.replace(/<\/svg/, '<style>@font-face {font-family: "Montserrat";src: url("data:application/font-woff;charset=utf-8;base64,[encoded data, 42280 characters]");}</style>$&'),
    options,
    failCallback,
    successCallback
  );
});
