@bigbinary/neeto-form-frontend 1.2.1 → 1.2.3
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/dist/index.cjs.js +276 -97
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.js +266 -87
- package/dist/index.js.map +1 -1
- package/package.json +2 -1
package/dist/index.js
CHANGED
|
@@ -1,17 +1,16 @@
|
|
|
1
1
|
import * as React$2 from 'react';
|
|
2
2
|
import React__default, { useLayoutEffect, useEffect, useMemo as useMemo$1, useContext, useReducer, useRef, useState, memo, forwardRef, Fragment } from 'react';
|
|
3
3
|
import { useField, useFormikContext, FieldArray, Form as Form$1, Formik, Field, FastField } from 'formik';
|
|
4
|
-
import {
|
|
4
|
+
import { curryN, isNil, complement, curry, either, isEmpty, assoc, prop, path, reject, omit, insert, compose as compose$1, trim, values as values$1, equals, not, pluck, times } from 'ramda';
|
|
5
5
|
import PageLoader from 'neetomolecules/PageLoader';
|
|
6
6
|
import { Toastr, Typography, Dropdown as Dropdown$2, Tooltip, Button as Button$1, Label, Alert, MultiEmailInput, DatePicker, Radio, Checkbox as Checkbox$2, Select, Textarea as Textarea$1, Input as Input$2, Spinner as Spinner$2 } from '@bigbinary/neetoui';
|
|
7
|
-
import { assoc, prop, isEmpty, path, reject, omit, insert, compose as compose$1, trim, either, isNil, values as values$1, equals, not, pluck, times } from 'ramda';
|
|
8
7
|
import ReactDOM, { unstable_batchedUpdates as unstable_batchedUpdates$1 } from 'react-dom';
|
|
9
8
|
import i18next, { t as t$1 } from 'i18next';
|
|
10
9
|
import { Input, Email as Email$2, Phone as Phone$2, Up, Down, MenuHorizontal, Delete, Plus, NeetoInvisible, MultipleChoice as MultipleChoice$2, ListDot, Dropdown as Dropdown$3, Rating as Rating$4, Smiley, Checkbox as Checkbox$1, Calendar, Check, Close } from '@bigbinary/neeto-icons';
|
|
11
10
|
import axios from 'axios';
|
|
12
11
|
import { Input as Input$1, Textarea, Checkbox, ActionBlock } from '@bigbinary/neetoui/formik';
|
|
13
12
|
import { useTranslation, Trans } from 'react-i18next';
|
|
14
|
-
import { withImmutableActions, useHotKeys } from '@bigbinary/neeto-commons-frontend/react-utils';
|
|
13
|
+
import { withImmutableActions, useDebounce, useHotKeys } from '@bigbinary/neeto-commons-frontend/react-utils';
|
|
15
14
|
import { create as create$1 } from 'zustand';
|
|
16
15
|
import classnames from 'classnames';
|
|
17
16
|
import { Editor as Editor$1, isEditorEmpty, EditorContent } from '@bigbinary/neeto-editor';
|
|
@@ -40,22 +39,22 @@ function _extends$8() {
|
|
|
40
39
|
return _extends$8.apply(this, arguments);
|
|
41
40
|
}
|
|
42
41
|
|
|
43
|
-
function _typeof$
|
|
42
|
+
function _typeof$7(obj) {
|
|
44
43
|
"@babel/helpers - typeof";
|
|
45
44
|
|
|
46
|
-
return _typeof$
|
|
45
|
+
return _typeof$7 = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) {
|
|
47
46
|
return typeof obj;
|
|
48
47
|
} : function (obj) {
|
|
49
48
|
return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
|
|
50
|
-
}, _typeof$
|
|
49
|
+
}, _typeof$7(obj);
|
|
51
50
|
}
|
|
52
51
|
|
|
53
52
|
function _toPrimitive$1(input, hint) {
|
|
54
|
-
if (_typeof$
|
|
53
|
+
if (_typeof$7(input) !== "object" || input === null) return input;
|
|
55
54
|
var prim = input[Symbol.toPrimitive];
|
|
56
55
|
if (prim !== undefined) {
|
|
57
56
|
var res = prim.call(input, hint || "default");
|
|
58
|
-
if (_typeof$
|
|
57
|
+
if (_typeof$7(res) !== "object") return res;
|
|
59
58
|
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
60
59
|
}
|
|
61
60
|
return (hint === "string" ? String : Number)(input);
|
|
@@ -63,7 +62,7 @@ function _toPrimitive$1(input, hint) {
|
|
|
63
62
|
|
|
64
63
|
function _toPropertyKey$1(arg) {
|
|
65
64
|
var key = _toPrimitive$1(arg, "string");
|
|
66
|
-
return _typeof$
|
|
65
|
+
return _typeof$7(key) === "symbol" ? key : String(key);
|
|
67
66
|
}
|
|
68
67
|
|
|
69
68
|
function _defineProperty$7(obj, key, value) {
|
|
@@ -208,6 +207,131 @@ var QUERY_KEYS = (cov_4tvsihi60().s[4]++, {
|
|
|
208
207
|
});
|
|
209
208
|
var DEFAULT_STALE_TIME = (cov_4tvsihi60().s[5]++, 3200000); // 1 hour
|
|
210
209
|
|
|
210
|
+
function _arrayWithHoles$5(arr) {
|
|
211
|
+
if (Array.isArray(arr)) return arr;
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
function _iterableToArrayLimit$5(arr, i) {
|
|
215
|
+
var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"];
|
|
216
|
+
if (null != _i) {
|
|
217
|
+
var _s,
|
|
218
|
+
_e,
|
|
219
|
+
_x,
|
|
220
|
+
_r,
|
|
221
|
+
_arr = [],
|
|
222
|
+
_n = !0,
|
|
223
|
+
_d = !1;
|
|
224
|
+
try {
|
|
225
|
+
if (_x = (_i = _i.call(arr)).next, 0 === i) {
|
|
226
|
+
if (Object(_i) !== _i) return;
|
|
227
|
+
_n = !1;
|
|
228
|
+
} else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0);
|
|
229
|
+
} catch (err) {
|
|
230
|
+
_d = !0, _e = err;
|
|
231
|
+
} finally {
|
|
232
|
+
try {
|
|
233
|
+
if (!_n && null != _i["return"] && (_r = _i["return"](), Object(_r) !== _r)) return;
|
|
234
|
+
} finally {
|
|
235
|
+
if (_d) throw _e;
|
|
236
|
+
}
|
|
237
|
+
}
|
|
238
|
+
return _arr;
|
|
239
|
+
}
|
|
240
|
+
}
|
|
241
|
+
|
|
242
|
+
function _arrayLikeToArray$h(arr, len) {
|
|
243
|
+
if (len == null || len > arr.length) len = arr.length;
|
|
244
|
+
for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];
|
|
245
|
+
return arr2;
|
|
246
|
+
}
|
|
247
|
+
|
|
248
|
+
function _unsupportedIterableToArray$h(o, minLen) {
|
|
249
|
+
if (!o) return;
|
|
250
|
+
if (typeof o === "string") return _arrayLikeToArray$h(o, minLen);
|
|
251
|
+
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
252
|
+
if (n === "Object" && o.constructor) n = o.constructor.name;
|
|
253
|
+
if (n === "Map" || n === "Set") return Array.from(o);
|
|
254
|
+
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray$h(o, minLen);
|
|
255
|
+
}
|
|
256
|
+
|
|
257
|
+
function _nonIterableRest$5() {
|
|
258
|
+
throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
259
|
+
}
|
|
260
|
+
|
|
261
|
+
function _slicedToArray$5(arr, i) {
|
|
262
|
+
return _arrayWithHoles$5(arr) || _iterableToArrayLimit$5(arr, i) || _unsupportedIterableToArray$h(arr, i) || _nonIterableRest$5();
|
|
263
|
+
}
|
|
264
|
+
|
|
265
|
+
function _typeof$6(obj) {
|
|
266
|
+
"@babel/helpers - typeof";
|
|
267
|
+
|
|
268
|
+
return _typeof$6 = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) {
|
|
269
|
+
return typeof obj;
|
|
270
|
+
} : function (obj) {
|
|
271
|
+
return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
|
|
272
|
+
}, _typeof$6(obj);
|
|
273
|
+
}
|
|
274
|
+
|
|
275
|
+
/**
|
|
276
|
+
* @template {Function} T
|
|
277
|
+
* @param {T} func
|
|
278
|
+
* @returns {T}
|
|
279
|
+
*/
|
|
280
|
+
var nullSafe = function nullSafe(func) {
|
|
281
|
+
return (
|
|
282
|
+
// @ts-ignore
|
|
283
|
+
curryN(func.length, function () {
|
|
284
|
+
var _ref;
|
|
285
|
+
var dataArg = (_ref = func.length - 1, _ref < 0 || arguments.length <= _ref ? undefined : arguments[_ref]);
|
|
286
|
+
return isNil(dataArg) ? dataArg : func.apply(void 0, arguments);
|
|
287
|
+
})
|
|
288
|
+
);
|
|
289
|
+
};
|
|
290
|
+
var noop$4 = function noop() {};
|
|
291
|
+
var isNotPresent = /*#__PURE__*/either(isNil, isEmpty);
|
|
292
|
+
var isPresent = /*#__PURE__*/complement(isNotPresent);
|
|
293
|
+
|
|
294
|
+
var matchesImpl = function matchesImpl(pattern, object) {
|
|
295
|
+
var __parent = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : object;
|
|
296
|
+
if (object === pattern) return true;
|
|
297
|
+
if (typeof pattern === "function" && pattern(object, __parent)) return true;
|
|
298
|
+
if (isNil(pattern) || isNil(object)) return false;
|
|
299
|
+
if (_typeof$6(pattern) !== "object") return false;
|
|
300
|
+
return Object.entries(pattern).every(function (_ref) {
|
|
301
|
+
var _ref2 = _slicedToArray$5(_ref, 2),
|
|
302
|
+
key = _ref2[0],
|
|
303
|
+
value = _ref2[1];
|
|
304
|
+
return matchesImpl(value, object[key], __parent);
|
|
305
|
+
});
|
|
306
|
+
};
|
|
307
|
+
var matches = /*#__PURE__*/curry(function (pattern, object) {
|
|
308
|
+
return matchesImpl(pattern, object);
|
|
309
|
+
});
|
|
310
|
+
var filterNonNull = function filterNonNull(object) {
|
|
311
|
+
return Object.fromEntries(Object.entries(object).filter(function (_ref5) {
|
|
312
|
+
var _ref6 = _slicedToArray$5(_ref5, 2),
|
|
313
|
+
v = _ref6[1];
|
|
314
|
+
return !isNil(v);
|
|
315
|
+
}).map(function (_ref7) {
|
|
316
|
+
var _ref8 = _slicedToArray$5(_ref7, 2),
|
|
317
|
+
k = _ref8[0],
|
|
318
|
+
v = _ref8[1];
|
|
319
|
+
return [k, _typeof$6(v) === "object" && !Array.isArray(v) ? filterNonNull(v) : v];
|
|
320
|
+
}));
|
|
321
|
+
};
|
|
322
|
+
nullSafe(filterNonNull);
|
|
323
|
+
var findById = /*#__PURE__*/curry(function (id, array) {
|
|
324
|
+
return array.find(function (item) {
|
|
325
|
+
return item.id === id;
|
|
326
|
+
});
|
|
327
|
+
});
|
|
328
|
+
var findBy = /*#__PURE__*/curry(function (pattern, array) {
|
|
329
|
+
return array.find(matches(pattern));
|
|
330
|
+
});
|
|
331
|
+
var removeBy = /*#__PURE__*/curry(function (pattern, array) {
|
|
332
|
+
return array.filter(complement(matches(pattern)));
|
|
333
|
+
});
|
|
334
|
+
|
|
211
335
|
function _setPrototypeOf$2(o, p) {
|
|
212
336
|
_setPrototypeOf$2 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {
|
|
213
337
|
o.__proto__ = p;
|
|
@@ -49976,7 +50100,7 @@ var RatingField = function RatingField(_ref) {
|
|
|
49976
50100
|
|
|
49977
50101
|
function cov_169joloac6() {
|
|
49978
50102
|
var path = "/home/runner/work/neeto-form-frontend/neeto-form-frontend/src/components/ExternalForm/Fields/RichTextEditor.jsx";
|
|
49979
|
-
var hash = "
|
|
50103
|
+
var hash = "606c74303adb3d540387836761d6cccb9f3cc43f";
|
|
49980
50104
|
var global = new Function("return this")();
|
|
49981
50105
|
var gcv = "__coverage__";
|
|
49982
50106
|
var coverageData = {
|
|
@@ -49984,61 +50108,81 @@ function cov_169joloac6() {
|
|
|
49984
50108
|
statementMap: {
|
|
49985
50109
|
"0": {
|
|
49986
50110
|
start: {
|
|
49987
|
-
line:
|
|
50111
|
+
line: 10,
|
|
49988
50112
|
column: 23
|
|
49989
50113
|
},
|
|
49990
50114
|
end: {
|
|
49991
|
-
line:
|
|
50115
|
+
line: 54,
|
|
49992
50116
|
column: 1
|
|
49993
50117
|
}
|
|
49994
50118
|
},
|
|
49995
50119
|
"1": {
|
|
49996
50120
|
start: {
|
|
49997
|
-
line:
|
|
50121
|
+
line: 11,
|
|
49998
50122
|
column: 69
|
|
49999
50123
|
},
|
|
50000
50124
|
end: {
|
|
50001
|
-
line:
|
|
50125
|
+
line: 11,
|
|
50002
50126
|
column: 77
|
|
50003
50127
|
}
|
|
50004
50128
|
},
|
|
50005
50129
|
"2": {
|
|
50006
50130
|
start: {
|
|
50007
|
-
line:
|
|
50131
|
+
line: 13,
|
|
50132
|
+
column: 31
|
|
50133
|
+
},
|
|
50134
|
+
end: {
|
|
50135
|
+
line: 13,
|
|
50136
|
+
column: 60
|
|
50137
|
+
}
|
|
50138
|
+
},
|
|
50139
|
+
"3": {
|
|
50140
|
+
start: {
|
|
50141
|
+
line: 15,
|
|
50008
50142
|
column: 2
|
|
50009
50143
|
},
|
|
50010
50144
|
end: {
|
|
50011
|
-
line:
|
|
50145
|
+
line: 53,
|
|
50012
50146
|
column: 4
|
|
50013
50147
|
}
|
|
50014
50148
|
},
|
|
50015
|
-
"
|
|
50149
|
+
"4": {
|
|
50016
50150
|
start: {
|
|
50017
|
-
line:
|
|
50151
|
+
line: 29,
|
|
50018
50152
|
column: 10
|
|
50019
50153
|
},
|
|
50020
50154
|
end: {
|
|
50021
|
-
line:
|
|
50155
|
+
line: 29,
|
|
50156
|
+
column: 75
|
|
50157
|
+
}
|
|
50158
|
+
},
|
|
50159
|
+
"5": {
|
|
50160
|
+
start: {
|
|
50161
|
+
line: 33,
|
|
50162
|
+
column: 10
|
|
50163
|
+
},
|
|
50164
|
+
end: {
|
|
50165
|
+
line: 49,
|
|
50022
50166
|
column: 12
|
|
50023
50167
|
}
|
|
50024
50168
|
},
|
|
50025
|
-
"
|
|
50169
|
+
"6": {
|
|
50026
50170
|
start: {
|
|
50027
|
-
line:
|
|
50171
|
+
line: 46,
|
|
50028
50172
|
column: 26
|
|
50029
50173
|
},
|
|
50030
50174
|
end: {
|
|
50031
|
-
line:
|
|
50175
|
+
line: 46,
|
|
50032
50176
|
column: 58
|
|
50033
50177
|
}
|
|
50034
50178
|
},
|
|
50035
|
-
"
|
|
50179
|
+
"7": {
|
|
50036
50180
|
start: {
|
|
50037
|
-
line:
|
|
50181
|
+
line: 47,
|
|
50038
50182
|
column: 31
|
|
50039
50183
|
},
|
|
50040
50184
|
end: {
|
|
50041
|
-
line:
|
|
50185
|
+
line: 47,
|
|
50042
50186
|
column: 62
|
|
50043
50187
|
}
|
|
50044
50188
|
}
|
|
@@ -50048,222 +50192,246 @@ function cov_169joloac6() {
|
|
|
50048
50192
|
name: "(anonymous_0)",
|
|
50049
50193
|
decl: {
|
|
50050
50194
|
start: {
|
|
50051
|
-
line:
|
|
50195
|
+
line: 10,
|
|
50052
50196
|
column: 23
|
|
50053
50197
|
},
|
|
50054
50198
|
end: {
|
|
50055
|
-
line:
|
|
50199
|
+
line: 10,
|
|
50056
50200
|
column: 24
|
|
50057
50201
|
}
|
|
50058
50202
|
},
|
|
50059
50203
|
loc: {
|
|
50060
50204
|
start: {
|
|
50061
|
-
line:
|
|
50205
|
+
line: 10,
|
|
50062
50206
|
column: 70
|
|
50063
50207
|
},
|
|
50064
50208
|
end: {
|
|
50065
|
-
line:
|
|
50209
|
+
line: 54,
|
|
50066
50210
|
column: 1
|
|
50067
50211
|
}
|
|
50068
50212
|
},
|
|
50069
|
-
line:
|
|
50213
|
+
line: 10
|
|
50070
50214
|
},
|
|
50071
50215
|
"1": {
|
|
50072
50216
|
name: "(anonymous_1)",
|
|
50073
50217
|
decl: {
|
|
50074
50218
|
start: {
|
|
50075
|
-
line:
|
|
50219
|
+
line: 28,
|
|
50220
|
+
column: 22
|
|
50221
|
+
},
|
|
50222
|
+
end: {
|
|
50223
|
+
line: 28,
|
|
50224
|
+
column: 23
|
|
50225
|
+
}
|
|
50226
|
+
},
|
|
50227
|
+
loc: {
|
|
50228
|
+
start: {
|
|
50229
|
+
line: 29,
|
|
50230
|
+
column: 10
|
|
50231
|
+
},
|
|
50232
|
+
end: {
|
|
50233
|
+
line: 29,
|
|
50234
|
+
column: 75
|
|
50235
|
+
}
|
|
50236
|
+
},
|
|
50237
|
+
line: 29
|
|
50238
|
+
},
|
|
50239
|
+
"2": {
|
|
50240
|
+
name: "(anonymous_2)",
|
|
50241
|
+
decl: {
|
|
50242
|
+
start: {
|
|
50243
|
+
line: 32,
|
|
50076
50244
|
column: 9
|
|
50077
50245
|
},
|
|
50078
50246
|
end: {
|
|
50079
|
-
line:
|
|
50247
|
+
line: 32,
|
|
50080
50248
|
column: 10
|
|
50081
50249
|
}
|
|
50082
50250
|
},
|
|
50083
50251
|
loc: {
|
|
50084
50252
|
start: {
|
|
50085
|
-
line:
|
|
50253
|
+
line: 33,
|
|
50086
50254
|
column: 10
|
|
50087
50255
|
},
|
|
50088
50256
|
end: {
|
|
50089
|
-
line:
|
|
50257
|
+
line: 49,
|
|
50090
50258
|
column: 12
|
|
50091
50259
|
}
|
|
50092
50260
|
},
|
|
50093
|
-
line:
|
|
50261
|
+
line: 33
|
|
50094
50262
|
},
|
|
50095
|
-
"
|
|
50096
|
-
name: "(
|
|
50263
|
+
"3": {
|
|
50264
|
+
name: "(anonymous_3)",
|
|
50097
50265
|
decl: {
|
|
50098
50266
|
start: {
|
|
50099
|
-
line:
|
|
50267
|
+
line: 46,
|
|
50100
50268
|
column: 20
|
|
50101
50269
|
},
|
|
50102
50270
|
end: {
|
|
50103
|
-
line:
|
|
50271
|
+
line: 46,
|
|
50104
50272
|
column: 21
|
|
50105
50273
|
}
|
|
50106
50274
|
},
|
|
50107
50275
|
loc: {
|
|
50108
50276
|
start: {
|
|
50109
|
-
line:
|
|
50277
|
+
line: 46,
|
|
50110
50278
|
column: 26
|
|
50111
50279
|
},
|
|
50112
50280
|
end: {
|
|
50113
|
-
line:
|
|
50281
|
+
line: 46,
|
|
50114
50282
|
column: 58
|
|
50115
50283
|
}
|
|
50116
50284
|
},
|
|
50117
|
-
line:
|
|
50285
|
+
line: 46
|
|
50118
50286
|
},
|
|
50119
|
-
"
|
|
50120
|
-
name: "(
|
|
50287
|
+
"4": {
|
|
50288
|
+
name: "(anonymous_4)",
|
|
50121
50289
|
decl: {
|
|
50122
50290
|
start: {
|
|
50123
|
-
line:
|
|
50291
|
+
line: 47,
|
|
50124
50292
|
column: 22
|
|
50125
50293
|
},
|
|
50126
50294
|
end: {
|
|
50127
|
-
line:
|
|
50295
|
+
line: 47,
|
|
50128
50296
|
column: 23
|
|
50129
50297
|
}
|
|
50130
50298
|
},
|
|
50131
50299
|
loc: {
|
|
50132
50300
|
start: {
|
|
50133
|
-
line:
|
|
50301
|
+
line: 47,
|
|
50134
50302
|
column: 31
|
|
50135
50303
|
},
|
|
50136
50304
|
end: {
|
|
50137
|
-
line:
|
|
50305
|
+
line: 47,
|
|
50138
50306
|
column: 62
|
|
50139
50307
|
}
|
|
50140
50308
|
},
|
|
50141
|
-
line:
|
|
50309
|
+
line: 47
|
|
50142
50310
|
}
|
|
50143
50311
|
},
|
|
50144
50312
|
branchMap: {
|
|
50145
50313
|
"0": {
|
|
50146
50314
|
loc: {
|
|
50147
50315
|
start: {
|
|
50148
|
-
line:
|
|
50316
|
+
line: 10,
|
|
50149
50317
|
column: 47
|
|
50150
50318
|
},
|
|
50151
50319
|
end: {
|
|
50152
|
-
line:
|
|
50320
|
+
line: 10,
|
|
50153
50321
|
column: 63
|
|
50154
50322
|
}
|
|
50155
50323
|
},
|
|
50156
50324
|
type: "default-arg",
|
|
50157
50325
|
locations: [{
|
|
50158
50326
|
start: {
|
|
50159
|
-
line:
|
|
50327
|
+
line: 10,
|
|
50160
50328
|
column: 61
|
|
50161
50329
|
},
|
|
50162
50330
|
end: {
|
|
50163
|
-
line:
|
|
50331
|
+
line: 10,
|
|
50164
50332
|
column: 63
|
|
50165
50333
|
}
|
|
50166
50334
|
}],
|
|
50167
|
-
line:
|
|
50335
|
+
line: 10
|
|
50168
50336
|
},
|
|
50169
50337
|
"1": {
|
|
50170
50338
|
loc: {
|
|
50171
50339
|
start: {
|
|
50172
|
-
line:
|
|
50340
|
+
line: 18,
|
|
50173
50341
|
column: 9
|
|
50174
50342
|
},
|
|
50175
50343
|
end: {
|
|
50176
|
-
line:
|
|
50344
|
+
line: 22,
|
|
50177
50345
|
column: 9
|
|
50178
50346
|
}
|
|
50179
50347
|
},
|
|
50180
50348
|
type: "binary-expr",
|
|
50181
50349
|
locations: [{
|
|
50182
50350
|
start: {
|
|
50183
|
-
line:
|
|
50351
|
+
line: 18,
|
|
50184
50352
|
column: 9
|
|
50185
50353
|
},
|
|
50186
50354
|
end: {
|
|
50187
|
-
line:
|
|
50355
|
+
line: 18,
|
|
50188
50356
|
column: 14
|
|
50189
50357
|
}
|
|
50190
50358
|
}, {
|
|
50191
50359
|
start: {
|
|
50192
|
-
line:
|
|
50360
|
+
line: 19,
|
|
50193
50361
|
column: 10
|
|
50194
50362
|
},
|
|
50195
50363
|
end: {
|
|
50196
|
-
line:
|
|
50364
|
+
line: 21,
|
|
50197
50365
|
column: 18
|
|
50198
50366
|
}
|
|
50199
50367
|
}],
|
|
50200
|
-
line:
|
|
50368
|
+
line: 18
|
|
50201
50369
|
},
|
|
50202
50370
|
"2": {
|
|
50203
50371
|
loc: {
|
|
50204
50372
|
start: {
|
|
50205
|
-
line:
|
|
50373
|
+
line: 26,
|
|
50206
50374
|
column: 14
|
|
50207
50375
|
},
|
|
50208
50376
|
end: {
|
|
50209
|
-
line:
|
|
50377
|
+
line: 26,
|
|
50210
50378
|
column: 28
|
|
50211
50379
|
}
|
|
50212
50380
|
},
|
|
50213
50381
|
type: "binary-expr",
|
|
50214
50382
|
locations: [{
|
|
50215
50383
|
start: {
|
|
50216
|
-
line:
|
|
50384
|
+
line: 26,
|
|
50217
50385
|
column: 14
|
|
50218
50386
|
},
|
|
50219
50387
|
end: {
|
|
50220
|
-
line:
|
|
50388
|
+
line: 26,
|
|
50221
50389
|
column: 18
|
|
50222
50390
|
}
|
|
50223
50391
|
}, {
|
|
50224
50392
|
start: {
|
|
50225
|
-
line:
|
|
50393
|
+
line: 26,
|
|
50226
50394
|
column: 22
|
|
50227
50395
|
},
|
|
50228
50396
|
end: {
|
|
50229
|
-
line:
|
|
50397
|
+
line: 26,
|
|
50230
50398
|
column: 28
|
|
50231
50399
|
}
|
|
50232
50400
|
}],
|
|
50233
|
-
line:
|
|
50401
|
+
line: 26
|
|
50234
50402
|
},
|
|
50235
50403
|
"3": {
|
|
50236
50404
|
loc: {
|
|
50237
50405
|
start: {
|
|
50238
|
-
line:
|
|
50406
|
+
line: 35,
|
|
50239
50407
|
column: 19
|
|
50240
50408
|
},
|
|
50241
50409
|
end: {
|
|
50242
|
-
line:
|
|
50410
|
+
line: 35,
|
|
50243
50411
|
column: 49
|
|
50244
50412
|
}
|
|
50245
50413
|
},
|
|
50246
50414
|
type: "cond-expr",
|
|
50247
50415
|
locations: [{
|
|
50248
50416
|
start: {
|
|
50249
|
-
line:
|
|
50417
|
+
line: 35,
|
|
50250
50418
|
column: 34
|
|
50251
50419
|
},
|
|
50252
50420
|
end: {
|
|
50253
|
-
line:
|
|
50421
|
+
line: 35,
|
|
50254
50422
|
column: 44
|
|
50255
50423
|
}
|
|
50256
50424
|
}, {
|
|
50257
50425
|
start: {
|
|
50258
|
-
line:
|
|
50426
|
+
line: 35,
|
|
50259
50427
|
column: 47
|
|
50260
50428
|
},
|
|
50261
50429
|
end: {
|
|
50262
|
-
line:
|
|
50430
|
+
line: 35,
|
|
50263
50431
|
column: 49
|
|
50264
50432
|
}
|
|
50265
50433
|
}],
|
|
50266
|
-
line:
|
|
50434
|
+
line: 35
|
|
50267
50435
|
}
|
|
50268
50436
|
},
|
|
50269
50437
|
s: {
|
|
@@ -50272,13 +50440,16 @@ function cov_169joloac6() {
|
|
|
50272
50440
|
"2": 0,
|
|
50273
50441
|
"3": 0,
|
|
50274
50442
|
"4": 0,
|
|
50275
|
-
"5": 0
|
|
50443
|
+
"5": 0,
|
|
50444
|
+
"6": 0,
|
|
50445
|
+
"7": 0
|
|
50276
50446
|
},
|
|
50277
50447
|
f: {
|
|
50278
50448
|
"0": 0,
|
|
50279
50449
|
"1": 0,
|
|
50280
50450
|
"2": 0,
|
|
50281
|
-
"3": 0
|
|
50451
|
+
"3": 0,
|
|
50452
|
+
"4": 0
|
|
50282
50453
|
},
|
|
50283
50454
|
b: {
|
|
50284
50455
|
"0": [0],
|
|
@@ -50287,7 +50458,7 @@ function cov_169joloac6() {
|
|
|
50287
50458
|
"3": [0, 0]
|
|
50288
50459
|
},
|
|
50289
50460
|
_coverageSchema: "1a1c01bbd47fc00a2c39e90264f33305004495a9",
|
|
50290
|
-
hash: "
|
|
50461
|
+
hash: "606c74303adb3d540387836761d6cccb9f3cc43f"
|
|
50291
50462
|
};
|
|
50292
50463
|
var coverage = global[gcv] || (global[gcv] = {});
|
|
50293
50464
|
if (!coverage[path] || coverage[path].hash !== hash) {
|
|
@@ -50317,7 +50488,8 @@ var RichTextEditor = function RichTextEditor(_ref) {
|
|
|
50317
50488
|
isRequired = _ref2.isRequired,
|
|
50318
50489
|
nodeId = _ref2.nodeId,
|
|
50319
50490
|
placeholder = _ref2.placeholder;
|
|
50320
|
-
cov_169joloac6().s[2]
|
|
50491
|
+
var debouncedPlaceholder = (cov_169joloac6().s[2]++, useDebounce(placeholder, 300));
|
|
50492
|
+
cov_169joloac6().s[3]++;
|
|
50321
50493
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
50322
50494
|
className: "neeto-form-engine-input__wrapper"
|
|
50323
50495
|
}, /*#__PURE__*/React__default.createElement("div", {
|
|
@@ -50325,33 +50497,40 @@ var RichTextEditor = function RichTextEditor(_ref) {
|
|
|
50325
50497
|
}, (cov_169joloac6().b[1][0]++, label) && (cov_169joloac6().b[1][1]++, /*#__PURE__*/React__default.createElement("label", {
|
|
50326
50498
|
className: "neeto-form-engine-label"
|
|
50327
50499
|
}, getLabel$1(label, isRequired)))), /*#__PURE__*/React__default.createElement(FastField, {
|
|
50500
|
+
debouncedPlaceholder: debouncedPlaceholder,
|
|
50328
50501
|
name: (cov_169joloac6().b[2][0]++, name) || (cov_169joloac6().b[2][1]++, nodeId),
|
|
50329
50502
|
validate: validateFieldValue({
|
|
50330
50503
|
kind: kind,
|
|
50331
50504
|
label: label,
|
|
50332
50505
|
isRequired: isRequired
|
|
50333
|
-
})
|
|
50506
|
+
}),
|
|
50507
|
+
shouldUpdate: function shouldUpdate(nextProps, prevProps) {
|
|
50508
|
+
cov_169joloac6().f[1]++;
|
|
50509
|
+
cov_169joloac6().s[4]++;
|
|
50510
|
+
return nextProps.debouncedPlaceholder !== prevProps.debouncedPlaceholder;
|
|
50511
|
+
}
|
|
50334
50512
|
}, function (_ref3) {
|
|
50335
50513
|
var field = _ref3.field,
|
|
50336
50514
|
form = _ref3.form,
|
|
50337
50515
|
meta = _ref3.meta;
|
|
50338
|
-
cov_169joloac6().f[
|
|
50339
|
-
cov_169joloac6().s[
|
|
50516
|
+
cov_169joloac6().f[2]++;
|
|
50517
|
+
cov_169joloac6().s[5]++;
|
|
50340
50518
|
return /*#__PURE__*/React__default.createElement(Editor$1, _extends$8({
|
|
50341
50519
|
className: "neeto-form-engine-rich-text-input",
|
|
50342
50520
|
error: meta.touched ? (cov_169joloac6().b[3][0]++, meta.error) : (cov_169joloac6().b[3][1]++, ""),
|
|
50343
50521
|
initialValue: field.value,
|
|
50344
|
-
|
|
50522
|
+
key: debouncedPlaceholder,
|
|
50523
|
+
placeholder: debouncedPlaceholder,
|
|
50345
50524
|
ref: editorRef,
|
|
50346
50525
|
addons: ["attachments", "block-quote", "code-block", "image-upload"],
|
|
50347
50526
|
onBlur: function onBlur() {
|
|
50348
|
-
cov_169joloac6().f[
|
|
50349
|
-
cov_169joloac6().s[
|
|
50527
|
+
cov_169joloac6().f[3]++;
|
|
50528
|
+
cov_169joloac6().s[6]++;
|
|
50350
50529
|
return form.setFieldTouched(name, true);
|
|
50351
50530
|
},
|
|
50352
50531
|
onChange: function onChange(value) {
|
|
50353
|
-
cov_169joloac6().f[
|
|
50354
|
-
cov_169joloac6().s[
|
|
50532
|
+
cov_169joloac6().f[4]++;
|
|
50533
|
+
cov_169joloac6().s[7]++;
|
|
50355
50534
|
return form.setFieldValue(name, value);
|
|
50356
50535
|
}
|
|
50357
50536
|
}, editorProps));
|