: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
fix(cdp): remove non-functional disable toggle from hog function mappings (#70978)
Meikel Ratz721d063d177c
diff --git a/frontend/src/scenes/hog-functions/mapping/HogFunctionMappings.tsx b/frontend/src/scenes/hog-functions/mapping/HogFunctionMappings.tsxindex b3105e0e10d8..f7ce4b953c28 100644--- a/frontend/src/scenes/hog-functions/mapping/HogFunctionMappings.tsx+++ b/frontend/src/scenes/hog-functions/mapping/HogFunctionMappings.tsx@@ -12,7 +12,6 @@ import {LemonInput,LemonLabel,LemonSelect,- LemonTag,Tooltip,} from '@posthog/lemon-ui'@@ -76,7 +75,6 @@ export const MappingSummary = memo(function MappingSummary({: humanize(firstInputValue)}</span><span className="flex-1" />- {mapping.disabled ? <LemonTag type="danger">Disabled</LemonTag> : null}</span>)})@@ -99,18 +97,6 @@ export function HogFunctionMapping({return (<><div className="p-3 pl-10 deprecated-space-y-2">- {mapping.disabled ? (- <LemonBanner- type="warning"- className="p-2"- action={{- children: 'Enable',- onClick: () => onChange({ ...mapping, disabled: false }),- }}- >- This mapping is disabled. It will not trigger the function.- </LemonBanner>- ) : null}{!hideEventFilter && (<><LemonLabel>Match events and actions</LemonLabel>@@ -260,13 +246,6 @@ export function HogFunctionMappings(): JSX.Element | null {}}- const toggleDisabled = (mapping: HogFunctionMappingType): void => {- const index = mappingsValue.findIndex((m) => m === mapping)- if (index !== -1) {- onChange(mappingsValue.map((m, i) => (i === index ? { ...m, disabled: !m.disabled } : m)))- }- }-const renameMapping = (mapping: HogFunctionMappingType): void => {LemonDialog.openForm({title: 'Rename mapping',@@ -336,11 +315,6 @@ export function HogFunctionMappings(): JSX.Element | null {dropdown: {overlay: (<div className="deprecated-space-y-px">- <LemonButton- onClick={() => toggleDisabled(mapping)}- >- {mapping.disabled ? 'Enable' : 'Disable'}- </LemonButton><LemonButton onClick={() => renameMapping(mapping)}>Rename</LemonButton>diff --git a/frontend/src/types.ts b/frontend/src/types.tsindex b1793d7c9b86..28f6dc7b77bf 100644--- a/frontend/src/types.ts+++ b/frontend/src/types.ts@@ -7046,7 +7046,6 @@ export type CyclotronJobInputType = CyclotronInputTypeexport interface HogFunctionMappingType {name: string- disabled?: booleaninputs_schema?: CyclotronJobInputSchemaType[]inputs?: Record<string, CyclotronInputType> | nullfilters?: CyclotronJobFiltersType | nulldiff --git a/products/workflows/frontend/Workflows/hogflows/steps/components/HogFlowFunctionMappings.tsx b/products/workflows/frontend/Workflows/hogflows/steps/components/HogFlowFunctionMappings.tsxindex 9d675d3a9292..672feb7339c2 100644--- a/products/workflows/frontend/Workflows/hogflows/steps/components/HogFlowFunctionMappings.tsx+++ b/products/workflows/frontend/Workflows/hogflows/steps/components/HogFlowFunctionMappings.tsx@@ -85,13 +85,6 @@ export function HogFlowFunctionMappings({}}- const toggleDisabled = (mapping: HogFunctionMappingType): void => {- const index = mappingsValue.findIndex((m) => m === mapping)- if (index !== -1) {- onChange(mappingsValue.map((m, i) => (i === index ? { ...m, disabled: !m.disabled } : m)))- }- }-const renameMapping = (mapping: HogFunctionMappingType): void => {LemonDialog.openForm({title: 'Rename mapping',@@ -156,9 +149,6 @@ export function HogFlowFunctionMappings({dropdown: {overlay: (<div className="deprecated-space-y-px">- <LemonButton onClick={() => toggleDisabled(mapping)}>- {mapping.disabled ? 'Enable' : 'Disable'}- </LemonButton><LemonButton onClick={() => renameMapping(mapping)}>Rename</LemonButton>