n8n/packages/nodes-base/nodes/Form/interfaces.ts
Michael Kret 953a58f18b
feat(n8n Form Trigger Node): Improvements (#7571)
Github issue / Community forum post (link here to close automatically):

---------

Co-authored-by: कारतोफ्फेलस्क्रिप्ट™ <aditya@netroy.in>
Co-authored-by: Giulio Andreini <andreini@netseven.it>
2023-12-13 17:00:51 +02:00

34 lines
771 B
TypeScript

export type FormField = {
fieldLabel: string;
fieldType: string;
requiredField: boolean;
fieldOptions?: { values: Array<{ option: string }> };
multiselect?: boolean;
};
export type FormTriggerInput = {
isSelect?: boolean;
isMultiSelect?: boolean;
isTextarea?: boolean;
isInput?: boolean;
labbel: string;
id: string;
errorId: string;
type?: 'text' | 'number' | 'date';
inputRequired: 'form-required' | '';
selectOptions?: string[];
multiSelectOptions?: Array<{ id: string; label: string }>;
};
export type FormTriggerData = {
testRun: boolean;
validForm: boolean;
formTitle: string;
formDescription?: string;
formSubmittedText?: string;
redirectUrl?: string;
n8nWebsiteLink: string;
formFields: FormTriggerInput[];
useResponseData?: boolean;
};