options, addFailureCb);

      this.metricLatenciesMs_.push(new Date() - startDate);
      while (this.metricLatenciesMs_.length > 20) {
        this.metricLatenciesMs_.shift();
      }

      this.recomputeButton_.style.background = '';

      await this.$.results.build(histograms);
    }
  });

  tr.ui.side_panel.SidePanelRegistry.register(function() {
    return document.createElement('tr-ui-sp-metrics-side-panel');
  });

  return {};
});
</script>
