_getActiveElements(e, lastActive, replay, inChartArea) {
    const options = this.options;

    if (e.type === 'mouseout') {
      return [];
    }

    if (!inChartArea) {
      // Let user control the active elements outside chartArea. Eg. using Legend.
      // But make sure that active elements are still valid.
      return lastActive.filter(i =>
        this.chart.data.datasets[i.datasetIndex] &&
        this.chart.getDatasetMeta(i.datasetIndex).controller.getParsed(i.index) !== undefined
      );
    }

    // Find Active Elements for tooltips
    const active = this.chart.getElementsAtEventForMode(e, options.mode, options, replay);

    if (options.reverse) {
      active.reverse();
    }

    return active;
  }
Helper for determining the active elements for event
@param {ChartEvent} e - The event to handle
@param {InteractionItem[]} lastActive - Previously active elements
@param {boolean} [replay] - This is a replayed event (from update)
@param {boolean} [inChartArea] - The event is inside chartArea
@returns {InteractionItem[]} - Active elements
@private