import React from 'react' ; import { i18n } from '@kbn/i18n' ; import { TransactionDistribution } from './distribution' ; import type { TabContentProps } from './types' ; function TraceSamplesTab ( { selectSampleFromChartSelection , clearChartSelection , sampleRangeFrom , sampleRangeTo , traceSamples , } ) { return ( < TransactionDistribution onChartSelection = { selectSampleFromChartSelection } onClearSelection = { clearChartSelection } selection = { sampleRangeFrom !== undefined && sampleRangeTo !== undefined ? [ sampleRangeFrom , sampleRangeTo ] : undefined } traceSamples = { traceSamples } / > ) ; } export const traceSamplesTab = { dataTestSubj : 'apmTraceSamplesTabButton' , key : 'traceSamples' , label : i18n . translate ( 'xpack.apm.transactionDetails.tabs.traceSamplesLabel' , { defaultMessage : 'Trace samples' , } ) , component : TraceSamplesTab , } ;