feat(funnels): add per-step filter UI to funnel creation form

This commit is contained in:
Rudy B. committed 2026-03-16 21:51:16 +01:00
1 parent 96ae1de7fd
commit 8f0ccf84a9
2 files changed
+343 -35

No files matched your search

+14 -1
View File
@@ -9,9 +9,21 @@ export interface LookupFieldProps extends ComboBoxProps {
type: string;
value: string;
onChange: (value: string) => void;
/**
* `FormField` injects `onChange` via `cloneElement`, overwriting any custom handler.
* Use `onValueChange` for side effects that must survive that override.
*/
onValueChange?: (value: string) => void;
}
export function LookupField({ websiteId, type, value, onChange, ...props }: LookupFieldProps) {
export function LookupField({
websiteId,
type,
value,
onChange,
onValueChange,
...props
}: LookupFieldProps) {
const { formatMessage, messages } = useMessages();
const [search, setSearch] = useState(value);
const searchValue = useDebounce(search, 300);
@@ -43,6 +55,7 @@ export function LookupField({ websiteId, type, value, onChange, ...props }: Look
onInputChange={value => {
handleSearch(value);
onChange?.(value);
onValueChange?.(value);
}}
formValue="text"
allowsEmptyCollection