/** * WordPress dependencies */ import { DropdownMenu, TextControl } from '@safe-wordpress/components'; import { useDispatch } from '@safe-wordpress/data'; import { _x } from '@safe-wordpress/i18n'; /** * External dependencies */ import { isDefined } from '@nab/utils'; /** * Internal dependencies */ import './style.scss'; import { AutomaticConversionActionList, ConversionActionList, } from './conversion-action-list'; import { ConversionActionTypeList } from './conversion-action-type-list'; import { ECommerceGoalSettings } from './ecommerce-goal-settings'; import { GA4Settings } from './ga4-settings'; import { store as NAB_EDITOR } from '../../store'; export type GoalProps = { readonly isAutomatic: boolean; readonly name: string; readonly duplicateGoal?: () => void; readonly removeGoal?: () => void; readonly setName: ( name: string ) => void; }; export const Goal = ( { name, setName, duplicateGoal, removeGoal, isAutomatic, }: GoalProps ): JSX.Element => (