n8n/packages/nodes-base/nodes/Form/interfaces.ts
Michael Kret 3ddc176dfa
feat(n8n Form Trigger Node): New node (#7130)
Github issue / Community forum post (link here to close automatically):

based on https://github.com/joffcom/n8n-nodes-form-trigger

---------

Co-authored-by: Giulio Andreini <g.andreini@gmail.com>
2023-10-17 07:09:30 +03:00

31 lines
697 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;
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;
n8nWebsiteLink: string;
formFields: FormTriggerInput[];
};