:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.
Python ab-testingai-analyticsanalyticscdpdata-warehouseexperimentsfeature-flagsjavascriptproduct-analyticspythonreactsession-replaysurveystypescriptweb-analytics
import { ExperimentMetric } from '~/queries/schema/schema-general'
import { BreakdownAttributionType } from '~/types'
import { MetricBreakdowns } from './MetricBreakdowns'
export type MetricBreakdownErrorProps = {
metric: ExperimentMetric
isAlternatingRow: boolean
onRemoveBreakdown: (index: number) => void
onAttributionChange: (attributionType: BreakdownAttributionType, attributionValue?: number) => void
onBreakdownLimitChange: (breakdownLimit: number) => void
}
export function MetricBreakdownError({
metric,
isAlternatingRow,
onRemoveBreakdown,
onAttributionChange,
onBreakdownLimitChange,
}: MetricBreakdownErrorProps): JSX.Element {
return (
<tr data-breakdown-row className="hover:bg-bg-hover group">
<td colSpan={7} className={`p-0 border-t border-b ${isAlternatingRow ? 'bg-bg-table' : 'bg-bg-light'}`}>
<div className="p-1">
<MetricBreakdowns
metric={metric}
onRemoveBreakdown={onRemoveBreakdown}
onAttributionChange={onAttributionChange}
onBreakdownLimitChange={onBreakdownLimitChange}
/>
</div>
</td>
</tr>
)
}