@bigbinary/neeto-form-frontend 1.2.6 → 1.2.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +77 -273
- package/dist/index.cjs.js +14070 -21395
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.js +14130 -21455
- package/dist/index.js.map +1 -1
- package/dist/main.css +2 -1
- package/dist/main.css.map +1 -0
- package/package.json +143 -89
- package/types.d.ts +3 -0
- package/index.d.ts +0 -268
- /package/{src → app/javascript/src}/translations/de.json +0 -0
- /package/{src → app/javascript/src}/translations/en.json +0 -0
package/package.json
CHANGED
|
@@ -1,144 +1,198 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bigbinary/neeto-form-frontend",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.8",
|
|
4
4
|
"description": "Neeto Form Engine Frontend",
|
|
5
|
+
"license": "UNLICENSED",
|
|
6
|
+
"homepage": "https://github.com/bigbinary/neeto-form-nano",
|
|
7
|
+
"bugs": {
|
|
8
|
+
"url": "https://github.com/bigbinary/neeto-form-nano/issues"
|
|
9
|
+
},
|
|
10
|
+
"repository": "neeto-form-nano",
|
|
5
11
|
"author": "BigBinary",
|
|
6
|
-
"
|
|
7
|
-
|
|
12
|
+
"files": [
|
|
13
|
+
"dist",
|
|
14
|
+
"types.d.ts",
|
|
15
|
+
"app/javascript/src/translations"
|
|
16
|
+
],
|
|
8
17
|
"main": "dist/index.cjs.js",
|
|
9
18
|
"module": "dist/index.js",
|
|
10
|
-
"types": "
|
|
11
|
-
"engines": {
|
|
12
|
-
"node": "18.12",
|
|
13
|
-
"npm": "9.x",
|
|
14
|
-
"yarn": "1.22.x"
|
|
15
|
-
},
|
|
19
|
+
"types": "types.d.ts",
|
|
16
20
|
"scripts": {
|
|
17
21
|
"build": "NODE_ENV=production rollup -c --environment production",
|
|
18
|
-
"release": "yarn build && yalc push --sig",
|
|
19
22
|
"prepare": "husky install",
|
|
20
|
-
"
|
|
23
|
+
"release": "yarn build && yalc push --sig",
|
|
24
|
+
"build-preview": "NODE_ENV=production webpack"
|
|
21
25
|
},
|
|
22
26
|
"lint-staged": {
|
|
23
|
-
"
|
|
27
|
+
"./**/app/javascript/**/*.{js,jsx,json}": [
|
|
24
28
|
"prettier --write",
|
|
25
29
|
"eslint --fix"
|
|
30
|
+
],
|
|
31
|
+
"./test/dummy/**/app/javascript/**/*.{js,jsx,json}": [
|
|
32
|
+
"prettier --write",
|
|
33
|
+
"eslint --fix"
|
|
34
|
+
],
|
|
35
|
+
"./**/*.rb": [
|
|
36
|
+
"bundle exec rubocop -a --force-exclusion"
|
|
37
|
+
],
|
|
38
|
+
"{Gemfile,Rakefile,config.ru}": [
|
|
39
|
+
"bundle exec rubocop -a --force-exclusion"
|
|
26
40
|
]
|
|
27
41
|
},
|
|
28
42
|
"devDependencies": {
|
|
29
|
-
"@babel/core": "
|
|
30
|
-
"@babel/eslint-parser": "7.
|
|
31
|
-
"@babel/plugin-transform-runtime": "
|
|
32
|
-
"@babel/preset-env": "7.
|
|
33
|
-
"@babel/preset-react": "7.
|
|
34
|
-
"@babel/preset-typescript": "
|
|
35
|
-
"@babel/runtime": "
|
|
43
|
+
"@babel/core": "7.22.6",
|
|
44
|
+
"@babel/eslint-parser": "7.22.6",
|
|
45
|
+
"@babel/plugin-transform-runtime": "7.22.6",
|
|
46
|
+
"@babel/preset-env": "7.22.6",
|
|
47
|
+
"@babel/preset-react": "7.22.5",
|
|
48
|
+
"@babel/preset-typescript": "7.22.5",
|
|
49
|
+
"@babel/runtime": "7.22.6",
|
|
36
50
|
"@bigbinary/babel-preset-neeto": "^1.0.6",
|
|
37
51
|
"@bigbinary/eslint-plugin-neeto": "^1.1.14",
|
|
38
|
-
"@bigbinary/neeto-audit-frontend": "1.0.
|
|
52
|
+
"@bigbinary/neeto-audit-frontend": "1.0.8",
|
|
39
53
|
"@bigbinary/neeto-cist": "^1.0.2",
|
|
40
|
-
"@bigbinary/neeto-commons-frontend": "
|
|
54
|
+
"@bigbinary/neeto-commons-frontend": "3.0.1",
|
|
41
55
|
"@bigbinary/neeto-editor": "1.20.0",
|
|
42
56
|
"@bigbinary/neeto-icons": "1.9.12",
|
|
43
57
|
"@bigbinary/neeto-molecules": "^1.0.19",
|
|
44
58
|
"@bigbinary/neetoui": "^5.2.1",
|
|
45
|
-
"@
|
|
46
|
-
"@
|
|
47
|
-
"@
|
|
48
|
-
"@rollup/plugin-
|
|
49
|
-
"@rollup/plugin-
|
|
50
|
-
"@rollup/plugin-
|
|
51
|
-
"@rollup/plugin-
|
|
52
|
-
"@rollup/plugin-
|
|
53
|
-
"@
|
|
54
|
-
"@
|
|
55
|
-
"antd": "
|
|
56
|
-
"autoprefixer": "
|
|
57
|
-
"axios": "
|
|
58
|
-
"babel-loader": "
|
|
59
|
-
"babel-plugin-istanbul": "
|
|
59
|
+
"@emotion/is-prop-valid": "1.2.0",
|
|
60
|
+
"@faker-js/faker": "8.0.2",
|
|
61
|
+
"@honeybadger-io/react": "2.0.1",
|
|
62
|
+
"@rollup/plugin-alias": "5.0.0",
|
|
63
|
+
"@rollup/plugin-babel": "6.0.3",
|
|
64
|
+
"@rollup/plugin-commonjs": "25.0.2",
|
|
65
|
+
"@rollup/plugin-json": "6.0.0",
|
|
66
|
+
"@rollup/plugin-node-resolve": "15.1.0",
|
|
67
|
+
"@rollup/plugin-replace": "5.0.2",
|
|
68
|
+
"@svgr/rollup": "8.0.1",
|
|
69
|
+
"antd": "4.24.12",
|
|
70
|
+
"autoprefixer": "10.4.14",
|
|
71
|
+
"axios": "1.4.0",
|
|
72
|
+
"babel-loader": "9.1.2",
|
|
73
|
+
"babel-plugin-istanbul": "6.1.1",
|
|
60
74
|
"babel-plugin-js-logger": "1.0.17",
|
|
61
75
|
"babel-plugin-macros": "3.1.0",
|
|
62
76
|
"babel-plugin-preval": "^5.1.0",
|
|
63
77
|
"babel-plugin-transform-react-remove-prop-types": "0.4.24",
|
|
64
78
|
"babel-preset-react": "6.24.1",
|
|
65
|
-
"babel-preset-typescript": "
|
|
66
|
-
"
|
|
79
|
+
"babel-preset-typescript": "7.0.0-alpha.19",
|
|
80
|
+
"browserify-zlib": "0.2.0",
|
|
81
|
+
"buffer": "6.0.3",
|
|
82
|
+
"classnames": "2.3.2",
|
|
83
|
+
"crypto-browserify": "3.12.0",
|
|
84
|
+
"css-loader": "6.8.1",
|
|
67
85
|
"dayjs": "1.11.1",
|
|
68
|
-
"
|
|
69
|
-
"
|
|
70
|
-
"eslint
|
|
71
|
-
"eslint-
|
|
86
|
+
"dompurify": "3.0.2",
|
|
87
|
+
"dotenv-webpack": "^8.0.1",
|
|
88
|
+
"eslint": "8.44.0",
|
|
89
|
+
"eslint-config-prettier": "8.8.0",
|
|
90
|
+
"eslint-plugin-cypress": "2.13.3",
|
|
91
|
+
"eslint-plugin-import": "2.27.5",
|
|
72
92
|
"eslint-plugin-jam3": "0.2.3",
|
|
73
93
|
"eslint-plugin-json": "3.1.0",
|
|
74
|
-
"eslint-plugin-prettier": "4.
|
|
75
|
-
"eslint-plugin-promise": "6.
|
|
76
|
-
"eslint-plugin-react": "7.
|
|
77
|
-
"eslint-plugin-react-hooks": "4.
|
|
94
|
+
"eslint-plugin-prettier": "4.2.1",
|
|
95
|
+
"eslint-plugin-promise": "6.1.1",
|
|
96
|
+
"eslint-plugin-react": "7.32.2",
|
|
97
|
+
"eslint-plugin-react-hooks": "4.6.0",
|
|
98
|
+
"eslint-plugin-security": "^1.7.1",
|
|
99
|
+
"eslint-plugin-sonarjs": "^0.21.0",
|
|
78
100
|
"eslint-plugin-unused-imports": "2.0.0",
|
|
79
|
-
"
|
|
80
|
-
"
|
|
101
|
+
"eslint-plugin-xss": "^0.1.12",
|
|
102
|
+
"formik": "2.4.2",
|
|
103
|
+
"html-webpack-plugin": "5.5.3",
|
|
104
|
+
"https-browserify": "1.0.0",
|
|
105
|
+
"husky": "8.0.3",
|
|
81
106
|
"i18next": "23.2.7",
|
|
82
|
-
"
|
|
107
|
+
"i18next-browser-languagedetector": "7.0.1",
|
|
108
|
+
"js-logger": "1.6.1",
|
|
83
109
|
"libphonenumber-js": "^1.10.9",
|
|
84
|
-
"lint-staged": "
|
|
85
|
-
"
|
|
86
|
-
"
|
|
87
|
-
"
|
|
88
|
-
"
|
|
89
|
-
"
|
|
90
|
-
"
|
|
110
|
+
"lint-staged": "13.2.3",
|
|
111
|
+
"mini-css-extract-plugin": "2.7.6",
|
|
112
|
+
"mixpanel-browser": "2.47.0",
|
|
113
|
+
"os-browserify": "0.3.0",
|
|
114
|
+
"path-browserify": "1.0.1",
|
|
115
|
+
"postcss": "8.4.31",
|
|
116
|
+
"postcss-import": "15.1.0",
|
|
117
|
+
"postcss-loader": "7.3.3",
|
|
118
|
+
"postcss-preset-env": "9.0.0",
|
|
119
|
+
"prettier": "2.8.8",
|
|
120
|
+
"prettier-plugin-tailwindcss": "0.3.0",
|
|
121
|
+
"process": "0.11.10",
|
|
91
122
|
"prop-types": "15.8.1",
|
|
92
123
|
"ramda": "0.29.0",
|
|
93
124
|
"react": "^18.2.0",
|
|
94
125
|
"react-beautiful-dnd": "^13.1.0",
|
|
95
126
|
"react-dom": "^18.2.0",
|
|
96
|
-
"react-helmet": "
|
|
127
|
+
"react-helmet": "6.1.0",
|
|
97
128
|
"react-i18next": "13.0.1",
|
|
98
129
|
"react-linkify": "^1.0.0-alpha",
|
|
99
|
-
"react-query": "3.39.
|
|
130
|
+
"react-query": "3.39.3",
|
|
100
131
|
"react-router-dom": "5.3.3",
|
|
101
132
|
"react-select": "^5.3.2",
|
|
102
|
-
"react-svg-loader": "^3.0.3",
|
|
103
133
|
"react-toastify": "8.0.2",
|
|
104
|
-
"
|
|
105
|
-
"rollup
|
|
106
|
-
"rollup-plugin-
|
|
107
|
-
"
|
|
134
|
+
"react_ujs": "^3.1.1",
|
|
135
|
+
"rollup": "2.79.1",
|
|
136
|
+
"rollup-plugin-analyzer": "4.0.0",
|
|
137
|
+
"rollup-plugin-cleaner": "1.0.0",
|
|
138
|
+
"rollup-plugin-peer-deps-external": "2.2.4",
|
|
139
|
+
"rollup-plugin-styles": "4.0.0",
|
|
140
|
+
"sass": "1.63.6",
|
|
141
|
+
"sass-loader": "13.3.2",
|
|
142
|
+
"shakapacker": "6.6.0",
|
|
143
|
+
"stream-browserify": "3.0.0",
|
|
144
|
+
"stream-http": "3.2.0",
|
|
145
|
+
"style-loader": "3.3.3",
|
|
108
146
|
"tailwindcss": "npm:@tailwindcss/postcss7-compat",
|
|
147
|
+
"tty-browserify": "0.0.1",
|
|
148
|
+
"url": "0.11.1",
|
|
149
|
+
"util": "0.12.5",
|
|
109
150
|
"uuid": "^9.0.0",
|
|
110
|
-
"
|
|
111
|
-
"
|
|
112
|
-
"
|
|
113
|
-
"
|
|
114
|
-
"
|
|
151
|
+
"vm-browserify": "1.1.2",
|
|
152
|
+
"webpack": "5.88.1",
|
|
153
|
+
"webpack-assets-manifest": "5.1.0",
|
|
154
|
+
"webpack-cli": "5.1.4",
|
|
155
|
+
"webpack-dev-server": "4.15.1",
|
|
156
|
+
"yup": "0.32.11",
|
|
115
157
|
"zustand": "4.3.2"
|
|
116
158
|
},
|
|
117
159
|
"peerDependencies": {
|
|
118
|
-
"@bigbinary/neeto-
|
|
119
|
-
"@bigbinary/neeto-
|
|
120
|
-
"@bigbinary/neeto-
|
|
121
|
-
"@bigbinary/neeto-
|
|
122
|
-
"@bigbinary/
|
|
123
|
-
"
|
|
124
|
-
"
|
|
125
|
-
"
|
|
160
|
+
"@bigbinary/neeto-cist": "latest",
|
|
161
|
+
"@bigbinary/neeto-commons-frontend": "^2.1.28",
|
|
162
|
+
"@bigbinary/neeto-editor": "^1.26.3",
|
|
163
|
+
"@bigbinary/neeto-icons": "^1.9.22",
|
|
164
|
+
"@bigbinary/neeto-molecules": "^1.0.9",
|
|
165
|
+
"@bigbinary/neetoui": "^4.4.10",
|
|
166
|
+
"@honeybadger-io/react": "^2.0.1",
|
|
167
|
+
"axios": "^0.27.2",
|
|
168
|
+
"classnames": "^2.3.2",
|
|
126
169
|
"dayjs": "1.11.1",
|
|
127
|
-
"formik": "2.2.9",
|
|
170
|
+
"formik": "^2.2.9",
|
|
128
171
|
"i18next": "23.2.7",
|
|
129
172
|
"js-logger": "^1.6.1",
|
|
130
|
-
"
|
|
131
|
-
"
|
|
132
|
-
"react
|
|
173
|
+
"mixpanel-browser": "^2.45.0",
|
|
174
|
+
"ramda": "^0.29.0",
|
|
175
|
+
"react": "18.2.0",
|
|
176
|
+
"react-dom": "18.2.0",
|
|
177
|
+
"react-helmet": "^6.1.0",
|
|
133
178
|
"react-i18next": "13.0.1",
|
|
134
|
-
"react-
|
|
135
|
-
"react-
|
|
136
|
-
"
|
|
137
|
-
"
|
|
179
|
+
"react-query": "3.39.2",
|
|
180
|
+
"react-router-dom": "5.3.3",
|
|
181
|
+
"react-toastify": "8.2.0",
|
|
182
|
+
"yup": "^0.32.11",
|
|
183
|
+
"zustand": "4.3.2"
|
|
138
184
|
},
|
|
139
|
-
"
|
|
140
|
-
"
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
185
|
+
"resolutions": {
|
|
186
|
+
"postcss": "^8"
|
|
187
|
+
},
|
|
188
|
+
"engines": {
|
|
189
|
+
"node": ">=18.12",
|
|
190
|
+
"npm": ">=9",
|
|
191
|
+
"yarn": ">=1.22"
|
|
192
|
+
},
|
|
193
|
+
"dependencies": {
|
|
194
|
+
"react-router-nav-prompt": "0.4.1",
|
|
195
|
+
"source-map-loader": "^4.0.1",
|
|
196
|
+
"zustand": "4.3.2"
|
|
197
|
+
}
|
|
144
198
|
}
|
package/types.d.ts
ADDED
package/index.d.ts
DELETED
|
@@ -1,268 +0,0 @@
|
|
|
1
|
-
import axios from "axios";
|
|
2
|
-
import { ButtonProps, TypographyProps } from "@bigbinary/neetoui";
|
|
3
|
-
import React, { FormHTMLAttributes, HTMLAttributes } from "react";
|
|
4
|
-
import {
|
|
5
|
-
UseQueryResult,
|
|
6
|
-
UseMutationResult,
|
|
7
|
-
UseQueryOptions,
|
|
8
|
-
UseMutationOptions,
|
|
9
|
-
} from "react-query";
|
|
10
|
-
import { EditorProps } from "@bigbinary/neeto-editor";
|
|
11
|
-
import { Schema } from "yup";
|
|
12
|
-
|
|
13
|
-
interface Question {
|
|
14
|
-
id: string;
|
|
15
|
-
entityId?: string;
|
|
16
|
-
entityType?: string;
|
|
17
|
-
label: string;
|
|
18
|
-
placeholder?: string;
|
|
19
|
-
isRequired?: boolean;
|
|
20
|
-
optionsAttributes?: {
|
|
21
|
-
id: string;
|
|
22
|
-
label: string;
|
|
23
|
-
displayOrder: number;
|
|
24
|
-
}[];
|
|
25
|
-
highestRatingLabel?: string;
|
|
26
|
-
lowestRatingLabel?: string;
|
|
27
|
-
averageRatingLabel?: string;
|
|
28
|
-
options?: KeyValuePair[];
|
|
29
|
-
count?: number;
|
|
30
|
-
shape?: string;
|
|
31
|
-
kind: string;
|
|
32
|
-
[key: string]: any;
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
interface BuildFormProps {
|
|
36
|
-
id: string;
|
|
37
|
-
allowAdditionalGuests?: boolean;
|
|
38
|
-
onUpdate?: (data: any) => void;
|
|
39
|
-
buildRequestArgs?: any;
|
|
40
|
-
showAddQuestionDivider?: boolean;
|
|
41
|
-
nonRemovableFields?: string[];
|
|
42
|
-
requiredFields?: string[];
|
|
43
|
-
formDomProps?: FormHTMLAttributes<HTMLFormElement>;
|
|
44
|
-
showActionBlock?: boolean;
|
|
45
|
-
submitButtonProps?: HTMLAttributes<HTMLButtonElement>;
|
|
46
|
-
cancelButtonProps?: HTMLAttributes<HTMLButtonElement>;
|
|
47
|
-
questionKinds?: KeyValuePair[];
|
|
48
|
-
isKindAlreadyActive?: (args: {
|
|
49
|
-
activeQuestions: KeyValuePair[];
|
|
50
|
-
kind: KeyValuePair;
|
|
51
|
-
}) => boolean;
|
|
52
|
-
getActiveKindDetails?: (args: {
|
|
53
|
-
allQuestionKinds: KeyValuePair[];
|
|
54
|
-
item: Item;
|
|
55
|
-
}) => {
|
|
56
|
-
kind: string;
|
|
57
|
-
label: string;
|
|
58
|
-
FieldComponent: React.FC;
|
|
59
|
-
FieldIcon: string | any;
|
|
60
|
-
isSingular: boolean;
|
|
61
|
-
};
|
|
62
|
-
showLoader?: boolean;
|
|
63
|
-
kindUniqueOn?: string[];
|
|
64
|
-
isFieldRequired?: (item: Item) => boolean;
|
|
65
|
-
isFieldLabelDisabled?: (item: Item) => boolean;
|
|
66
|
-
isQuestionDeletable?: (item: Item) => boolean;
|
|
67
|
-
disabledAddButtonTooltipProps?: DisabledAddButtonTooltipProps;
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
interface ExternalFormProps {
|
|
71
|
-
preview?: boolean;
|
|
72
|
-
formId: string;
|
|
73
|
-
submissionId?: string;
|
|
74
|
-
customSubmitHandler?: (data: any) => void;
|
|
75
|
-
onBeforeSubmit?: (
|
|
76
|
-
data: any,
|
|
77
|
-
values: any
|
|
78
|
-
) => any | Promise<any> | void | Promise<void> | undefined | null;
|
|
79
|
-
onSubmitSuccess?: (data: any) => void;
|
|
80
|
-
showTitle?: boolean;
|
|
81
|
-
formTitle?: string;
|
|
82
|
-
titleProps?: TypographyProps;
|
|
83
|
-
submitRequestArgs?: any;
|
|
84
|
-
footer?: React.ReactNode;
|
|
85
|
-
submitButtonProps?: ButtonProps;
|
|
86
|
-
cancelButtonProps?: ButtonProps;
|
|
87
|
-
resetButtonProps?: ButtonProps;
|
|
88
|
-
showPrefixIcons?: boolean;
|
|
89
|
-
displayThankYou?: boolean;
|
|
90
|
-
showSuccessToastr?: boolean;
|
|
91
|
-
showEmptyState?: boolean;
|
|
92
|
-
className?: string;
|
|
93
|
-
preserveValues?: boolean;
|
|
94
|
-
clearValuesOnReset?: boolean;
|
|
95
|
-
clearValuesOnSubmit?: boolean;
|
|
96
|
-
onChange?: (values: any) => void;
|
|
97
|
-
initialValues?: any;
|
|
98
|
-
formDomProps?: FormHTMLAttributes<HTMLFormElement>;
|
|
99
|
-
editorProps?: EditorProps;
|
|
100
|
-
customValidator?: (question: Question) => Schema;
|
|
101
|
-
}
|
|
102
|
-
|
|
103
|
-
interface DisabledAddButtonTooltipProps {
|
|
104
|
-
content?: string
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
interface SubmissionProps {
|
|
108
|
-
formId: string;
|
|
109
|
-
submissionId: string;
|
|
110
|
-
className?: string;
|
|
111
|
-
questionLabelProps?: TypographyProps;
|
|
112
|
-
answerProps?: TypographyProps;
|
|
113
|
-
}
|
|
114
|
-
|
|
115
|
-
interface IBuildFormState {
|
|
116
|
-
values: any;
|
|
117
|
-
dirty: boolean;
|
|
118
|
-
isSubmitting: boolean;
|
|
119
|
-
isValid: boolean;
|
|
120
|
-
errors: { [key: string]: string }[];
|
|
121
|
-
submitForm: () => void;
|
|
122
|
-
resetForm: () => void;
|
|
123
|
-
}
|
|
124
|
-
|
|
125
|
-
interface ISubmission {
|
|
126
|
-
responses: {
|
|
127
|
-
label: string;
|
|
128
|
-
value: string;
|
|
129
|
-
kind: string;
|
|
130
|
-
}[];
|
|
131
|
-
}
|
|
132
|
-
|
|
133
|
-
interface KeyValuePair {
|
|
134
|
-
[key: string]: any;
|
|
135
|
-
}
|
|
136
|
-
|
|
137
|
-
interface UpdateHookResponse<TData = unknown, TError = unknown>
|
|
138
|
-
extends Omit<UseMutationResult<TData, TError>, "mutate" | "mutateAsync"> {
|
|
139
|
-
mutate: (args: { id: string; values: KeyValuePair }) => Promise<TData>;
|
|
140
|
-
mutateAsync: (args: { id: string; values: KeyValuePair }) => Promise<TData>;
|
|
141
|
-
}
|
|
142
|
-
|
|
143
|
-
interface CreateHookResponse<TData = unknown, TError = unknown>
|
|
144
|
-
extends Omit<UseMutationResult<TData, TError>, "mutate" | "mutateAsync"> {
|
|
145
|
-
mutate: (values: KeyValuePair) => Promise<TData>;
|
|
146
|
-
mutateAsync: (values: KeyValuePair) => Promise<TData>;
|
|
147
|
-
}
|
|
148
|
-
|
|
149
|
-
interface DeleteHookResponse<TData = unknown, TError = unknown>
|
|
150
|
-
extends Omit<UseMutationResult<TData, TError>, "mutate" | "mutateAsync"> {
|
|
151
|
-
mutate: (args: { id: string }) => Promise<TData>;
|
|
152
|
-
mutateAsync: (args: { id: string }) => Promise<TData>;
|
|
153
|
-
}
|
|
154
|
-
|
|
155
|
-
interface FormHookOptions extends UseQueryOptions {
|
|
156
|
-
formId: string;
|
|
157
|
-
preview?: boolean;
|
|
158
|
-
}
|
|
159
|
-
|
|
160
|
-
interface Item {
|
|
161
|
-
label: string;
|
|
162
|
-
isRequired: boolean;
|
|
163
|
-
optionsAttributes: KeyValuePair[];
|
|
164
|
-
metadata?: KeyValuePair[];
|
|
165
|
-
kind: string;
|
|
166
|
-
nodeId: string;
|
|
167
|
-
}
|
|
168
|
-
|
|
169
|
-
interface EmailProps {
|
|
170
|
-
name: string;
|
|
171
|
-
isRequired: boolean;
|
|
172
|
-
}
|
|
173
|
-
|
|
174
|
-
interface DropdownProps {
|
|
175
|
-
item: Item;
|
|
176
|
-
name: string;
|
|
177
|
-
isRequired: boolean;
|
|
178
|
-
}
|
|
179
|
-
|
|
180
|
-
interface ShortTextProps {
|
|
181
|
-
name: string;
|
|
182
|
-
isRequired: boolean;
|
|
183
|
-
}
|
|
184
|
-
|
|
185
|
-
interface LongTextProps {
|
|
186
|
-
name: string;
|
|
187
|
-
isRequired: boolean;
|
|
188
|
-
}
|
|
189
|
-
|
|
190
|
-
interface MultipleChoiceProps {
|
|
191
|
-
item: Item;
|
|
192
|
-
name: string;
|
|
193
|
-
isRequired: boolean;
|
|
194
|
-
}
|
|
195
|
-
|
|
196
|
-
interface SingleChoiceProps {
|
|
197
|
-
item: Item;
|
|
198
|
-
name: string;
|
|
199
|
-
isRequired: boolean;
|
|
200
|
-
}
|
|
201
|
-
|
|
202
|
-
interface PhoneProps {
|
|
203
|
-
name: string;
|
|
204
|
-
isRequired: boolean;
|
|
205
|
-
}
|
|
206
|
-
|
|
207
|
-
interface RatingProps {
|
|
208
|
-
name: string;
|
|
209
|
-
isRequired: boolean;
|
|
210
|
-
}
|
|
211
|
-
|
|
212
|
-
interface TermsProps {
|
|
213
|
-
name: string;
|
|
214
|
-
}
|
|
215
|
-
|
|
216
|
-
interface StarRatingProps {
|
|
217
|
-
name: string;
|
|
218
|
-
isRequired: boolean;
|
|
219
|
-
}
|
|
220
|
-
|
|
221
|
-
interface AdditionalGuestsProps {
|
|
222
|
-
name: string;
|
|
223
|
-
}
|
|
224
|
-
|
|
225
|
-
interface ConditionProps {
|
|
226
|
-
name: string;
|
|
227
|
-
isRequired: boolean;
|
|
228
|
-
}
|
|
229
|
-
|
|
230
|
-
export const BuildForm: React.FC<BuildFormProps>;
|
|
231
|
-
export const ExternalForm: React.FC<ExternalFormProps>;
|
|
232
|
-
export const Submission: React.FC<SubmissionProps>;
|
|
233
|
-
export const NeetoFormProvider: React.FC;
|
|
234
|
-
export const Fields: {
|
|
235
|
-
Email: React.FC<EmailProps>;
|
|
236
|
-
Dropdown: React.FC<DropdownProps>;
|
|
237
|
-
ShortText: React.FC<ShortTextProps>;
|
|
238
|
-
LongText: React.FC<LongTextProps>;
|
|
239
|
-
MultipleChoice: React.FC<MultipleChoiceProps>;
|
|
240
|
-
SingleChoice: React.FC<SingleChoiceProps>;
|
|
241
|
-
Phone: React.FC<PhoneProps>;
|
|
242
|
-
Rating: React.FC<RatingProps>;
|
|
243
|
-
Terms: React.FC<TermsProps>;
|
|
244
|
-
StarRating: React.FC<StarRatingProps>;
|
|
245
|
-
AdditionalGuests: React.FC<AdditionalGuestsProps>;
|
|
246
|
-
Condition: React.FC<ConditionProps>;
|
|
247
|
-
};
|
|
248
|
-
|
|
249
|
-
export const useBuildFormState: () => IBuildFormState;
|
|
250
|
-
export const useFormSubmission: (args: {
|
|
251
|
-
formId: string;
|
|
252
|
-
submissionId: string;
|
|
253
|
-
}) => {
|
|
254
|
-
submission: ISubmission;
|
|
255
|
-
isLoading: boolean;
|
|
256
|
-
};
|
|
257
|
-
|
|
258
|
-
export const useForms: (options?: UseQueryOptions) => UseQueryResult;
|
|
259
|
-
export const useForm: (options?: FormHookOptions) => UseQueryResult;
|
|
260
|
-
export const useCreateForm: (
|
|
261
|
-
options?: UseMutationOptions
|
|
262
|
-
) => CreateHookResponse;
|
|
263
|
-
export const useUpdateForm: (
|
|
264
|
-
options?: UseMutationOptions
|
|
265
|
-
) => UpdateHookResponse;
|
|
266
|
-
export const useDeleteForm: (
|
|
267
|
-
options?: UseMutationOptions
|
|
268
|
-
) => DeleteHookResponse;
|
|
File without changes
|
|
File without changes
|