FieldConfig: {
    agencyLabel?: string;
    clearable?: boolean;
    data: T[];
    key: string;
    label: string;
    onChange?: (value: string | string[] | null) => void;
    onClear?: () => void;
    required?: boolean;
    value?: string | null;
}

Generic field configuration type for form or settings UI.

Type Parameters

  • T = DropdownOption

    The type of data options, defaults to DropdownOption | MeasurementOption.

Type declaration

  • OptionalagencyLabel?: string
  • Optionalclearable?: boolean
  • data: T[]
  • key: string
  • label: string
  • OptionalonChange?: (value: string | string[] | null) => void
  • OptionalonClear?: () => void
  • Optionalrequired?: boolean
  • Optionalvalue?: string | null