@bigbinary/neeto-filters-frontend 3.0.4 → 3.0.6
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 +220 -43
- package/{src → app/javascript/src}/translations/en.json +4 -2
- package/dist/index.cjs.js +434 -2029
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.js +367 -1958
- package/dist/index.js.map +1 -1
- package/package.json +131 -95
- package/types.d.ts +2 -0
- /package/{src → app/javascript/src}/translations/index.js +0 -0
package/dist/index.cjs.js
CHANGED
|
@@ -4,22 +4,19 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
var React = require('react');
|
|
6
6
|
var classnames = require('classnames');
|
|
7
|
-
var
|
|
7
|
+
var i18next = require('i18next');
|
|
8
|
+
var neetoCist = require('@bigbinary/neeto-cist');
|
|
8
9
|
var reactUtils = require('@bigbinary/neeto-commons-frontend/react-utils');
|
|
9
10
|
var utils = require('@bigbinary/neeto-commons-frontend/utils');
|
|
10
11
|
var neetoui = require('@bigbinary/neetoui');
|
|
12
|
+
var ramda = require('ramda');
|
|
11
13
|
var reactI18next = require('react-i18next');
|
|
12
14
|
var reactRouterDom = require('react-router-dom');
|
|
13
15
|
var neetoIcons = require('@bigbinary/neeto-icons');
|
|
14
|
-
var i18next = require('i18next');
|
|
15
|
-
var dayjs = require('dayjs');
|
|
16
|
-
var yup = require('yup');
|
|
17
|
-
var timezone = require('dayjs/plugin/timezone');
|
|
18
|
-
var utc = require('dayjs/plugin/utc');
|
|
19
|
-
var weekday = require('dayjs/plugin/weekday');
|
|
20
16
|
var formik = require('@bigbinary/neetoui/formik');
|
|
21
17
|
var reactQuery = require('react-query');
|
|
22
18
|
var axios = require('axios');
|
|
19
|
+
var yup = require('yup');
|
|
23
20
|
var Search = require('@bigbinary/neeto-molecules/Search');
|
|
24
21
|
var ReactDOM = require('react-dom');
|
|
25
22
|
var MenuBar = require('@bigbinary/neeto-molecules/MenuBar');
|
|
@@ -48,37 +45,33 @@ function _interopNamespace(e) {
|
|
|
48
45
|
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
49
46
|
var classnames__default = /*#__PURE__*/_interopDefaultLegacy(classnames);
|
|
50
47
|
var i18next__default = /*#__PURE__*/_interopDefaultLegacy(i18next);
|
|
51
|
-
var dayjs__default = /*#__PURE__*/_interopDefaultLegacy(dayjs);
|
|
52
|
-
var yup__namespace = /*#__PURE__*/_interopNamespace(yup);
|
|
53
|
-
var timezone__default = /*#__PURE__*/_interopDefaultLegacy(timezone);
|
|
54
|
-
var utc__default = /*#__PURE__*/_interopDefaultLegacy(utc);
|
|
55
|
-
var weekday__default = /*#__PURE__*/_interopDefaultLegacy(weekday);
|
|
56
48
|
var axios__default = /*#__PURE__*/_interopDefaultLegacy(axios);
|
|
49
|
+
var yup__namespace = /*#__PURE__*/_interopNamespace(yup);
|
|
57
50
|
var Search__default = /*#__PURE__*/_interopDefaultLegacy(Search);
|
|
58
51
|
var ReactDOM__default = /*#__PURE__*/_interopDefaultLegacy(ReactDOM);
|
|
59
52
|
var MenuBar__default = /*#__PURE__*/_interopDefaultLegacy(MenuBar);
|
|
60
53
|
|
|
61
|
-
function _arrayLikeToArray
|
|
54
|
+
function _arrayLikeToArray(arr, len) {
|
|
62
55
|
if (len == null || len > arr.length) len = arr.length;
|
|
63
56
|
for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];
|
|
64
57
|
return arr2;
|
|
65
58
|
}
|
|
66
59
|
|
|
67
60
|
function _arrayWithoutHoles(arr) {
|
|
68
|
-
if (Array.isArray(arr)) return _arrayLikeToArray
|
|
61
|
+
if (Array.isArray(arr)) return _arrayLikeToArray(arr);
|
|
69
62
|
}
|
|
70
63
|
|
|
71
64
|
function _iterableToArray(iter) {
|
|
72
65
|
if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter);
|
|
73
66
|
}
|
|
74
67
|
|
|
75
|
-
function _unsupportedIterableToArray
|
|
68
|
+
function _unsupportedIterableToArray(o, minLen) {
|
|
76
69
|
if (!o) return;
|
|
77
|
-
if (typeof o === "string") return _arrayLikeToArray
|
|
70
|
+
if (typeof o === "string") return _arrayLikeToArray(o, minLen);
|
|
78
71
|
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
79
72
|
if (n === "Object" && o.constructor) n = o.constructor.name;
|
|
80
73
|
if (n === "Map" || n === "Set") return Array.from(o);
|
|
81
|
-
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray
|
|
74
|
+
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);
|
|
82
75
|
}
|
|
83
76
|
|
|
84
77
|
function _nonIterableSpread() {
|
|
@@ -86,25 +79,25 @@ function _nonIterableSpread() {
|
|
|
86
79
|
}
|
|
87
80
|
|
|
88
81
|
function _toConsumableArray(arr) {
|
|
89
|
-
return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray
|
|
82
|
+
return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread();
|
|
90
83
|
}
|
|
91
84
|
|
|
92
|
-
function _typeof
|
|
85
|
+
function _typeof(obj) {
|
|
93
86
|
"@babel/helpers - typeof";
|
|
94
87
|
|
|
95
|
-
return _typeof
|
|
88
|
+
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) {
|
|
96
89
|
return typeof obj;
|
|
97
90
|
} : function (obj) {
|
|
98
91
|
return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
|
|
99
|
-
}, _typeof
|
|
92
|
+
}, _typeof(obj);
|
|
100
93
|
}
|
|
101
94
|
|
|
102
95
|
function _toPrimitive(input, hint) {
|
|
103
|
-
if (_typeof
|
|
96
|
+
if (_typeof(input) !== "object" || input === null) return input;
|
|
104
97
|
var prim = input[Symbol.toPrimitive];
|
|
105
98
|
if (prim !== undefined) {
|
|
106
99
|
var res = prim.call(input, hint || "default");
|
|
107
|
-
if (_typeof
|
|
100
|
+
if (_typeof(res) !== "object") return res;
|
|
108
101
|
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
109
102
|
}
|
|
110
103
|
return (hint === "string" ? String : Number)(input);
|
|
@@ -112,7 +105,7 @@ function _toPrimitive(input, hint) {
|
|
|
112
105
|
|
|
113
106
|
function _toPropertyKey(arg) {
|
|
114
107
|
var key = _toPrimitive(arg, "string");
|
|
115
|
-
return _typeof
|
|
108
|
+
return _typeof(key) === "symbol" ? key : String(key);
|
|
116
109
|
}
|
|
117
110
|
|
|
118
111
|
function _defineProperty(obj, key, value) {
|
|
@@ -130,153 +123,6 @@ function _defineProperty(obj, key, value) {
|
|
|
130
123
|
return obj;
|
|
131
124
|
}
|
|
132
125
|
|
|
133
|
-
function _arrayWithHoles$1(arr) {
|
|
134
|
-
if (Array.isArray(arr)) return arr;
|
|
135
|
-
}
|
|
136
|
-
|
|
137
|
-
function _iterableToArrayLimit$1(arr, i) {
|
|
138
|
-
var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"];
|
|
139
|
-
if (null != _i) {
|
|
140
|
-
var _s,
|
|
141
|
-
_e,
|
|
142
|
-
_x,
|
|
143
|
-
_r,
|
|
144
|
-
_arr = [],
|
|
145
|
-
_n = !0,
|
|
146
|
-
_d = !1;
|
|
147
|
-
try {
|
|
148
|
-
if (_x = (_i = _i.call(arr)).next, 0 === i) {
|
|
149
|
-
if (Object(_i) !== _i) return;
|
|
150
|
-
_n = !1;
|
|
151
|
-
} else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0);
|
|
152
|
-
} catch (err) {
|
|
153
|
-
_d = !0, _e = err;
|
|
154
|
-
} finally {
|
|
155
|
-
try {
|
|
156
|
-
if (!_n && null != _i["return"] && (_r = _i["return"](), Object(_r) !== _r)) return;
|
|
157
|
-
} finally {
|
|
158
|
-
if (_d) throw _e;
|
|
159
|
-
}
|
|
160
|
-
}
|
|
161
|
-
return _arr;
|
|
162
|
-
}
|
|
163
|
-
}
|
|
164
|
-
|
|
165
|
-
function _arrayLikeToArray(arr, len) {
|
|
166
|
-
if (len == null || len > arr.length) len = arr.length;
|
|
167
|
-
for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];
|
|
168
|
-
return arr2;
|
|
169
|
-
}
|
|
170
|
-
|
|
171
|
-
function _unsupportedIterableToArray(o, minLen) {
|
|
172
|
-
if (!o) return;
|
|
173
|
-
if (typeof o === "string") return _arrayLikeToArray(o, minLen);
|
|
174
|
-
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
175
|
-
if (n === "Object" && o.constructor) n = o.constructor.name;
|
|
176
|
-
if (n === "Map" || n === "Set") return Array.from(o);
|
|
177
|
-
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);
|
|
178
|
-
}
|
|
179
|
-
|
|
180
|
-
function _nonIterableRest$1() {
|
|
181
|
-
throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
182
|
-
}
|
|
183
|
-
|
|
184
|
-
function _slicedToArray$1(arr, i) {
|
|
185
|
-
return _arrayWithHoles$1(arr) || _iterableToArrayLimit$1(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest$1();
|
|
186
|
-
}
|
|
187
|
-
|
|
188
|
-
function _typeof(obj) {
|
|
189
|
-
"@babel/helpers - typeof";
|
|
190
|
-
|
|
191
|
-
return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) {
|
|
192
|
-
return typeof obj;
|
|
193
|
-
} : function (obj) {
|
|
194
|
-
return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
|
|
195
|
-
}, _typeof(obj);
|
|
196
|
-
}
|
|
197
|
-
|
|
198
|
-
/**
|
|
199
|
-
* @template {Function} T
|
|
200
|
-
* @param {T} func
|
|
201
|
-
* @returns {T}
|
|
202
|
-
*/
|
|
203
|
-
var nullSafe = function nullSafe(func) {
|
|
204
|
-
return (
|
|
205
|
-
// @ts-ignore
|
|
206
|
-
ramda.curryN(func.length, function () {
|
|
207
|
-
var _ref;
|
|
208
|
-
var dataArg = (_ref = func.length - 1, _ref < 0 || arguments.length <= _ref ? undefined : arguments[_ref]);
|
|
209
|
-
return ramda.isNil(dataArg) ? dataArg : func.apply(void 0, arguments);
|
|
210
|
-
})
|
|
211
|
-
);
|
|
212
|
-
};
|
|
213
|
-
var noop$1 = function noop() {};
|
|
214
|
-
var toLabelAndValue = function toLabelAndValue(string) {
|
|
215
|
-
return {
|
|
216
|
-
label: string,
|
|
217
|
-
value: string
|
|
218
|
-
};
|
|
219
|
-
};
|
|
220
|
-
var isNotEmpty = /*#__PURE__*/ramda.complement(ramda.isEmpty);
|
|
221
|
-
var isNotPresent = /*#__PURE__*/ramda.either(ramda.isNil, ramda.isEmpty);
|
|
222
|
-
var isPresent = /*#__PURE__*/ramda.complement(isNotPresent);
|
|
223
|
-
|
|
224
|
-
var humanize = function humanize(string) {
|
|
225
|
-
string = string.replace(/[_-]+/g, " ").replace(/\s{2,}/g, " ").replace(/([a-z\d])([A-Z])/g, "$1" + " " + "$2").replace(/([A-Z]+)([A-Z][a-z\d]+)/g, "$1" + " " + "$2").toLowerCase().trim();
|
|
226
|
-
string = string.charAt(0).toUpperCase() + string.slice(1);
|
|
227
|
-
return string;
|
|
228
|
-
};
|
|
229
|
-
var capitalize = function capitalize(string) {
|
|
230
|
-
return string.charAt(0).toUpperCase() + string.slice(1);
|
|
231
|
-
};
|
|
232
|
-
|
|
233
|
-
var matchesImpl = function matchesImpl(pattern, object) {
|
|
234
|
-
var __parent = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : object;
|
|
235
|
-
if (object === pattern) return true;
|
|
236
|
-
if (typeof pattern === "function" && pattern(object, __parent)) return true;
|
|
237
|
-
if (ramda.isNil(pattern) || ramda.isNil(object)) return false;
|
|
238
|
-
if (_typeof(pattern) !== "object") return false;
|
|
239
|
-
return Object.entries(pattern).every(function (_ref) {
|
|
240
|
-
var _ref2 = _slicedToArray$1(_ref, 2),
|
|
241
|
-
key = _ref2[0],
|
|
242
|
-
value = _ref2[1];
|
|
243
|
-
return matchesImpl(value, object[key], __parent);
|
|
244
|
-
});
|
|
245
|
-
};
|
|
246
|
-
var matches = /*#__PURE__*/ramda.curry(function (pattern, object) {
|
|
247
|
-
return matchesImpl(pattern, object);
|
|
248
|
-
});
|
|
249
|
-
var filterNonNull = function filterNonNull(object) {
|
|
250
|
-
return Object.fromEntries(Object.entries(object).filter(function (_ref5) {
|
|
251
|
-
var _ref6 = _slicedToArray$1(_ref5, 2),
|
|
252
|
-
v = _ref6[1];
|
|
253
|
-
return !ramda.isNil(v);
|
|
254
|
-
}).map(function (_ref7) {
|
|
255
|
-
var _ref8 = _slicedToArray$1(_ref7, 2),
|
|
256
|
-
k = _ref8[0],
|
|
257
|
-
v = _ref8[1];
|
|
258
|
-
return [k, _typeof(v) === "object" && !Array.isArray(v) ? filterNonNull(v) : v];
|
|
259
|
-
}));
|
|
260
|
-
};
|
|
261
|
-
nullSafe(filterNonNull);
|
|
262
|
-
var findBy = /*#__PURE__*/ramda.curry(function (pattern, array) {
|
|
263
|
-
return array.find(matches(pattern));
|
|
264
|
-
});
|
|
265
|
-
var removeBy = /*#__PURE__*/ramda.curry(function (pattern, array) {
|
|
266
|
-
return array.filter(ramda.complement(matches(pattern)));
|
|
267
|
-
});
|
|
268
|
-
var replaceBy = /*#__PURE__*/ramda.curry(function (pattern, newItem, array) {
|
|
269
|
-
return array.map(function (item) {
|
|
270
|
-
return matches(pattern, item) ? newItem : item;
|
|
271
|
-
});
|
|
272
|
-
});
|
|
273
|
-
var existsBy = /*#__PURE__*/ramda.curry(function (pattern, array) {
|
|
274
|
-
return array.some(matches(pattern));
|
|
275
|
-
});
|
|
276
|
-
var filterBy = /*#__PURE__*/ramda.curry(function (pattern, array) {
|
|
277
|
-
return array.filter(matches(pattern));
|
|
278
|
-
});
|
|
279
|
-
|
|
280
126
|
var SHORTCUTS = {
|
|
281
127
|
closePane: {
|
|
282
128
|
sequence: "escape",
|
|
@@ -292,9 +138,6 @@ var SHORTCUTS = {
|
|
|
292
138
|
}
|
|
293
139
|
};
|
|
294
140
|
|
|
295
|
-
var SEGMENT_VALIDATION_SCHEMA = yup__namespace.object({
|
|
296
|
-
name: yup__namespace.string().trim().required()
|
|
297
|
-
});
|
|
298
141
|
var SEGMENTS_BASE_URL = "/neeto_filters/segments";
|
|
299
142
|
var DATE_OPTIONS = [{
|
|
300
143
|
label: "Today",
|
|
@@ -375,6 +218,23 @@ var DATE_RULES = {
|
|
|
375
218
|
"all-time": "before"
|
|
376
219
|
};
|
|
377
220
|
|
|
221
|
+
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
|
222
|
+
|
|
223
|
+
function getDefaultExportFromCjs (x) {
|
|
224
|
+
return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
var dayjs_min = {exports: {}};
|
|
228
|
+
|
|
229
|
+
dayjs_min.exports;
|
|
230
|
+
|
|
231
|
+
(function (module, exports) {
|
|
232
|
+
!function(t,e){module.exports=e();}(commonjsGlobal,(function(){var t=1e3,e=6e4,n=36e5,r="millisecond",i="second",s="minute",u="hour",a="day",o="week",c="month",f="quarter",h="year",d="date",l="Invalid Date",$=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,y=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,M={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(t){var e=["th","st","nd","rd"],n=t%100;return "["+t+(e[(n-20)%10]||e[n]||e[0])+"]"}},m=function(t,e,n){var r=String(t);return !r||r.length>=e?t:""+Array(e+1-r.length).join(n)+t},v={s:m,z:function(t){var e=-t.utcOffset(),n=Math.abs(e),r=Math.floor(n/60),i=n%60;return (e<=0?"+":"-")+m(r,2,"0")+":"+m(i,2,"0")},m:function t(e,n){if(e.date()<n.date())return -t(n,e);var r=12*(n.year()-e.year())+(n.month()-e.month()),i=e.clone().add(r,c),s=n-i<0,u=e.clone().add(r+(s?-1:1),c);return +(-(r+(n-i)/(s?i-u:u-i))||0)},a:function(t){return t<0?Math.ceil(t)||0:Math.floor(t)},p:function(t){return {M:c,y:h,w:o,d:a,D:d,h:u,m:s,s:i,ms:r,Q:f}[t]||String(t||"").toLowerCase().replace(/s$/,"")},u:function(t){return void 0===t}},g="en",D={};D[g]=M;var p=function(t){return t instanceof b},S=function t(e,n,r){var i;if(!e)return g;if("string"==typeof e){var s=e.toLowerCase();D[s]&&(i=s),n&&(D[s]=n,i=s);var u=e.split("-");if(!i&&u.length>1)return t(u[0])}else {var a=e.name;D[a]=e,i=a;}return !r&&i&&(g=i),i||!r&&g},w=function(t,e){if(p(t))return t.clone();var n="object"==typeof e?e:{};return n.date=t,n.args=arguments,new b(n)},O=v;O.l=S,O.i=p,O.w=function(t,e){return w(t,{locale:e.$L,utc:e.$u,x:e.$x,$offset:e.$offset})};var b=function(){function M(t){this.$L=S(t.locale,null,!0),this.parse(t);}var m=M.prototype;return m.parse=function(t){this.$d=function(t){var e=t.date,n=t.utc;if(null===e)return new Date(NaN);if(O.u(e))return new Date;if(e instanceof Date)return new Date(e);if("string"==typeof e&&!/Z$/i.test(e)){var r=e.match($);if(r){var i=r[2]-1||0,s=(r[7]||"0").substring(0,3);return n?new Date(Date.UTC(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,s)):new Date(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,s)}}return new Date(e)}(t),this.$x=t.x||{},this.init();},m.init=function(){var t=this.$d;this.$y=t.getFullYear(),this.$M=t.getMonth(),this.$D=t.getDate(),this.$W=t.getDay(),this.$H=t.getHours(),this.$m=t.getMinutes(),this.$s=t.getSeconds(),this.$ms=t.getMilliseconds();},m.$utils=function(){return O},m.isValid=function(){return !(this.$d.toString()===l)},m.isSame=function(t,e){var n=w(t);return this.startOf(e)<=n&&n<=this.endOf(e)},m.isAfter=function(t,e){return w(t)<this.startOf(e)},m.isBefore=function(t,e){return this.endOf(e)<w(t)},m.$g=function(t,e,n){return O.u(t)?this[e]:this.set(n,t)},m.unix=function(){return Math.floor(this.valueOf()/1e3)},m.valueOf=function(){return this.$d.getTime()},m.startOf=function(t,e){var n=this,r=!!O.u(e)||e,f=O.p(t),l=function(t,e){var i=O.w(n.$u?Date.UTC(n.$y,e,t):new Date(n.$y,e,t),n);return r?i:i.endOf(a)},$=function(t,e){return O.w(n.toDate()[t].apply(n.toDate("s"),(r?[0,0,0,0]:[23,59,59,999]).slice(e)),n)},y=this.$W,M=this.$M,m=this.$D,v="set"+(this.$u?"UTC":"");switch(f){case h:return r?l(1,0):l(31,11);case c:return r?l(1,M):l(0,M+1);case o:var g=this.$locale().weekStart||0,D=(y<g?y+7:y)-g;return l(r?m-D:m+(6-D),M);case a:case d:return $(v+"Hours",0);case u:return $(v+"Minutes",1);case s:return $(v+"Seconds",2);case i:return $(v+"Milliseconds",3);default:return this.clone()}},m.endOf=function(t){return this.startOf(t,!1)},m.$set=function(t,e){var n,o=O.p(t),f="set"+(this.$u?"UTC":""),l=(n={},n[a]=f+"Date",n[d]=f+"Date",n[c]=f+"Month",n[h]=f+"FullYear",n[u]=f+"Hours",n[s]=f+"Minutes",n[i]=f+"Seconds",n[r]=f+"Milliseconds",n)[o],$=o===a?this.$D+(e-this.$W):e;if(o===c||o===h){var y=this.clone().set(d,1);y.$d[l]($),y.init(),this.$d=y.set(d,Math.min(this.$D,y.daysInMonth())).$d;}else l&&this.$d[l]($);return this.init(),this},m.set=function(t,e){return this.clone().$set(t,e)},m.get=function(t){return this[O.p(t)]()},m.add=function(r,f){var d,l=this;r=Number(r);var $=O.p(f),y=function(t){var e=w(l);return O.w(e.date(e.date()+Math.round(t*r)),l)};if($===c)return this.set(c,this.$M+r);if($===h)return this.set(h,this.$y+r);if($===a)return y(1);if($===o)return y(7);var M=(d={},d[s]=e,d[u]=n,d[i]=t,d)[$]||1,m=this.$d.getTime()+r*M;return O.w(m,this)},m.subtract=function(t,e){return this.add(-1*t,e)},m.format=function(t){var e=this,n=this.$locale();if(!this.isValid())return n.invalidDate||l;var r=t||"YYYY-MM-DDTHH:mm:ssZ",i=O.z(this),s=this.$H,u=this.$m,a=this.$M,o=n.weekdays,c=n.months,f=n.meridiem,h=function(t,n,i,s){return t&&(t[n]||t(e,r))||i[n].slice(0,s)},d=function(t){return O.s(s%12||12,t,"0")},$=f||function(t,e,n){var r=t<12?"AM":"PM";return n?r.toLowerCase():r};return r.replace(y,(function(t,r){return r||function(t){switch(t){case"YY":return String(e.$y).slice(-2);case"YYYY":return O.s(e.$y,4,"0");case"M":return a+1;case"MM":return O.s(a+1,2,"0");case"MMM":return h(n.monthsShort,a,c,3);case"MMMM":return h(c,a);case"D":return e.$D;case"DD":return O.s(e.$D,2,"0");case"d":return String(e.$W);case"dd":return h(n.weekdaysMin,e.$W,o,2);case"ddd":return h(n.weekdaysShort,e.$W,o,3);case"dddd":return o[e.$W];case"H":return String(s);case"HH":return O.s(s,2,"0");case"h":return d(1);case"hh":return d(2);case"a":return $(s,u,!0);case"A":return $(s,u,!1);case"m":return String(u);case"mm":return O.s(u,2,"0");case"s":return String(e.$s);case"ss":return O.s(e.$s,2,"0");case"SSS":return O.s(e.$ms,3,"0");case"Z":return i}return null}(t)||i.replace(":","")}))},m.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},m.diff=function(r,d,l){var $,y=this,M=O.p(d),m=w(r),v=(m.utcOffset()-this.utcOffset())*e,g=this-m,D=function(){return O.m(y,m)};switch(M){case h:$=D()/12;break;case c:$=D();break;case f:$=D()/3;break;case o:$=(g-v)/6048e5;break;case a:$=(g-v)/864e5;break;case u:$=g/n;break;case s:$=g/e;break;case i:$=g/t;break;default:$=g;}return l?$:O.a($)},m.daysInMonth=function(){return this.endOf(c).$D},m.$locale=function(){return D[this.$L]},m.locale=function(t,e){if(!t)return this.$L;var n=this.clone(),r=S(t,e,!0);return r&&(n.$L=r),n},m.clone=function(){return O.w(this.$d,this)},m.toDate=function(){return new Date(this.valueOf())},m.toJSON=function(){return this.isValid()?this.toISOString():null},m.toISOString=function(){return this.$d.toISOString()},m.toString=function(){return this.$d.toUTCString()},M}(),_=b.prototype;return w.prototype=_,[["$ms",r],["$s",i],["$m",s],["$H",u],["$W",a],["$M",c],["$y",h],["$D",d]].forEach((function(t){_[t[1]]=function(e){return this.$g(e,t[0],t[1])};})),w.extend=function(t,e){return t.$i||(t(e,b,w),t.$i=!0),w},w.locale=S,w.isDayjs=p,w.unix=function(t){return w(1e3*t)},w.en=D[g],w.Ls=D,w.p={},w}));
|
|
233
|
+
} (dayjs_min, dayjs_min.exports));
|
|
234
|
+
|
|
235
|
+
var dayjs_minExports = dayjs_min.exports;
|
|
236
|
+
var dayjs = /*@__PURE__*/getDefaultExportFromCjs(dayjs_minExports);
|
|
237
|
+
|
|
378
238
|
var NUMBER_RULES = [{
|
|
379
239
|
label: i18next.t("neetoFilters.rules.is"),
|
|
380
240
|
value: "is"
|
|
@@ -458,13 +318,46 @@ function _nonIterableRest() {
|
|
|
458
318
|
}
|
|
459
319
|
|
|
460
320
|
function _slicedToArray(arr, i) {
|
|
461
|
-
return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray
|
|
321
|
+
return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest();
|
|
462
322
|
}
|
|
463
323
|
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
324
|
+
var timezone$1 = {exports: {}};
|
|
325
|
+
|
|
326
|
+
timezone$1.exports;
|
|
327
|
+
|
|
328
|
+
(function (module, exports) {
|
|
329
|
+
!function(t,e){module.exports=e();}(commonjsGlobal,(function(){var t={year:0,month:1,day:2,hour:3,minute:4,second:5},e={};return function(n,i,o){var r,a=function(t,n,i){void 0===i&&(i={});var o=new Date(t),r=function(t,n){void 0===n&&(n={});var i=n.timeZoneName||"short",o=t+"|"+i,r=e[o];return r||(r=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:t,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",timeZoneName:i}),e[o]=r),r}(n,i);return r.formatToParts(o)},u=function(e,n){for(var i=a(e,n),r=[],u=0;u<i.length;u+=1){var f=i[u],s=f.type,m=f.value,c=t[s];c>=0&&(r[c]=parseInt(m,10));}var d=r[3],l=24===d?0:d,v=r[0]+"-"+r[1]+"-"+r[2]+" "+l+":"+r[4]+":"+r[5]+":000",h=+e;return (o.utc(v).valueOf()-(h-=h%1e3))/6e4},f=i.prototype;f.tz=function(t,e){void 0===t&&(t=r);var n=this.utcOffset(),i=this.toDate(),a=i.toLocaleString("en-US",{timeZone:t}),u=Math.round((i-new Date(a))/1e3/60),f=o(a).$set("millisecond",this.$ms).utcOffset(15*-Math.round(i.getTimezoneOffset()/15)-u,!0);if(e){var s=f.utcOffset();f=f.add(n-s,"minute");}return f.$x.$timezone=t,f},f.offsetName=function(t){var e=this.$x.$timezone||o.tz.guess(),n=a(this.valueOf(),e,{timeZoneName:t}).find((function(t){return "timezonename"===t.type.toLowerCase()}));return n&&n.value};var s=f.startOf;f.startOf=function(t,e){if(!this.$x||!this.$x.$timezone)return s.call(this,t,e);var n=o(this.format("YYYY-MM-DD HH:mm:ss:SSS"));return s.call(n,t,e).tz(this.$x.$timezone,!0)},o.tz=function(t,e,n){var i=n&&e,a=n||e||r,f=u(+o(),a);if("string"!=typeof t)return o(t).tz(a);var s=function(t,e,n){var i=t-60*e*1e3,o=u(i,n);if(e===o)return [i,e];var r=u(i-=60*(o-e)*1e3,n);return o===r?[i,o]:[t-60*Math.min(o,r)*1e3,Math.max(o,r)]}(o.utc(t,i).valueOf(),f,a),m=s[0],c=s[1],d=o(m).utcOffset(c);return d.$x.$timezone=a,d},o.tz.guess=function(){return Intl.DateTimeFormat().resolvedOptions().timeZone},o.tz.setDefault=function(t){r=t;};}}));
|
|
330
|
+
} (timezone$1, timezone$1.exports));
|
|
331
|
+
|
|
332
|
+
var timezoneExports = timezone$1.exports;
|
|
333
|
+
var timezone = /*@__PURE__*/getDefaultExportFromCjs(timezoneExports);
|
|
334
|
+
|
|
335
|
+
var utc$1 = {exports: {}};
|
|
336
|
+
|
|
337
|
+
utc$1.exports;
|
|
338
|
+
|
|
339
|
+
(function (module, exports) {
|
|
340
|
+
!function(t,i){module.exports=i();}(commonjsGlobal,(function(){var t="minute",i=/[+-]\d\d(?::?\d\d)?/g,e=/([+-]|\d\d)/g;return function(s,f,n){var u=f.prototype;n.utc=function(t){var i={date:t,utc:!0,args:arguments};return new f(i)},u.utc=function(i){var e=n(this.toDate(),{locale:this.$L,utc:!0});return i?e.add(this.utcOffset(),t):e},u.local=function(){return n(this.toDate(),{locale:this.$L,utc:!1})};var o=u.parse;u.parse=function(t){t.utc&&(this.$u=!0),this.$utils().u(t.$offset)||(this.$offset=t.$offset),o.call(this,t);};var r=u.init;u.init=function(){if(this.$u){var t=this.$d;this.$y=t.getUTCFullYear(),this.$M=t.getUTCMonth(),this.$D=t.getUTCDate(),this.$W=t.getUTCDay(),this.$H=t.getUTCHours(),this.$m=t.getUTCMinutes(),this.$s=t.getUTCSeconds(),this.$ms=t.getUTCMilliseconds();}else r.call(this);};var a=u.utcOffset;u.utcOffset=function(s,f){var n=this.$utils().u;if(n(s))return this.$u?0:n(this.$offset)?a.call(this):this.$offset;if("string"==typeof s&&(s=function(t){void 0===t&&(t="");var s=t.match(i);if(!s)return null;var f=(""+s[0]).match(e)||["-",0,0],n=f[0],u=60*+f[1]+ +f[2];return 0===u?0:"+"===n?u:-u}(s),null===s))return this;var u=Math.abs(s)<=16?60*s:s,o=this;if(f)return o.$offset=u,o.$u=0===s,o;if(0!==s){var r=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();(o=this.local().add(u+r,t)).$offset=u,o.$x.$localOffset=r;}else o=this.utc();return o};var h=u.format;u.format=function(t){var i=t||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":"");return h.call(this,i)},u.valueOf=function(){var t=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||this.$d.getTimezoneOffset());return this.$d.valueOf()-6e4*t},u.isUTC=function(){return !!this.$u},u.toISOString=function(){return this.toDate().toISOString()},u.toString=function(){return this.toDate().toUTCString()};var l=u.toDate;u.toDate=function(t){return "s"===t&&this.$offset?n(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():l.call(this)};var c=u.diff;u.diff=function(t,i,e){if(t&&this.$u===t.$u)return c.call(this,t,i,e);var s=this.local(),f=n(t).local();return c.call(s,f,i,e)};}}));
|
|
341
|
+
} (utc$1, utc$1.exports));
|
|
342
|
+
|
|
343
|
+
var utcExports = utc$1.exports;
|
|
344
|
+
var utc = /*@__PURE__*/getDefaultExportFromCjs(utcExports);
|
|
345
|
+
|
|
346
|
+
var weekday$1 = {exports: {}};
|
|
347
|
+
|
|
348
|
+
weekday$1.exports;
|
|
349
|
+
|
|
350
|
+
(function (module, exports) {
|
|
351
|
+
!function(e,t){module.exports=t();}(commonjsGlobal,(function(){return function(e,t){t.prototype.weekday=function(e){var t=this.$locale().weekStart||0,i=this.$W,n=(i<t?i+7:i)-t;return this.$utils().u(e)?n:this.subtract(n,"day").add(e,"day")};}}));
|
|
352
|
+
} (weekday$1, weekday$1.exports));
|
|
353
|
+
|
|
354
|
+
var weekdayExports = weekday$1.exports;
|
|
355
|
+
var weekday = /*@__PURE__*/getDefaultExportFromCjs(weekdayExports);
|
|
356
|
+
|
|
357
|
+
dayjs.extend(utc);
|
|
358
|
+
dayjs.extend(timezone);
|
|
359
|
+
dayjs.extend(weekday);
|
|
360
|
+
dayjs.Ls.en.weekStart = 1;
|
|
468
361
|
|
|
469
362
|
function ownKeys$4(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
470
363
|
function _objectSpread$4(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$4(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$4(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
@@ -518,19 +411,19 @@ var isMultiModelFilter = function isMultiModelFilter(_ref2) {
|
|
|
518
411
|
return model.split(",").length > 1;
|
|
519
412
|
};
|
|
520
413
|
var getTimezone = function getTimezone() {
|
|
521
|
-
return
|
|
414
|
+
return dayjs.tz.guess();
|
|
522
415
|
};
|
|
523
416
|
var getLabelFromBool = function getLabelFromBool(_ref3) {
|
|
524
417
|
var value = _ref3.value,
|
|
525
418
|
values = _ref3.values;
|
|
526
|
-
return findBy({
|
|
419
|
+
return neetoCist.findBy({
|
|
527
420
|
value: value
|
|
528
421
|
}, ramda.either(ramda.isEmpty, ramda.isNil)(values) ? DEFAULT_BOOLEAN_OPTIONS : values).label;
|
|
529
422
|
};
|
|
530
423
|
var getBoolFromLabel = function getBoolFromLabel(_ref4) {
|
|
531
424
|
var label = _ref4.label,
|
|
532
425
|
values = _ref4.values;
|
|
533
|
-
return findBy({
|
|
426
|
+
return neetoCist.findBy({
|
|
534
427
|
label: label
|
|
535
428
|
}, ramda.either(ramda.isEmpty, ramda.isNil)(values) ? DEFAULT_BOOLEAN_OPTIONS : values).value;
|
|
536
429
|
};
|
|
@@ -540,10 +433,10 @@ var buildRuleOptions = function buildRuleOptions(_ref5) {
|
|
|
540
433
|
return [];
|
|
541
434
|
};
|
|
542
435
|
var getDefaultRuleValue = function getDefaultRuleValue(defaultType) {
|
|
543
|
-
var _buildRuleOptions
|
|
436
|
+
var _buildRuleOptions;
|
|
544
437
|
return ((_buildRuleOptions = buildRuleOptions({
|
|
545
438
|
defaultType: defaultType
|
|
546
|
-
})) === null || _buildRuleOptions === void 0
|
|
439
|
+
})) === null || _buildRuleOptions === void 0 || (_buildRuleOptions = _buildRuleOptions[0]) === null || _buildRuleOptions === void 0 ? void 0 : _buildRuleOptions.value) || "";
|
|
547
440
|
};
|
|
548
441
|
var isUndefinedOrEmpty = ramda.anyPass([ramda.isNil, ramda.isEmpty, ramda.any(ramda.isNil)]);
|
|
549
442
|
|
|
@@ -606,7 +499,7 @@ var buildUpdatedFilter = function buildUpdatedFilter(_ref8) {
|
|
|
606
499
|
var _column$preprocessor;
|
|
607
500
|
return ramda.mergeLeft(filter, {
|
|
608
501
|
rule: rule,
|
|
609
|
-
value: (column === null || column === void 0
|
|
502
|
+
value: (column === null || column === void 0 || (_column$preprocessor = column.preprocessor) === null || _column$preprocessor === void 0 ? void 0 : _column$preprocessor.call(column, value)) || value
|
|
610
503
|
});
|
|
611
504
|
} else if (isSingleTime(defaultType)) {
|
|
612
505
|
return ramda.mergeLeft(filter, {
|
|
@@ -634,6 +527,7 @@ var buildFiltersFromSearchParams = function buildFiltersFromSearchParams(columns
|
|
|
634
527
|
} else if (ramda.isNil(value) || value === "" || column.key === "keyword") {
|
|
635
528
|
return null;
|
|
636
529
|
} else if (column.key === "search_term") {
|
|
530
|
+
if (ramda.isNil(column.node)) return null;
|
|
637
531
|
return ramda.mergeLeft({
|
|
638
532
|
value: value,
|
|
639
533
|
type: "text",
|
|
@@ -696,9 +590,9 @@ var buildFiltersFromSearchParams = function buildFiltersFromSearchParams(columns
|
|
|
696
590
|
};
|
|
697
591
|
var buildTimePayload = function buildTimePayload(value) {
|
|
698
592
|
var timeValue = {
|
|
699
|
-
"this-hour": [
|
|
700
|
-
"last-hour": [
|
|
701
|
-
"next-hour": [
|
|
593
|
+
"this-hour": [dayjs().startOf("hour"), dayjs().endOf("hour")],
|
|
594
|
+
"last-hour": [dayjs().add(-1, "hour").startOf("hour"), dayjs().add(-1, "hour").endOf("hour")],
|
|
595
|
+
"next-hour": [dayjs().add(1, "hour").startOf("hour"), dayjs().add(1, "hour").endOf("hour")]
|
|
702
596
|
};
|
|
703
597
|
if (isCustomTimeRange(value)) {
|
|
704
598
|
return {
|
|
@@ -715,28 +609,28 @@ var buildTimePayload = function buildTimePayload(value) {
|
|
|
715
609
|
};
|
|
716
610
|
var buildDatePayload = function buildDatePayload(value) {
|
|
717
611
|
var dateValue = {
|
|
718
|
-
"this-week": [
|
|
719
|
-
"last-week": [
|
|
720
|
-
"this-month": [
|
|
721
|
-
"last-month": [
|
|
722
|
-
"this-year": [
|
|
723
|
-
"last-year": [
|
|
612
|
+
"this-week": [dayjs().startOf("week"), dayjs().endOf("week")],
|
|
613
|
+
"last-week": [dayjs().add(-1, "week").startOf("week"), dayjs().add(-1, "week").endOf("week")],
|
|
614
|
+
"this-month": [dayjs().startOf("month"), dayjs().endOf("month")],
|
|
615
|
+
"last-month": [dayjs().add(-1, "month").startOf("month"), dayjs().add(-1, "month").endOf("month")],
|
|
616
|
+
"this-year": [dayjs().startOf("year"), dayjs().endOf("year")],
|
|
617
|
+
"last-year": [dayjs().add(-1, "year").startOf("year"), dayjs().add(-1, "year").endOf("year")]
|
|
724
618
|
};
|
|
725
619
|
if (value === "today") {
|
|
726
620
|
return {
|
|
727
|
-
value:
|
|
621
|
+
value: dayjs().toISOString(),
|
|
728
622
|
rule: "on",
|
|
729
623
|
timezone: getTimezone()
|
|
730
624
|
};
|
|
731
625
|
} else if (value === "yesterday") {
|
|
732
626
|
return {
|
|
733
|
-
value:
|
|
627
|
+
value: dayjs().add(-1, "day").toISOString(),
|
|
734
628
|
rule: "on",
|
|
735
629
|
timezone: getTimezone()
|
|
736
630
|
};
|
|
737
631
|
} else if (value === "all-time") {
|
|
738
632
|
return {
|
|
739
|
-
value:
|
|
633
|
+
value: dayjs().toISOString(),
|
|
740
634
|
rule: "before",
|
|
741
635
|
timezone: getTimezone(),
|
|
742
636
|
type: "datetime"
|
|
@@ -786,7 +680,7 @@ var buildMultiOptionPayload = function buildMultiOptionPayload(values) {
|
|
|
786
680
|
}).join("|");
|
|
787
681
|
};
|
|
788
682
|
var buildFiltersPayload = function buildFiltersPayload(filters) {
|
|
789
|
-
var payload = removeBy({
|
|
683
|
+
var payload = neetoCist.removeBy({
|
|
790
684
|
value: ""
|
|
791
685
|
}, filters).map(function (filter) {
|
|
792
686
|
if (filter.key === "search_term" && isMultiModelFilter(filter)) {
|
|
@@ -820,7 +714,7 @@ var buildFiltersPayload = function buildFiltersPayload(filters) {
|
|
|
820
714
|
};
|
|
821
715
|
var buildSegmentsPayload = function buildSegmentsPayload(filters) {
|
|
822
716
|
var childrenKeys = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];
|
|
823
|
-
var payload = removeBy({
|
|
717
|
+
var payload = neetoCist.removeBy({
|
|
824
718
|
value: ""
|
|
825
719
|
}, filters).map(function (filter) {
|
|
826
720
|
if (filter.key === "search_term") {
|
|
@@ -880,7 +774,7 @@ var buildSelectorsFromURL = function buildSelectorsFromURL(columns) {
|
|
|
880
774
|
};
|
|
881
775
|
var compareFilters = function compareFilters(oldFilters, newFilters) {
|
|
882
776
|
var formatFilters = function formatFilters(filters) {
|
|
883
|
-
return removeBy({
|
|
777
|
+
return neetoCist.removeBy({
|
|
884
778
|
value: ""
|
|
885
779
|
}, filters).map(ramda.pick(["key", "rule", "value"]));
|
|
886
780
|
};
|
|
@@ -911,7 +805,7 @@ var buildFilteredColumns = function buildFilteredColumns(_ref11) {
|
|
|
911
805
|
};
|
|
912
806
|
var buildDefaultFilters = function buildDefaultFilters(columns, filters) {
|
|
913
807
|
return columns.filter(function (column) {
|
|
914
|
-
return !isUndefinedOrEmpty(column.defaultValue) && !findBy({
|
|
808
|
+
return !isUndefinedOrEmpty(column.defaultValue) && !neetoCist.findBy({
|
|
915
809
|
key: column.key
|
|
916
810
|
}, filters);
|
|
917
811
|
}).map(function (column) {
|
|
@@ -944,7 +838,7 @@ var createUrlParamString = function createUrlParamString(_ref15) {
|
|
|
944
838
|
} else if (isBoolean(defaultType)) {
|
|
945
839
|
return getLabelFromBool({
|
|
946
840
|
value: value,
|
|
947
|
-
values: findBy({
|
|
841
|
+
values: neetoCist.findBy({
|
|
948
842
|
key: key
|
|
949
843
|
}, columns).values
|
|
950
844
|
});
|
|
@@ -959,6 +853,9 @@ var buildUrlFromFilters = function buildUrlFromFilters(_ref16) {
|
|
|
959
853
|
_ref16$childrenKeys = _ref16.childrenKeys,
|
|
960
854
|
childrenKeys = _ref16$childrenKeys === void 0 ? [] : _ref16$childrenKeys;
|
|
961
855
|
var searchParams = utils.getQueryParams();
|
|
856
|
+
var isKeywordFilterPresent = neetoCist.findBy({
|
|
857
|
+
key: "search_term"
|
|
858
|
+
}, filters);
|
|
962
859
|
columns.forEach(function (_ref17) {
|
|
963
860
|
var key = _ref17.key,
|
|
964
861
|
defaultValue = _ref17.defaultValue;
|
|
@@ -971,7 +868,7 @@ var buildUrlFromFilters = function buildUrlFromFilters(_ref16) {
|
|
|
971
868
|
delete searchParams["segmentId"];
|
|
972
869
|
}
|
|
973
870
|
var defaultFilters = buildDefaultFilters(columns, filters);
|
|
974
|
-
delete searchParams["search_term"];
|
|
871
|
+
isKeywordFilterPresent && delete searchParams["search_term"];
|
|
975
872
|
ramda.concat(filters, defaultFilters).forEach(function (filter) {
|
|
976
873
|
searchParams[filter.key] = createUrlParamString({
|
|
977
874
|
filter: filter,
|
|
@@ -1010,7 +907,7 @@ var buildUrlFromSegment = function buildUrlFromSegment(_ref19) {
|
|
|
1010
907
|
var defaultFilters = buildDefaultFilters(columns, filters);
|
|
1011
908
|
delete searchParams["searchTerm"];
|
|
1012
909
|
ramda.concat(filters, defaultFilters).forEach(function (filter) {
|
|
1013
|
-
isNotEmpty(id) && (searchParams["segmentId"] = id);
|
|
910
|
+
neetoCist.isNotEmpty(id) && (searchParams["segmentId"] = id);
|
|
1014
911
|
searchParams[filter.key] = createUrlParamStringForSegments({
|
|
1015
912
|
filter: filter,
|
|
1016
913
|
columns: columns
|
|
@@ -1036,7 +933,7 @@ var buildFilterColumnsFromFields = function buildFilterColumnsFromFields(_ref21)
|
|
|
1036
933
|
var column = _objectSpread$4({
|
|
1037
934
|
key: ramda.toLower(name),
|
|
1038
935
|
node: "".concat(name, ":").concat(id),
|
|
1039
|
-
label: capitalize(name),
|
|
936
|
+
label: neetoCist.capitalize(name),
|
|
1040
937
|
type: "custom.".concat(kind),
|
|
1041
938
|
showRuleSelector: showRuleSelector
|
|
1042
939
|
}, groupName && {
|
|
@@ -1045,7 +942,7 @@ var buildFilterColumnsFromFields = function buildFilterColumnsFromFields(_ref21)
|
|
|
1045
942
|
if (kind === "single_option" || kind === "multi_option") {
|
|
1046
943
|
column.values = field.data.map(function (item) {
|
|
1047
944
|
return {
|
|
1048
|
-
label: capitalize(item.label),
|
|
945
|
+
label: neetoCist.capitalize(item.label),
|
|
1049
946
|
value: item.id
|
|
1050
947
|
};
|
|
1051
948
|
});
|
|
@@ -1062,14 +959,17 @@ var getColumnsWithStandardizedType = function getColumnsWithStandardizedType(col
|
|
|
1062
959
|
});
|
|
1063
960
|
});
|
|
1064
961
|
};
|
|
962
|
+
var isKeywordFilterPresent = function isKeywordFilterPresent(keyworFilter) {
|
|
963
|
+
return ramda.not(ramda.isEmpty(keyworFilter.node));
|
|
964
|
+
};
|
|
1065
965
|
|
|
1066
966
|
var buildCustomDateValue = function buildCustomDateValue(value) {
|
|
1067
|
-
var isBeforeOrAfter = Math.abs(
|
|
967
|
+
var isBeforeOrAfter = Math.abs(dayjs(value[1]).diff(dayjs(value[0]), "year")) >= 90;
|
|
1068
968
|
if (isBeforeOrAfter) {
|
|
1069
|
-
var currentMoment =
|
|
1070
|
-
var diffWithStart = Math.abs(currentMoment.diff(
|
|
1071
|
-
var diffWithEnd = Math.abs(currentMoment.diff(
|
|
1072
|
-
return diffWithStart < diffWithEnd ? "after-".concat(utils.dateFormat.date(
|
|
969
|
+
var currentMoment = dayjs();
|
|
970
|
+
var diffWithStart = Math.abs(currentMoment.diff(dayjs(value[0]), "year"));
|
|
971
|
+
var diffWithEnd = Math.abs(currentMoment.diff(dayjs(value[1]), "year"));
|
|
972
|
+
return diffWithStart < diffWithEnd ? "after-".concat(utils.dateFormat.date(dayjs(value[0]).subtract(1, "day"))) : "before-".concat(utils.dateFormat.date(dayjs(value[1]).add(1, "day")));
|
|
1073
973
|
}
|
|
1074
974
|
return value.map(utils.dateFormat.date).join(" - ");
|
|
1075
975
|
};
|
|
@@ -1089,11 +989,11 @@ var buildFilterValue = function buildFilterValue(filter) {
|
|
|
1089
989
|
} else if (isTime(defaultType) && isCustomTimeRange(value)) {
|
|
1090
990
|
return value.map(utils.dateFormat.time).join(" - ");
|
|
1091
991
|
} else if (isDate(defaultType) || isTime(defaultType)) {
|
|
1092
|
-
return humanize(value);
|
|
992
|
+
return neetoCist.humanize(value);
|
|
1093
993
|
} else if (isMulti(defaultType)) {
|
|
1094
994
|
return value.map(function (value) {
|
|
1095
995
|
var _findBy;
|
|
1096
|
-
return ((_findBy = findBy({
|
|
996
|
+
return ((_findBy = neetoCist.findBy({
|
|
1097
997
|
value: value
|
|
1098
998
|
}, values)) === null || _findBy === void 0 ? void 0 : _findBy.label) || value;
|
|
1099
999
|
}).join(", ");
|
|
@@ -1107,7 +1007,7 @@ var buildFilterValue = function buildFilterValue(filter) {
|
|
|
1107
1007
|
values: values
|
|
1108
1008
|
});
|
|
1109
1009
|
}
|
|
1110
|
-
return ((_findBy2 = findBy({
|
|
1010
|
+
return ((_findBy2 = neetoCist.findBy({
|
|
1111
1011
|
value: value
|
|
1112
1012
|
}, values)) === null || _findBy2 === void 0 ? void 0 : _findBy2.label) || value;
|
|
1113
1013
|
};
|
|
@@ -1115,19 +1015,19 @@ var buildRuleValue = function buildRuleValue(_ref) {
|
|
|
1115
1015
|
var rule = _ref.rule,
|
|
1116
1016
|
defaultType = _ref.defaultType;
|
|
1117
1017
|
if (isText(defaultType)) {
|
|
1118
|
-
return findBy({
|
|
1018
|
+
return neetoCist.findBy({
|
|
1119
1019
|
value: rule
|
|
1120
1020
|
}, TEXT_RULES).label;
|
|
1121
1021
|
} else if (isDigit(defaultType)) {
|
|
1122
|
-
return findBy({
|
|
1022
|
+
return neetoCist.findBy({
|
|
1123
1023
|
value: rule
|
|
1124
1024
|
}, NUMBER_RULES).label;
|
|
1125
1025
|
} else if (isSingleDate(defaultType)) {
|
|
1126
|
-
return findBy({
|
|
1026
|
+
return neetoCist.findBy({
|
|
1127
1027
|
value: rule
|
|
1128
1028
|
}, SINGLE_DATE_OPTIONS).label;
|
|
1129
1029
|
} else if (isSingleTime(defaultType)) {
|
|
1130
|
-
return findBy({
|
|
1030
|
+
return neetoCist.findBy({
|
|
1131
1031
|
value: rule
|
|
1132
1032
|
}, SINGLE_TIME_OPTIONS).label;
|
|
1133
1033
|
}
|
|
@@ -1321,6 +1221,18 @@ var useDestroySegment = function useDestroySegment(options) {
|
|
|
1321
1221
|
}, options));
|
|
1322
1222
|
};
|
|
1323
1223
|
|
|
1224
|
+
var buildSegmentsValidationSchema = function buildSegmentsValidationSchema(defaultSegmentName) {
|
|
1225
|
+
return yup__namespace.object({
|
|
1226
|
+
name: yup__namespace.string().trim().required().test({
|
|
1227
|
+
name: "not-default-segment-name",
|
|
1228
|
+
test: function test(value) {
|
|
1229
|
+
return (value === null || value === void 0 ? void 0 : value.toLocaleLowerCase()) !== defaultSegmentName.toLocaleLowerCase();
|
|
1230
|
+
},
|
|
1231
|
+
message: i18next.t("neetoFilters.segments.reservedNameErrorMessage")
|
|
1232
|
+
})
|
|
1233
|
+
});
|
|
1234
|
+
};
|
|
1235
|
+
|
|
1324
1236
|
var Menu = neetoui.Dropdown.Menu,
|
|
1325
1237
|
MenuItem = neetoui.Dropdown.MenuItem;
|
|
1326
1238
|
var Segment = function Segment(_ref) {
|
|
@@ -1328,7 +1240,8 @@ var Segment = function Segment(_ref) {
|
|
|
1328
1240
|
filters = _ref.filters,
|
|
1329
1241
|
columns = _ref.columns,
|
|
1330
1242
|
childrenKeys = _ref.childrenKeys,
|
|
1331
|
-
setIsFilterPaneOpen = _ref.setIsFilterPaneOpen
|
|
1243
|
+
setIsFilterPaneOpen = _ref.setIsFilterPaneOpen,
|
|
1244
|
+
defaultSegmentName = _ref.defaultSegmentName;
|
|
1332
1245
|
var _useState = React.useState(false),
|
|
1333
1246
|
_useState2 = _slicedToArray(_useState, 2),
|
|
1334
1247
|
isSavePaneOpen = _useState2[0],
|
|
@@ -1431,7 +1344,7 @@ var Segment = function Segment(_ref) {
|
|
|
1431
1344
|
},
|
|
1432
1345
|
validateOnChange: true,
|
|
1433
1346
|
validateOnBlur: true,
|
|
1434
|
-
validationSchema:
|
|
1347
|
+
validationSchema: buildSegmentsValidationSchema(defaultSegmentName),
|
|
1435
1348
|
onSubmit: handleSubmit
|
|
1436
1349
|
}
|
|
1437
1350
|
}, /*#__PURE__*/React__default["default"].createElement(neetoui.Pane.Body, null, /*#__PURE__*/React__default["default"].createElement(formik.Input, {
|
|
@@ -1477,127 +1390,132 @@ var Bar = function Bar(_ref) {
|
|
|
1477
1390
|
keyword = _ref$keyword === void 0 ? {
|
|
1478
1391
|
node: "",
|
|
1479
1392
|
value: "",
|
|
1480
|
-
setValue: noop
|
|
1393
|
+
setValue: neetoCist.noop
|
|
1481
1394
|
} : _ref$keyword,
|
|
1482
1395
|
_ref$setIsPaneOpen = _ref.setIsPaneOpen,
|
|
1483
1396
|
setIsPaneOpen = _ref$setIsPaneOpen === void 0 ? ramda.identity : _ref$setIsPaneOpen,
|
|
1484
1397
|
_ref$childrenKeys = _ref.childrenKeys,
|
|
1485
|
-
childrenKeys = _ref$childrenKeys === void 0 ? [] : _ref$childrenKeys
|
|
1486
|
-
|
|
1487
|
-
|
|
1488
|
-
|
|
1489
|
-
|
|
1490
|
-
|
|
1491
|
-
|
|
1492
|
-
|
|
1493
|
-
|
|
1494
|
-
|
|
1495
|
-
|
|
1496
|
-
|
|
1497
|
-
|
|
1498
|
-
|
|
1499
|
-
|
|
1500
|
-
|
|
1501
|
-
hidden: true
|
|
1502
|
-
}, filters);
|
|
1503
|
-
var history = reactRouterDom.useHistory();
|
|
1504
|
-
React.useEffect(function () {
|
|
1505
|
-
if (initialRenderRef.current) {
|
|
1506
|
-
initialRenderRef.current = false;
|
|
1507
|
-
return noop$1;
|
|
1508
|
-
}
|
|
1509
|
-
var handler = setTimeout(function () {
|
|
1510
|
-
handleSubmit(filters);
|
|
1511
|
-
}, 500);
|
|
1512
|
-
return function () {
|
|
1513
|
-
return clearTimeout(handler);
|
|
1514
|
-
};
|
|
1515
|
-
}, [keywordValue]);
|
|
1516
|
-
var handleSubmit = function handleSubmit(newFilters, isClearAll) {
|
|
1517
|
-
var params = buildUrlFromFilters(_objectSpread$2({
|
|
1518
|
-
columns: columns,
|
|
1519
|
-
filters: isNotEmpty(getSearchTermFromUrl()) ? [].concat(_toConsumableArray(newFilters), [keywordFilter]) : newFilters
|
|
1520
|
-
}, isClearAll && {
|
|
1521
|
-
isClearAll: true,
|
|
1522
|
-
childrenKeys: childrenKeys
|
|
1523
|
-
}));
|
|
1524
|
-
history.push({
|
|
1525
|
-
search: params
|
|
1398
|
+
childrenKeys = _ref$childrenKeys === void 0 ? [] : _ref$childrenKeys,
|
|
1399
|
+
_ref$defaultSegmentNa = _ref.defaultSegmentName,
|
|
1400
|
+
defaultSegmentName = _ref$defaultSegmentNa === void 0 ? i18next.t("neetoFilters.common.allResults") : _ref$defaultSegmentNa;
|
|
1401
|
+
return function () {
|
|
1402
|
+
var _useTranslation = reactI18next.useTranslation(),
|
|
1403
|
+
t = _useTranslation.t;
|
|
1404
|
+
var initialRenderRef = React.useRef(true);
|
|
1405
|
+
var searchParams = reactUtils.useQueryParams();
|
|
1406
|
+
var keywordValue = searchParams.search_term || "";
|
|
1407
|
+
var keywordFilter = _objectSpread$2(_objectSpread$2({
|
|
1408
|
+
type: "text",
|
|
1409
|
+
rule: "contains",
|
|
1410
|
+
label: t("neetoFilters.common.searchTerm")
|
|
1411
|
+
}, keyword), {}, {
|
|
1412
|
+
key: "search_term",
|
|
1413
|
+
value: keywordValue
|
|
1526
1414
|
});
|
|
1527
|
-
|
|
1528
|
-
|
|
1529
|
-
|
|
1530
|
-
|
|
1415
|
+
var filters = buildFiltersFromSearchParams(isKeywordFilterPresent(keywordFilter) && neetoCist.isNotEmpty(keywordValue) ? [keywordFilter].concat(_toConsumableArray(columns)) : columns);
|
|
1416
|
+
var nonHiddenFilters = neetoCist.removeBy({
|
|
1417
|
+
hidden: true
|
|
1418
|
+
}, filters);
|
|
1419
|
+
var history = reactRouterDom.useHistory();
|
|
1420
|
+
var handleSubmit = function handleSubmit(newFilters, isClearAll) {
|
|
1421
|
+
var params = buildUrlFromFilters(_objectSpread$2({
|
|
1422
|
+
columns: columns,
|
|
1423
|
+
filters: isKeywordFilterPresent(keywordFilter) && neetoCist.isNotEmpty(getSearchTermFromUrl()) ? [].concat(_toConsumableArray(newFilters), [keywordFilter]) : newFilters
|
|
1424
|
+
}, isClearAll && {
|
|
1425
|
+
isClearAll: true,
|
|
1426
|
+
childrenKeys: childrenKeys
|
|
1427
|
+
}));
|
|
1428
|
+
history.push({
|
|
1429
|
+
search: params
|
|
1430
|
+
});
|
|
1431
|
+
};
|
|
1432
|
+
var handleDelete = function handleDelete(key) {
|
|
1433
|
+
if (key === "search_term") {
|
|
1434
|
+
var params = ramda.omit(["search_term"], utils.getQueryParams());
|
|
1435
|
+
var pathname = window.location.pathname;
|
|
1436
|
+
history.push(utils.buildUrl(pathname, params));
|
|
1437
|
+
return;
|
|
1438
|
+
}
|
|
1439
|
+
if (childrenKeys.includes(key)) {
|
|
1440
|
+
var _params = ramda.omit([key], utils.getQueryParams());
|
|
1441
|
+
var _pathname = window.location.pathname;
|
|
1442
|
+
history.push(utils.buildUrl(_pathname, _params));
|
|
1443
|
+
}
|
|
1444
|
+
var newFilters = neetoCist.removeBy({
|
|
1445
|
+
key: key
|
|
1446
|
+
}, filters);
|
|
1447
|
+
handleSubmit(newFilters);
|
|
1448
|
+
};
|
|
1449
|
+
var handleClearAll = function handleClearAll() {
|
|
1450
|
+
var params = isKeywordFilterPresent(keywordFilter) ? ramda.omit(["search_term"], utils.getQueryParams()) : utils.getQueryParams();
|
|
1531
1451
|
var pathname = window.location.pathname;
|
|
1532
1452
|
history.push(utils.buildUrl(pathname, params));
|
|
1533
|
-
|
|
1534
|
-
}
|
|
1535
|
-
|
|
1536
|
-
|
|
1537
|
-
|
|
1538
|
-
|
|
1539
|
-
|
|
1540
|
-
|
|
1541
|
-
|
|
1542
|
-
}
|
|
1543
|
-
|
|
1544
|
-
|
|
1545
|
-
|
|
1546
|
-
|
|
1547
|
-
|
|
1548
|
-
|
|
1549
|
-
|
|
1550
|
-
|
|
1551
|
-
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
|
|
1555
|
-
|
|
1556
|
-
|
|
1557
|
-
|
|
1558
|
-
|
|
1559
|
-
|
|
1560
|
-
|
|
1561
|
-
|
|
1562
|
-
|
|
1563
|
-
|
|
1564
|
-
|
|
1565
|
-
|
|
1566
|
-
|
|
1567
|
-
|
|
1568
|
-
|
|
1569
|
-
|
|
1570
|
-
|
|
1571
|
-
|
|
1572
|
-
|
|
1573
|
-
|
|
1574
|
-
|
|
1575
|
-
|
|
1576
|
-
|
|
1577
|
-
|
|
1578
|
-
|
|
1579
|
-
|
|
1580
|
-
|
|
1581
|
-
|
|
1582
|
-
|
|
1583
|
-
|
|
1453
|
+
handleSubmit([], true);
|
|
1454
|
+
};
|
|
1455
|
+
var childrenFiltersApplied = childrenKeys.some(function (key) {
|
|
1456
|
+
return ramda.has(key, searchParams);
|
|
1457
|
+
});
|
|
1458
|
+
var hideClearButton = nonHiddenFilters.every(function (_ref2) {
|
|
1459
|
+
var defaultValue = _ref2.defaultValue,
|
|
1460
|
+
isClearable = _ref2.isClearable;
|
|
1461
|
+
return defaultValue && !isClearable;
|
|
1462
|
+
}) && !childrenFiltersApplied;
|
|
1463
|
+
React.useEffect(function () {
|
|
1464
|
+
if (initialRenderRef.current) {
|
|
1465
|
+
initialRenderRef.current = false;
|
|
1466
|
+
return neetoCist.noop;
|
|
1467
|
+
}
|
|
1468
|
+
var handler = setTimeout(function () {
|
|
1469
|
+
handleSubmit(filters);
|
|
1470
|
+
}, 500);
|
|
1471
|
+
return function () {
|
|
1472
|
+
return clearTimeout(handler);
|
|
1473
|
+
};
|
|
1474
|
+
}, [keywordValue]);
|
|
1475
|
+
if (ramda.isEmpty(nonHiddenFilters) && !childrenFiltersApplied) return null;
|
|
1476
|
+
return /*#__PURE__*/React__default["default"].createElement("div", {
|
|
1477
|
+
className: classnames__default["default"]("neeto-filters-bar", _defineProperty({}, className, className))
|
|
1478
|
+
}, nonHiddenFilters.map(function (filter) {
|
|
1479
|
+
var _filter$suffixCompone;
|
|
1480
|
+
return /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, {
|
|
1481
|
+
key: filter.key
|
|
1482
|
+
}, /*#__PURE__*/React__default["default"].createElement(Block, {
|
|
1483
|
+
filter: filter,
|
|
1484
|
+
handleDelete: handleDelete,
|
|
1485
|
+
setIsPaneOpen: setIsPaneOpen
|
|
1486
|
+
}), (_filter$suffixCompone = filter.suffixComponent) === null || _filter$suffixCompone === void 0 ? void 0 : _filter$suffixCompone.call(filter), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
1487
|
+
className: "neeto-filters-bar--separator"
|
|
1488
|
+
}));
|
|
1489
|
+
}), childrenKeys.filter(function (childKey) {
|
|
1490
|
+
return ramda.has(childKey, searchParams);
|
|
1491
|
+
}).map(function (childKey) {
|
|
1492
|
+
return /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, {
|
|
1493
|
+
key: childKey
|
|
1494
|
+
}, /*#__PURE__*/React__default["default"].createElement(ChildBlock, {
|
|
1495
|
+
childKey: childKey,
|
|
1496
|
+
handleDelete: handleDelete,
|
|
1497
|
+
setIsPaneOpen: setIsPaneOpen
|
|
1498
|
+
}), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
1499
|
+
className: "neeto-filters-bar--separator"
|
|
1500
|
+
}));
|
|
1501
|
+
}), ramda.isNotNil(entity) && /*#__PURE__*/React__default["default"].createElement(Segment, {
|
|
1502
|
+
childrenKeys: childrenKeys,
|
|
1503
|
+
columns: columns,
|
|
1504
|
+
defaultSegmentName: defaultSegmentName,
|
|
1505
|
+
entity: entity,
|
|
1506
|
+
filters: filters,
|
|
1507
|
+
setIsFilterPaneOpen: setIsPaneOpen
|
|
1508
|
+
}), !hideClearButton && /*#__PURE__*/React__default["default"].createElement(neetoui.Button, {
|
|
1509
|
+
"data-cy": "neeto-filters-bar-clear-btn",
|
|
1510
|
+
label: t("neetoFilters.common.clearFilters"),
|
|
1511
|
+
style: "text",
|
|
1512
|
+
onClick: handleClearAll
|
|
1584
1513
|
}));
|
|
1585
|
-
}
|
|
1586
|
-
childrenKeys: childrenKeys,
|
|
1587
|
-
columns: columns,
|
|
1588
|
-
entity: entity,
|
|
1589
|
-
filters: filters,
|
|
1590
|
-
setIsFilterPaneOpen: setIsPaneOpen
|
|
1591
|
-
}), !hideClearButton && /*#__PURE__*/React__default["default"].createElement(neetoui.Button, {
|
|
1592
|
-
"data-cy": "neeto-filters-bar-clear-btn",
|
|
1593
|
-
label: t("neetoFilters.common.clearFilters"),
|
|
1594
|
-
style: "text",
|
|
1595
|
-
onClick: handleClearAll
|
|
1596
|
-
}));
|
|
1514
|
+
}();
|
|
1597
1515
|
};
|
|
1598
1516
|
|
|
1599
|
-
function _extends
|
|
1600
|
-
_extends
|
|
1517
|
+
function _extends() {
|
|
1518
|
+
_extends = Object.assign ? Object.assign.bind() : function (target) {
|
|
1601
1519
|
for (var i = 1; i < arguments.length; i++) {
|
|
1602
1520
|
var source = arguments[i];
|
|
1603
1521
|
for (var key in source) {
|
|
@@ -1608,10 +1526,10 @@ function _extends$1() {
|
|
|
1608
1526
|
}
|
|
1609
1527
|
return target;
|
|
1610
1528
|
};
|
|
1611
|
-
return _extends
|
|
1529
|
+
return _extends.apply(this, arguments);
|
|
1612
1530
|
}
|
|
1613
1531
|
|
|
1614
|
-
function _objectWithoutPropertiesLoose
|
|
1532
|
+
function _objectWithoutPropertiesLoose(source, excluded) {
|
|
1615
1533
|
if (source == null) return {};
|
|
1616
1534
|
var target = {};
|
|
1617
1535
|
var sourceKeys = Object.keys(source);
|
|
@@ -1626,7 +1544,7 @@ function _objectWithoutPropertiesLoose$1(source, excluded) {
|
|
|
1626
1544
|
|
|
1627
1545
|
function _objectWithoutProperties(source, excluded) {
|
|
1628
1546
|
if (source == null) return {};
|
|
1629
|
-
var target = _objectWithoutPropertiesLoose
|
|
1547
|
+
var target = _objectWithoutPropertiesLoose(source, excluded);
|
|
1630
1548
|
var key, i;
|
|
1631
1549
|
if (Object.getOwnPropertySymbols) {
|
|
1632
1550
|
var sourceSymbolKeys = Object.getOwnPropertySymbols(source);
|
|
@@ -1668,34 +1586,6 @@ var Portal = function Portal(_ref) {
|
|
|
1668
1586
|
return /*#__PURE__*/ReactDOM.createPortal(children, target.current);
|
|
1669
1587
|
};
|
|
1670
1588
|
|
|
1671
|
-
function _extends() {
|
|
1672
|
-
_extends = Object.assign ? Object.assign.bind() : function (target) {
|
|
1673
|
-
for (var i = 1; i < arguments.length; i++) {
|
|
1674
|
-
var source = arguments[i];
|
|
1675
|
-
for (var key in source) {
|
|
1676
|
-
if (Object.prototype.hasOwnProperty.call(source, key)) {
|
|
1677
|
-
target[key] = source[key];
|
|
1678
|
-
}
|
|
1679
|
-
}
|
|
1680
|
-
}
|
|
1681
|
-
return target;
|
|
1682
|
-
};
|
|
1683
|
-
return _extends.apply(this, arguments);
|
|
1684
|
-
}
|
|
1685
|
-
|
|
1686
|
-
function _objectWithoutPropertiesLoose(source, excluded) {
|
|
1687
|
-
if (source == null) return {};
|
|
1688
|
-
var target = {};
|
|
1689
|
-
var sourceKeys = Object.keys(source);
|
|
1690
|
-
var key, i;
|
|
1691
|
-
for (i = 0; i < sourceKeys.length; i++) {
|
|
1692
|
-
key = sourceKeys[i];
|
|
1693
|
-
if (excluded.indexOf(key) >= 0) continue;
|
|
1694
|
-
target[key] = source[key];
|
|
1695
|
-
}
|
|
1696
|
-
return target;
|
|
1697
|
-
}
|
|
1698
|
-
|
|
1699
1589
|
function _setPrototypeOf(o, p) {
|
|
1700
1590
|
_setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {
|
|
1701
1591
|
o.__proto__ = p;
|
|
@@ -1710,1188 +1600,6 @@ function _inheritsLoose(subClass, superClass) {
|
|
|
1710
1600
|
_setPrototypeOf(subClass, superClass);
|
|
1711
1601
|
}
|
|
1712
1602
|
|
|
1713
|
-
var propTypes = {exports: {}};
|
|
1714
|
-
|
|
1715
|
-
var reactIs = {exports: {}};
|
|
1716
|
-
|
|
1717
|
-
var reactIs_production_min = {};
|
|
1718
|
-
|
|
1719
|
-
/** @license React v16.13.1
|
|
1720
|
-
* react-is.production.min.js
|
|
1721
|
-
*
|
|
1722
|
-
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
1723
|
-
*
|
|
1724
|
-
* This source code is licensed under the MIT license found in the
|
|
1725
|
-
* LICENSE file in the root directory of this source tree.
|
|
1726
|
-
*/
|
|
1727
|
-
|
|
1728
|
-
var hasRequiredReactIs_production_min;
|
|
1729
|
-
|
|
1730
|
-
function requireReactIs_production_min () {
|
|
1731
|
-
if (hasRequiredReactIs_production_min) return reactIs_production_min;
|
|
1732
|
-
hasRequiredReactIs_production_min = 1;
|
|
1733
|
-
var b="function"===typeof Symbol&&Symbol.for,c=b?Symbol.for("react.element"):60103,d=b?Symbol.for("react.portal"):60106,e=b?Symbol.for("react.fragment"):60107,f=b?Symbol.for("react.strict_mode"):60108,g=b?Symbol.for("react.profiler"):60114,h=b?Symbol.for("react.provider"):60109,k=b?Symbol.for("react.context"):60110,l=b?Symbol.for("react.async_mode"):60111,m=b?Symbol.for("react.concurrent_mode"):60111,n=b?Symbol.for("react.forward_ref"):60112,p=b?Symbol.for("react.suspense"):60113,q=b?
|
|
1734
|
-
Symbol.for("react.suspense_list"):60120,r=b?Symbol.for("react.memo"):60115,t=b?Symbol.for("react.lazy"):60116,v=b?Symbol.for("react.block"):60121,w=b?Symbol.for("react.fundamental"):60117,x=b?Symbol.for("react.responder"):60118,y=b?Symbol.for("react.scope"):60119;
|
|
1735
|
-
function z(a){if("object"===typeof a&&null!==a){var u=a.$$typeof;switch(u){case c:switch(a=a.type,a){case l:case m:case e:case g:case f:case p:return a;default:switch(a=a&&a.$$typeof,a){case k:case n:case t:case r:case h:return a;default:return u}}case d:return u}}}function A(a){return z(a)===m}reactIs_production_min.AsyncMode=l;reactIs_production_min.ConcurrentMode=m;reactIs_production_min.ContextConsumer=k;reactIs_production_min.ContextProvider=h;reactIs_production_min.Element=c;reactIs_production_min.ForwardRef=n;reactIs_production_min.Fragment=e;reactIs_production_min.Lazy=t;reactIs_production_min.Memo=r;reactIs_production_min.Portal=d;
|
|
1736
|
-
reactIs_production_min.Profiler=g;reactIs_production_min.StrictMode=f;reactIs_production_min.Suspense=p;reactIs_production_min.isAsyncMode=function(a){return A(a)||z(a)===l};reactIs_production_min.isConcurrentMode=A;reactIs_production_min.isContextConsumer=function(a){return z(a)===k};reactIs_production_min.isContextProvider=function(a){return z(a)===h};reactIs_production_min.isElement=function(a){return "object"===typeof a&&null!==a&&a.$$typeof===c};reactIs_production_min.isForwardRef=function(a){return z(a)===n};reactIs_production_min.isFragment=function(a){return z(a)===e};reactIs_production_min.isLazy=function(a){return z(a)===t};
|
|
1737
|
-
reactIs_production_min.isMemo=function(a){return z(a)===r};reactIs_production_min.isPortal=function(a){return z(a)===d};reactIs_production_min.isProfiler=function(a){return z(a)===g};reactIs_production_min.isStrictMode=function(a){return z(a)===f};reactIs_production_min.isSuspense=function(a){return z(a)===p};
|
|
1738
|
-
reactIs_production_min.isValidElementType=function(a){return "string"===typeof a||"function"===typeof a||a===e||a===m||a===g||a===f||a===p||a===q||"object"===typeof a&&null!==a&&(a.$$typeof===t||a.$$typeof===r||a.$$typeof===h||a.$$typeof===k||a.$$typeof===n||a.$$typeof===w||a.$$typeof===x||a.$$typeof===y||a.$$typeof===v)};reactIs_production_min.typeOf=z;
|
|
1739
|
-
return reactIs_production_min;
|
|
1740
|
-
}
|
|
1741
|
-
|
|
1742
|
-
var reactIs_development = {};
|
|
1743
|
-
|
|
1744
|
-
/** @license React v16.13.1
|
|
1745
|
-
* react-is.development.js
|
|
1746
|
-
*
|
|
1747
|
-
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
1748
|
-
*
|
|
1749
|
-
* This source code is licensed under the MIT license found in the
|
|
1750
|
-
* LICENSE file in the root directory of this source tree.
|
|
1751
|
-
*/
|
|
1752
|
-
|
|
1753
|
-
var hasRequiredReactIs_development;
|
|
1754
|
-
|
|
1755
|
-
function requireReactIs_development () {
|
|
1756
|
-
if (hasRequiredReactIs_development) return reactIs_development;
|
|
1757
|
-
hasRequiredReactIs_development = 1;
|
|
1758
|
-
|
|
1759
|
-
|
|
1760
|
-
|
|
1761
|
-
if (process.env.NODE_ENV !== "production") {
|
|
1762
|
-
(function() {
|
|
1763
|
-
|
|
1764
|
-
// The Symbol used to tag the ReactElement-like types. If there is no native Symbol
|
|
1765
|
-
// nor polyfill, then a plain number is used for performance.
|
|
1766
|
-
var hasSymbol = typeof Symbol === 'function' && Symbol.for;
|
|
1767
|
-
var REACT_ELEMENT_TYPE = hasSymbol ? Symbol.for('react.element') : 0xeac7;
|
|
1768
|
-
var REACT_PORTAL_TYPE = hasSymbol ? Symbol.for('react.portal') : 0xeaca;
|
|
1769
|
-
var REACT_FRAGMENT_TYPE = hasSymbol ? Symbol.for('react.fragment') : 0xeacb;
|
|
1770
|
-
var REACT_STRICT_MODE_TYPE = hasSymbol ? Symbol.for('react.strict_mode') : 0xeacc;
|
|
1771
|
-
var REACT_PROFILER_TYPE = hasSymbol ? Symbol.for('react.profiler') : 0xead2;
|
|
1772
|
-
var REACT_PROVIDER_TYPE = hasSymbol ? Symbol.for('react.provider') : 0xeacd;
|
|
1773
|
-
var REACT_CONTEXT_TYPE = hasSymbol ? Symbol.for('react.context') : 0xeace; // TODO: We don't use AsyncMode or ConcurrentMode anymore. They were temporary
|
|
1774
|
-
// (unstable) APIs that have been removed. Can we remove the symbols?
|
|
1775
|
-
|
|
1776
|
-
var REACT_ASYNC_MODE_TYPE = hasSymbol ? Symbol.for('react.async_mode') : 0xeacf;
|
|
1777
|
-
var REACT_CONCURRENT_MODE_TYPE = hasSymbol ? Symbol.for('react.concurrent_mode') : 0xeacf;
|
|
1778
|
-
var REACT_FORWARD_REF_TYPE = hasSymbol ? Symbol.for('react.forward_ref') : 0xead0;
|
|
1779
|
-
var REACT_SUSPENSE_TYPE = hasSymbol ? Symbol.for('react.suspense') : 0xead1;
|
|
1780
|
-
var REACT_SUSPENSE_LIST_TYPE = hasSymbol ? Symbol.for('react.suspense_list') : 0xead8;
|
|
1781
|
-
var REACT_MEMO_TYPE = hasSymbol ? Symbol.for('react.memo') : 0xead3;
|
|
1782
|
-
var REACT_LAZY_TYPE = hasSymbol ? Symbol.for('react.lazy') : 0xead4;
|
|
1783
|
-
var REACT_BLOCK_TYPE = hasSymbol ? Symbol.for('react.block') : 0xead9;
|
|
1784
|
-
var REACT_FUNDAMENTAL_TYPE = hasSymbol ? Symbol.for('react.fundamental') : 0xead5;
|
|
1785
|
-
var REACT_RESPONDER_TYPE = hasSymbol ? Symbol.for('react.responder') : 0xead6;
|
|
1786
|
-
var REACT_SCOPE_TYPE = hasSymbol ? Symbol.for('react.scope') : 0xead7;
|
|
1787
|
-
|
|
1788
|
-
function isValidElementType(type) {
|
|
1789
|
-
return typeof type === 'string' || typeof type === 'function' || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.
|
|
1790
|
-
type === REACT_FRAGMENT_TYPE || type === REACT_CONCURRENT_MODE_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || typeof type === 'object' && type !== null && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_FUNDAMENTAL_TYPE || type.$$typeof === REACT_RESPONDER_TYPE || type.$$typeof === REACT_SCOPE_TYPE || type.$$typeof === REACT_BLOCK_TYPE);
|
|
1791
|
-
}
|
|
1792
|
-
|
|
1793
|
-
function typeOf(object) {
|
|
1794
|
-
if (typeof object === 'object' && object !== null) {
|
|
1795
|
-
var $$typeof = object.$$typeof;
|
|
1796
|
-
|
|
1797
|
-
switch ($$typeof) {
|
|
1798
|
-
case REACT_ELEMENT_TYPE:
|
|
1799
|
-
var type = object.type;
|
|
1800
|
-
|
|
1801
|
-
switch (type) {
|
|
1802
|
-
case REACT_ASYNC_MODE_TYPE:
|
|
1803
|
-
case REACT_CONCURRENT_MODE_TYPE:
|
|
1804
|
-
case REACT_FRAGMENT_TYPE:
|
|
1805
|
-
case REACT_PROFILER_TYPE:
|
|
1806
|
-
case REACT_STRICT_MODE_TYPE:
|
|
1807
|
-
case REACT_SUSPENSE_TYPE:
|
|
1808
|
-
return type;
|
|
1809
|
-
|
|
1810
|
-
default:
|
|
1811
|
-
var $$typeofType = type && type.$$typeof;
|
|
1812
|
-
|
|
1813
|
-
switch ($$typeofType) {
|
|
1814
|
-
case REACT_CONTEXT_TYPE:
|
|
1815
|
-
case REACT_FORWARD_REF_TYPE:
|
|
1816
|
-
case REACT_LAZY_TYPE:
|
|
1817
|
-
case REACT_MEMO_TYPE:
|
|
1818
|
-
case REACT_PROVIDER_TYPE:
|
|
1819
|
-
return $$typeofType;
|
|
1820
|
-
|
|
1821
|
-
default:
|
|
1822
|
-
return $$typeof;
|
|
1823
|
-
}
|
|
1824
|
-
|
|
1825
|
-
}
|
|
1826
|
-
|
|
1827
|
-
case REACT_PORTAL_TYPE:
|
|
1828
|
-
return $$typeof;
|
|
1829
|
-
}
|
|
1830
|
-
}
|
|
1831
|
-
|
|
1832
|
-
return undefined;
|
|
1833
|
-
} // AsyncMode is deprecated along with isAsyncMode
|
|
1834
|
-
|
|
1835
|
-
var AsyncMode = REACT_ASYNC_MODE_TYPE;
|
|
1836
|
-
var ConcurrentMode = REACT_CONCURRENT_MODE_TYPE;
|
|
1837
|
-
var ContextConsumer = REACT_CONTEXT_TYPE;
|
|
1838
|
-
var ContextProvider = REACT_PROVIDER_TYPE;
|
|
1839
|
-
var Element = REACT_ELEMENT_TYPE;
|
|
1840
|
-
var ForwardRef = REACT_FORWARD_REF_TYPE;
|
|
1841
|
-
var Fragment = REACT_FRAGMENT_TYPE;
|
|
1842
|
-
var Lazy = REACT_LAZY_TYPE;
|
|
1843
|
-
var Memo = REACT_MEMO_TYPE;
|
|
1844
|
-
var Portal = REACT_PORTAL_TYPE;
|
|
1845
|
-
var Profiler = REACT_PROFILER_TYPE;
|
|
1846
|
-
var StrictMode = REACT_STRICT_MODE_TYPE;
|
|
1847
|
-
var Suspense = REACT_SUSPENSE_TYPE;
|
|
1848
|
-
var hasWarnedAboutDeprecatedIsAsyncMode = false; // AsyncMode should be deprecated
|
|
1849
|
-
|
|
1850
|
-
function isAsyncMode(object) {
|
|
1851
|
-
{
|
|
1852
|
-
if (!hasWarnedAboutDeprecatedIsAsyncMode) {
|
|
1853
|
-
hasWarnedAboutDeprecatedIsAsyncMode = true; // Using console['warn'] to evade Babel and ESLint
|
|
1854
|
-
|
|
1855
|
-
console['warn']('The ReactIs.isAsyncMode() alias has been deprecated, ' + 'and will be removed in React 17+. Update your code to use ' + 'ReactIs.isConcurrentMode() instead. It has the exact same API.');
|
|
1856
|
-
}
|
|
1857
|
-
}
|
|
1858
|
-
|
|
1859
|
-
return isConcurrentMode(object) || typeOf(object) === REACT_ASYNC_MODE_TYPE;
|
|
1860
|
-
}
|
|
1861
|
-
function isConcurrentMode(object) {
|
|
1862
|
-
return typeOf(object) === REACT_CONCURRENT_MODE_TYPE;
|
|
1863
|
-
}
|
|
1864
|
-
function isContextConsumer(object) {
|
|
1865
|
-
return typeOf(object) === REACT_CONTEXT_TYPE;
|
|
1866
|
-
}
|
|
1867
|
-
function isContextProvider(object) {
|
|
1868
|
-
return typeOf(object) === REACT_PROVIDER_TYPE;
|
|
1869
|
-
}
|
|
1870
|
-
function isElement(object) {
|
|
1871
|
-
return typeof object === 'object' && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;
|
|
1872
|
-
}
|
|
1873
|
-
function isForwardRef(object) {
|
|
1874
|
-
return typeOf(object) === REACT_FORWARD_REF_TYPE;
|
|
1875
|
-
}
|
|
1876
|
-
function isFragment(object) {
|
|
1877
|
-
return typeOf(object) === REACT_FRAGMENT_TYPE;
|
|
1878
|
-
}
|
|
1879
|
-
function isLazy(object) {
|
|
1880
|
-
return typeOf(object) === REACT_LAZY_TYPE;
|
|
1881
|
-
}
|
|
1882
|
-
function isMemo(object) {
|
|
1883
|
-
return typeOf(object) === REACT_MEMO_TYPE;
|
|
1884
|
-
}
|
|
1885
|
-
function isPortal(object) {
|
|
1886
|
-
return typeOf(object) === REACT_PORTAL_TYPE;
|
|
1887
|
-
}
|
|
1888
|
-
function isProfiler(object) {
|
|
1889
|
-
return typeOf(object) === REACT_PROFILER_TYPE;
|
|
1890
|
-
}
|
|
1891
|
-
function isStrictMode(object) {
|
|
1892
|
-
return typeOf(object) === REACT_STRICT_MODE_TYPE;
|
|
1893
|
-
}
|
|
1894
|
-
function isSuspense(object) {
|
|
1895
|
-
return typeOf(object) === REACT_SUSPENSE_TYPE;
|
|
1896
|
-
}
|
|
1897
|
-
|
|
1898
|
-
reactIs_development.AsyncMode = AsyncMode;
|
|
1899
|
-
reactIs_development.ConcurrentMode = ConcurrentMode;
|
|
1900
|
-
reactIs_development.ContextConsumer = ContextConsumer;
|
|
1901
|
-
reactIs_development.ContextProvider = ContextProvider;
|
|
1902
|
-
reactIs_development.Element = Element;
|
|
1903
|
-
reactIs_development.ForwardRef = ForwardRef;
|
|
1904
|
-
reactIs_development.Fragment = Fragment;
|
|
1905
|
-
reactIs_development.Lazy = Lazy;
|
|
1906
|
-
reactIs_development.Memo = Memo;
|
|
1907
|
-
reactIs_development.Portal = Portal;
|
|
1908
|
-
reactIs_development.Profiler = Profiler;
|
|
1909
|
-
reactIs_development.StrictMode = StrictMode;
|
|
1910
|
-
reactIs_development.Suspense = Suspense;
|
|
1911
|
-
reactIs_development.isAsyncMode = isAsyncMode;
|
|
1912
|
-
reactIs_development.isConcurrentMode = isConcurrentMode;
|
|
1913
|
-
reactIs_development.isContextConsumer = isContextConsumer;
|
|
1914
|
-
reactIs_development.isContextProvider = isContextProvider;
|
|
1915
|
-
reactIs_development.isElement = isElement;
|
|
1916
|
-
reactIs_development.isForwardRef = isForwardRef;
|
|
1917
|
-
reactIs_development.isFragment = isFragment;
|
|
1918
|
-
reactIs_development.isLazy = isLazy;
|
|
1919
|
-
reactIs_development.isMemo = isMemo;
|
|
1920
|
-
reactIs_development.isPortal = isPortal;
|
|
1921
|
-
reactIs_development.isProfiler = isProfiler;
|
|
1922
|
-
reactIs_development.isStrictMode = isStrictMode;
|
|
1923
|
-
reactIs_development.isSuspense = isSuspense;
|
|
1924
|
-
reactIs_development.isValidElementType = isValidElementType;
|
|
1925
|
-
reactIs_development.typeOf = typeOf;
|
|
1926
|
-
})();
|
|
1927
|
-
}
|
|
1928
|
-
return reactIs_development;
|
|
1929
|
-
}
|
|
1930
|
-
|
|
1931
|
-
var hasRequiredReactIs;
|
|
1932
|
-
|
|
1933
|
-
function requireReactIs () {
|
|
1934
|
-
if (hasRequiredReactIs) return reactIs.exports;
|
|
1935
|
-
hasRequiredReactIs = 1;
|
|
1936
|
-
(function (module) {
|
|
1937
|
-
|
|
1938
|
-
if (process.env.NODE_ENV === 'production') {
|
|
1939
|
-
module.exports = requireReactIs_production_min();
|
|
1940
|
-
} else {
|
|
1941
|
-
module.exports = requireReactIs_development();
|
|
1942
|
-
}
|
|
1943
|
-
} (reactIs));
|
|
1944
|
-
return reactIs.exports;
|
|
1945
|
-
}
|
|
1946
|
-
|
|
1947
|
-
/*
|
|
1948
|
-
object-assign
|
|
1949
|
-
(c) Sindre Sorhus
|
|
1950
|
-
@license MIT
|
|
1951
|
-
*/
|
|
1952
|
-
|
|
1953
|
-
var objectAssign;
|
|
1954
|
-
var hasRequiredObjectAssign;
|
|
1955
|
-
|
|
1956
|
-
function requireObjectAssign () {
|
|
1957
|
-
if (hasRequiredObjectAssign) return objectAssign;
|
|
1958
|
-
hasRequiredObjectAssign = 1;
|
|
1959
|
-
/* eslint-disable no-unused-vars */
|
|
1960
|
-
var getOwnPropertySymbols = Object.getOwnPropertySymbols;
|
|
1961
|
-
var hasOwnProperty = Object.prototype.hasOwnProperty;
|
|
1962
|
-
var propIsEnumerable = Object.prototype.propertyIsEnumerable;
|
|
1963
|
-
|
|
1964
|
-
function toObject(val) {
|
|
1965
|
-
if (val === null || val === undefined) {
|
|
1966
|
-
throw new TypeError('Object.assign cannot be called with null or undefined');
|
|
1967
|
-
}
|
|
1968
|
-
|
|
1969
|
-
return Object(val);
|
|
1970
|
-
}
|
|
1971
|
-
|
|
1972
|
-
function shouldUseNative() {
|
|
1973
|
-
try {
|
|
1974
|
-
if (!Object.assign) {
|
|
1975
|
-
return false;
|
|
1976
|
-
}
|
|
1977
|
-
|
|
1978
|
-
// Detect buggy property enumeration order in older V8 versions.
|
|
1979
|
-
|
|
1980
|
-
// https://bugs.chromium.org/p/v8/issues/detail?id=4118
|
|
1981
|
-
var test1 = new String('abc'); // eslint-disable-line no-new-wrappers
|
|
1982
|
-
test1[5] = 'de';
|
|
1983
|
-
if (Object.getOwnPropertyNames(test1)[0] === '5') {
|
|
1984
|
-
return false;
|
|
1985
|
-
}
|
|
1986
|
-
|
|
1987
|
-
// https://bugs.chromium.org/p/v8/issues/detail?id=3056
|
|
1988
|
-
var test2 = {};
|
|
1989
|
-
for (var i = 0; i < 10; i++) {
|
|
1990
|
-
test2['_' + String.fromCharCode(i)] = i;
|
|
1991
|
-
}
|
|
1992
|
-
var order2 = Object.getOwnPropertyNames(test2).map(function (n) {
|
|
1993
|
-
return test2[n];
|
|
1994
|
-
});
|
|
1995
|
-
if (order2.join('') !== '0123456789') {
|
|
1996
|
-
return false;
|
|
1997
|
-
}
|
|
1998
|
-
|
|
1999
|
-
// https://bugs.chromium.org/p/v8/issues/detail?id=3056
|
|
2000
|
-
var test3 = {};
|
|
2001
|
-
'abcdefghijklmnopqrst'.split('').forEach(function (letter) {
|
|
2002
|
-
test3[letter] = letter;
|
|
2003
|
-
});
|
|
2004
|
-
if (Object.keys(Object.assign({}, test3)).join('') !==
|
|
2005
|
-
'abcdefghijklmnopqrst') {
|
|
2006
|
-
return false;
|
|
2007
|
-
}
|
|
2008
|
-
|
|
2009
|
-
return true;
|
|
2010
|
-
} catch (err) {
|
|
2011
|
-
// We don't expect any of the above to throw, but better to be safe.
|
|
2012
|
-
return false;
|
|
2013
|
-
}
|
|
2014
|
-
}
|
|
2015
|
-
|
|
2016
|
-
objectAssign = shouldUseNative() ? Object.assign : function (target, source) {
|
|
2017
|
-
var from;
|
|
2018
|
-
var to = toObject(target);
|
|
2019
|
-
var symbols;
|
|
2020
|
-
|
|
2021
|
-
for (var s = 1; s < arguments.length; s++) {
|
|
2022
|
-
from = Object(arguments[s]);
|
|
2023
|
-
|
|
2024
|
-
for (var key in from) {
|
|
2025
|
-
if (hasOwnProperty.call(from, key)) {
|
|
2026
|
-
to[key] = from[key];
|
|
2027
|
-
}
|
|
2028
|
-
}
|
|
2029
|
-
|
|
2030
|
-
if (getOwnPropertySymbols) {
|
|
2031
|
-
symbols = getOwnPropertySymbols(from);
|
|
2032
|
-
for (var i = 0; i < symbols.length; i++) {
|
|
2033
|
-
if (propIsEnumerable.call(from, symbols[i])) {
|
|
2034
|
-
to[symbols[i]] = from[symbols[i]];
|
|
2035
|
-
}
|
|
2036
|
-
}
|
|
2037
|
-
}
|
|
2038
|
-
}
|
|
2039
|
-
|
|
2040
|
-
return to;
|
|
2041
|
-
};
|
|
2042
|
-
return objectAssign;
|
|
2043
|
-
}
|
|
2044
|
-
|
|
2045
|
-
/**
|
|
2046
|
-
* Copyright (c) 2013-present, Facebook, Inc.
|
|
2047
|
-
*
|
|
2048
|
-
* This source code is licensed under the MIT license found in the
|
|
2049
|
-
* LICENSE file in the root directory of this source tree.
|
|
2050
|
-
*/
|
|
2051
|
-
|
|
2052
|
-
var ReactPropTypesSecret_1;
|
|
2053
|
-
var hasRequiredReactPropTypesSecret;
|
|
2054
|
-
|
|
2055
|
-
function requireReactPropTypesSecret () {
|
|
2056
|
-
if (hasRequiredReactPropTypesSecret) return ReactPropTypesSecret_1;
|
|
2057
|
-
hasRequiredReactPropTypesSecret = 1;
|
|
2058
|
-
|
|
2059
|
-
var ReactPropTypesSecret = 'SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED';
|
|
2060
|
-
|
|
2061
|
-
ReactPropTypesSecret_1 = ReactPropTypesSecret;
|
|
2062
|
-
return ReactPropTypesSecret_1;
|
|
2063
|
-
}
|
|
2064
|
-
|
|
2065
|
-
var has;
|
|
2066
|
-
var hasRequiredHas;
|
|
2067
|
-
|
|
2068
|
-
function requireHas () {
|
|
2069
|
-
if (hasRequiredHas) return has;
|
|
2070
|
-
hasRequiredHas = 1;
|
|
2071
|
-
has = Function.call.bind(Object.prototype.hasOwnProperty);
|
|
2072
|
-
return has;
|
|
2073
|
-
}
|
|
2074
|
-
|
|
2075
|
-
/**
|
|
2076
|
-
* Copyright (c) 2013-present, Facebook, Inc.
|
|
2077
|
-
*
|
|
2078
|
-
* This source code is licensed under the MIT license found in the
|
|
2079
|
-
* LICENSE file in the root directory of this source tree.
|
|
2080
|
-
*/
|
|
2081
|
-
|
|
2082
|
-
var checkPropTypes_1;
|
|
2083
|
-
var hasRequiredCheckPropTypes;
|
|
2084
|
-
|
|
2085
|
-
function requireCheckPropTypes () {
|
|
2086
|
-
if (hasRequiredCheckPropTypes) return checkPropTypes_1;
|
|
2087
|
-
hasRequiredCheckPropTypes = 1;
|
|
2088
|
-
|
|
2089
|
-
var printWarning = function() {};
|
|
2090
|
-
|
|
2091
|
-
if (process.env.NODE_ENV !== 'production') {
|
|
2092
|
-
var ReactPropTypesSecret = requireReactPropTypesSecret();
|
|
2093
|
-
var loggedTypeFailures = {};
|
|
2094
|
-
var has = requireHas();
|
|
2095
|
-
|
|
2096
|
-
printWarning = function(text) {
|
|
2097
|
-
var message = 'Warning: ' + text;
|
|
2098
|
-
if (typeof console !== 'undefined') {
|
|
2099
|
-
console.error(message);
|
|
2100
|
-
}
|
|
2101
|
-
try {
|
|
2102
|
-
// --- Welcome to debugging React ---
|
|
2103
|
-
// This error was thrown as a convenience so that you can use this stack
|
|
2104
|
-
// to find the callsite that caused this warning to fire.
|
|
2105
|
-
throw new Error(message);
|
|
2106
|
-
} catch (x) { /**/ }
|
|
2107
|
-
};
|
|
2108
|
-
}
|
|
2109
|
-
|
|
2110
|
-
/**
|
|
2111
|
-
* Assert that the values match with the type specs.
|
|
2112
|
-
* Error messages are memorized and will only be shown once.
|
|
2113
|
-
*
|
|
2114
|
-
* @param {object} typeSpecs Map of name to a ReactPropType
|
|
2115
|
-
* @param {object} values Runtime values that need to be type-checked
|
|
2116
|
-
* @param {string} location e.g. "prop", "context", "child context"
|
|
2117
|
-
* @param {string} componentName Name of the component for error messages.
|
|
2118
|
-
* @param {?Function} getStack Returns the component stack.
|
|
2119
|
-
* @private
|
|
2120
|
-
*/
|
|
2121
|
-
function checkPropTypes(typeSpecs, values, location, componentName, getStack) {
|
|
2122
|
-
if (process.env.NODE_ENV !== 'production') {
|
|
2123
|
-
for (var typeSpecName in typeSpecs) {
|
|
2124
|
-
if (has(typeSpecs, typeSpecName)) {
|
|
2125
|
-
var error;
|
|
2126
|
-
// Prop type validation may throw. In case they do, we don't want to
|
|
2127
|
-
// fail the render phase where it didn't fail before. So we log it.
|
|
2128
|
-
// After these have been cleaned up, we'll let them throw.
|
|
2129
|
-
try {
|
|
2130
|
-
// This is intentionally an invariant that gets caught. It's the same
|
|
2131
|
-
// behavior as without this statement except with a better message.
|
|
2132
|
-
if (typeof typeSpecs[typeSpecName] !== 'function') {
|
|
2133
|
-
var err = Error(
|
|
2134
|
-
(componentName || 'React class') + ': ' + location + ' type `' + typeSpecName + '` is invalid; ' +
|
|
2135
|
-
'it must be a function, usually from the `prop-types` package, but received `' + typeof typeSpecs[typeSpecName] + '`.' +
|
|
2136
|
-
'This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.'
|
|
2137
|
-
);
|
|
2138
|
-
err.name = 'Invariant Violation';
|
|
2139
|
-
throw err;
|
|
2140
|
-
}
|
|
2141
|
-
error = typeSpecs[typeSpecName](values, typeSpecName, componentName, location, null, ReactPropTypesSecret);
|
|
2142
|
-
} catch (ex) {
|
|
2143
|
-
error = ex;
|
|
2144
|
-
}
|
|
2145
|
-
if (error && !(error instanceof Error)) {
|
|
2146
|
-
printWarning(
|
|
2147
|
-
(componentName || 'React class') + ': type specification of ' +
|
|
2148
|
-
location + ' `' + typeSpecName + '` is invalid; the type checker ' +
|
|
2149
|
-
'function must return `null` or an `Error` but returned a ' + typeof error + '. ' +
|
|
2150
|
-
'You may have forgotten to pass an argument to the type checker ' +
|
|
2151
|
-
'creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and ' +
|
|
2152
|
-
'shape all require an argument).'
|
|
2153
|
-
);
|
|
2154
|
-
}
|
|
2155
|
-
if (error instanceof Error && !(error.message in loggedTypeFailures)) {
|
|
2156
|
-
// Only monitor this failure once because there tends to be a lot of the
|
|
2157
|
-
// same error.
|
|
2158
|
-
loggedTypeFailures[error.message] = true;
|
|
2159
|
-
|
|
2160
|
-
var stack = getStack ? getStack() : '';
|
|
2161
|
-
|
|
2162
|
-
printWarning(
|
|
2163
|
-
'Failed ' + location + ' type: ' + error.message + (stack != null ? stack : '')
|
|
2164
|
-
);
|
|
2165
|
-
}
|
|
2166
|
-
}
|
|
2167
|
-
}
|
|
2168
|
-
}
|
|
2169
|
-
}
|
|
2170
|
-
|
|
2171
|
-
/**
|
|
2172
|
-
* Resets warning cache when testing.
|
|
2173
|
-
*
|
|
2174
|
-
* @private
|
|
2175
|
-
*/
|
|
2176
|
-
checkPropTypes.resetWarningCache = function() {
|
|
2177
|
-
if (process.env.NODE_ENV !== 'production') {
|
|
2178
|
-
loggedTypeFailures = {};
|
|
2179
|
-
}
|
|
2180
|
-
};
|
|
2181
|
-
|
|
2182
|
-
checkPropTypes_1 = checkPropTypes;
|
|
2183
|
-
return checkPropTypes_1;
|
|
2184
|
-
}
|
|
2185
|
-
|
|
2186
|
-
/**
|
|
2187
|
-
* Copyright (c) 2013-present, Facebook, Inc.
|
|
2188
|
-
*
|
|
2189
|
-
* This source code is licensed under the MIT license found in the
|
|
2190
|
-
* LICENSE file in the root directory of this source tree.
|
|
2191
|
-
*/
|
|
2192
|
-
|
|
2193
|
-
var factoryWithTypeCheckers;
|
|
2194
|
-
var hasRequiredFactoryWithTypeCheckers;
|
|
2195
|
-
|
|
2196
|
-
function requireFactoryWithTypeCheckers () {
|
|
2197
|
-
if (hasRequiredFactoryWithTypeCheckers) return factoryWithTypeCheckers;
|
|
2198
|
-
hasRequiredFactoryWithTypeCheckers = 1;
|
|
2199
|
-
|
|
2200
|
-
var ReactIs = requireReactIs();
|
|
2201
|
-
var assign = requireObjectAssign();
|
|
2202
|
-
|
|
2203
|
-
var ReactPropTypesSecret = requireReactPropTypesSecret();
|
|
2204
|
-
var has = requireHas();
|
|
2205
|
-
var checkPropTypes = requireCheckPropTypes();
|
|
2206
|
-
|
|
2207
|
-
var printWarning = function() {};
|
|
2208
|
-
|
|
2209
|
-
if (process.env.NODE_ENV !== 'production') {
|
|
2210
|
-
printWarning = function(text) {
|
|
2211
|
-
var message = 'Warning: ' + text;
|
|
2212
|
-
if (typeof console !== 'undefined') {
|
|
2213
|
-
console.error(message);
|
|
2214
|
-
}
|
|
2215
|
-
try {
|
|
2216
|
-
// --- Welcome to debugging React ---
|
|
2217
|
-
// This error was thrown as a convenience so that you can use this stack
|
|
2218
|
-
// to find the callsite that caused this warning to fire.
|
|
2219
|
-
throw new Error(message);
|
|
2220
|
-
} catch (x) {}
|
|
2221
|
-
};
|
|
2222
|
-
}
|
|
2223
|
-
|
|
2224
|
-
function emptyFunctionThatReturnsNull() {
|
|
2225
|
-
return null;
|
|
2226
|
-
}
|
|
2227
|
-
|
|
2228
|
-
factoryWithTypeCheckers = function(isValidElement, throwOnDirectAccess) {
|
|
2229
|
-
/* global Symbol */
|
|
2230
|
-
var ITERATOR_SYMBOL = typeof Symbol === 'function' && Symbol.iterator;
|
|
2231
|
-
var FAUX_ITERATOR_SYMBOL = '@@iterator'; // Before Symbol spec.
|
|
2232
|
-
|
|
2233
|
-
/**
|
|
2234
|
-
* Returns the iterator method function contained on the iterable object.
|
|
2235
|
-
*
|
|
2236
|
-
* Be sure to invoke the function with the iterable as context:
|
|
2237
|
-
*
|
|
2238
|
-
* var iteratorFn = getIteratorFn(myIterable);
|
|
2239
|
-
* if (iteratorFn) {
|
|
2240
|
-
* var iterator = iteratorFn.call(myIterable);
|
|
2241
|
-
* ...
|
|
2242
|
-
* }
|
|
2243
|
-
*
|
|
2244
|
-
* @param {?object} maybeIterable
|
|
2245
|
-
* @return {?function}
|
|
2246
|
-
*/
|
|
2247
|
-
function getIteratorFn(maybeIterable) {
|
|
2248
|
-
var iteratorFn = maybeIterable && (ITERATOR_SYMBOL && maybeIterable[ITERATOR_SYMBOL] || maybeIterable[FAUX_ITERATOR_SYMBOL]);
|
|
2249
|
-
if (typeof iteratorFn === 'function') {
|
|
2250
|
-
return iteratorFn;
|
|
2251
|
-
}
|
|
2252
|
-
}
|
|
2253
|
-
|
|
2254
|
-
/**
|
|
2255
|
-
* Collection of methods that allow declaration and validation of props that are
|
|
2256
|
-
* supplied to React components. Example usage:
|
|
2257
|
-
*
|
|
2258
|
-
* var Props = require('ReactPropTypes');
|
|
2259
|
-
* var MyArticle = React.createClass({
|
|
2260
|
-
* propTypes: {
|
|
2261
|
-
* // An optional string prop named "description".
|
|
2262
|
-
* description: Props.string,
|
|
2263
|
-
*
|
|
2264
|
-
* // A required enum prop named "category".
|
|
2265
|
-
* category: Props.oneOf(['News','Photos']).isRequired,
|
|
2266
|
-
*
|
|
2267
|
-
* // A prop named "dialog" that requires an instance of Dialog.
|
|
2268
|
-
* dialog: Props.instanceOf(Dialog).isRequired
|
|
2269
|
-
* },
|
|
2270
|
-
* render: function() { ... }
|
|
2271
|
-
* });
|
|
2272
|
-
*
|
|
2273
|
-
* A more formal specification of how these methods are used:
|
|
2274
|
-
*
|
|
2275
|
-
* type := array|bool|func|object|number|string|oneOf([...])|instanceOf(...)
|
|
2276
|
-
* decl := ReactPropTypes.{type}(.isRequired)?
|
|
2277
|
-
*
|
|
2278
|
-
* Each and every declaration produces a function with the same signature. This
|
|
2279
|
-
* allows the creation of custom validation functions. For example:
|
|
2280
|
-
*
|
|
2281
|
-
* var MyLink = React.createClass({
|
|
2282
|
-
* propTypes: {
|
|
2283
|
-
* // An optional string or URI prop named "href".
|
|
2284
|
-
* href: function(props, propName, componentName) {
|
|
2285
|
-
* var propValue = props[propName];
|
|
2286
|
-
* if (propValue != null && typeof propValue !== 'string' &&
|
|
2287
|
-
* !(propValue instanceof URI)) {
|
|
2288
|
-
* return new Error(
|
|
2289
|
-
* 'Expected a string or an URI for ' + propName + ' in ' +
|
|
2290
|
-
* componentName
|
|
2291
|
-
* );
|
|
2292
|
-
* }
|
|
2293
|
-
* }
|
|
2294
|
-
* },
|
|
2295
|
-
* render: function() {...}
|
|
2296
|
-
* });
|
|
2297
|
-
*
|
|
2298
|
-
* @internal
|
|
2299
|
-
*/
|
|
2300
|
-
|
|
2301
|
-
var ANONYMOUS = '<<anonymous>>';
|
|
2302
|
-
|
|
2303
|
-
// Important!
|
|
2304
|
-
// Keep this list in sync with production version in `./factoryWithThrowingShims.js`.
|
|
2305
|
-
var ReactPropTypes = {
|
|
2306
|
-
array: createPrimitiveTypeChecker('array'),
|
|
2307
|
-
bigint: createPrimitiveTypeChecker('bigint'),
|
|
2308
|
-
bool: createPrimitiveTypeChecker('boolean'),
|
|
2309
|
-
func: createPrimitiveTypeChecker('function'),
|
|
2310
|
-
number: createPrimitiveTypeChecker('number'),
|
|
2311
|
-
object: createPrimitiveTypeChecker('object'),
|
|
2312
|
-
string: createPrimitiveTypeChecker('string'),
|
|
2313
|
-
symbol: createPrimitiveTypeChecker('symbol'),
|
|
2314
|
-
|
|
2315
|
-
any: createAnyTypeChecker(),
|
|
2316
|
-
arrayOf: createArrayOfTypeChecker,
|
|
2317
|
-
element: createElementTypeChecker(),
|
|
2318
|
-
elementType: createElementTypeTypeChecker(),
|
|
2319
|
-
instanceOf: createInstanceTypeChecker,
|
|
2320
|
-
node: createNodeChecker(),
|
|
2321
|
-
objectOf: createObjectOfTypeChecker,
|
|
2322
|
-
oneOf: createEnumTypeChecker,
|
|
2323
|
-
oneOfType: createUnionTypeChecker,
|
|
2324
|
-
shape: createShapeTypeChecker,
|
|
2325
|
-
exact: createStrictShapeTypeChecker,
|
|
2326
|
-
};
|
|
2327
|
-
|
|
2328
|
-
/**
|
|
2329
|
-
* inlined Object.is polyfill to avoid requiring consumers ship their own
|
|
2330
|
-
* https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is
|
|
2331
|
-
*/
|
|
2332
|
-
/*eslint-disable no-self-compare*/
|
|
2333
|
-
function is(x, y) {
|
|
2334
|
-
// SameValue algorithm
|
|
2335
|
-
if (x === y) {
|
|
2336
|
-
// Steps 1-5, 7-10
|
|
2337
|
-
// Steps 6.b-6.e: +0 != -0
|
|
2338
|
-
return x !== 0 || 1 / x === 1 / y;
|
|
2339
|
-
} else {
|
|
2340
|
-
// Step 6.a: NaN == NaN
|
|
2341
|
-
return x !== x && y !== y;
|
|
2342
|
-
}
|
|
2343
|
-
}
|
|
2344
|
-
/*eslint-enable no-self-compare*/
|
|
2345
|
-
|
|
2346
|
-
/**
|
|
2347
|
-
* We use an Error-like object for backward compatibility as people may call
|
|
2348
|
-
* PropTypes directly and inspect their output. However, we don't use real
|
|
2349
|
-
* Errors anymore. We don't inspect their stack anyway, and creating them
|
|
2350
|
-
* is prohibitively expensive if they are created too often, such as what
|
|
2351
|
-
* happens in oneOfType() for any type before the one that matched.
|
|
2352
|
-
*/
|
|
2353
|
-
function PropTypeError(message, data) {
|
|
2354
|
-
this.message = message;
|
|
2355
|
-
this.data = data && typeof data === 'object' ? data: {};
|
|
2356
|
-
this.stack = '';
|
|
2357
|
-
}
|
|
2358
|
-
// Make `instanceof Error` still work for returned errors.
|
|
2359
|
-
PropTypeError.prototype = Error.prototype;
|
|
2360
|
-
|
|
2361
|
-
function createChainableTypeChecker(validate) {
|
|
2362
|
-
if (process.env.NODE_ENV !== 'production') {
|
|
2363
|
-
var manualPropTypeCallCache = {};
|
|
2364
|
-
var manualPropTypeWarningCount = 0;
|
|
2365
|
-
}
|
|
2366
|
-
function checkType(isRequired, props, propName, componentName, location, propFullName, secret) {
|
|
2367
|
-
componentName = componentName || ANONYMOUS;
|
|
2368
|
-
propFullName = propFullName || propName;
|
|
2369
|
-
|
|
2370
|
-
if (secret !== ReactPropTypesSecret) {
|
|
2371
|
-
if (throwOnDirectAccess) {
|
|
2372
|
-
// New behavior only for users of `prop-types` package
|
|
2373
|
-
var err = new Error(
|
|
2374
|
-
'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +
|
|
2375
|
-
'Use `PropTypes.checkPropTypes()` to call them. ' +
|
|
2376
|
-
'Read more at http://fb.me/use-check-prop-types'
|
|
2377
|
-
);
|
|
2378
|
-
err.name = 'Invariant Violation';
|
|
2379
|
-
throw err;
|
|
2380
|
-
} else if (process.env.NODE_ENV !== 'production' && typeof console !== 'undefined') {
|
|
2381
|
-
// Old behavior for people using React.PropTypes
|
|
2382
|
-
var cacheKey = componentName + ':' + propName;
|
|
2383
|
-
if (
|
|
2384
|
-
!manualPropTypeCallCache[cacheKey] &&
|
|
2385
|
-
// Avoid spamming the console because they are often not actionable except for lib authors
|
|
2386
|
-
manualPropTypeWarningCount < 3
|
|
2387
|
-
) {
|
|
2388
|
-
printWarning(
|
|
2389
|
-
'You are manually calling a React.PropTypes validation ' +
|
|
2390
|
-
'function for the `' + propFullName + '` prop on `' + componentName + '`. This is deprecated ' +
|
|
2391
|
-
'and will throw in the standalone `prop-types` package. ' +
|
|
2392
|
-
'You may be seeing this warning due to a third-party PropTypes ' +
|
|
2393
|
-
'library. See https://fb.me/react-warning-dont-call-proptypes ' + 'for details.'
|
|
2394
|
-
);
|
|
2395
|
-
manualPropTypeCallCache[cacheKey] = true;
|
|
2396
|
-
manualPropTypeWarningCount++;
|
|
2397
|
-
}
|
|
2398
|
-
}
|
|
2399
|
-
}
|
|
2400
|
-
if (props[propName] == null) {
|
|
2401
|
-
if (isRequired) {
|
|
2402
|
-
if (props[propName] === null) {
|
|
2403
|
-
return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required ' + ('in `' + componentName + '`, but its value is `null`.'));
|
|
2404
|
-
}
|
|
2405
|
-
return new PropTypeError('The ' + location + ' `' + propFullName + '` is marked as required in ' + ('`' + componentName + '`, but its value is `undefined`.'));
|
|
2406
|
-
}
|
|
2407
|
-
return null;
|
|
2408
|
-
} else {
|
|
2409
|
-
return validate(props, propName, componentName, location, propFullName);
|
|
2410
|
-
}
|
|
2411
|
-
}
|
|
2412
|
-
|
|
2413
|
-
var chainedCheckType = checkType.bind(null, false);
|
|
2414
|
-
chainedCheckType.isRequired = checkType.bind(null, true);
|
|
2415
|
-
|
|
2416
|
-
return chainedCheckType;
|
|
2417
|
-
}
|
|
2418
|
-
|
|
2419
|
-
function createPrimitiveTypeChecker(expectedType) {
|
|
2420
|
-
function validate(props, propName, componentName, location, propFullName, secret) {
|
|
2421
|
-
var propValue = props[propName];
|
|
2422
|
-
var propType = getPropType(propValue);
|
|
2423
|
-
if (propType !== expectedType) {
|
|
2424
|
-
// `propValue` being instance of, say, date/regexp, pass the 'object'
|
|
2425
|
-
// check, but we can offer a more precise error message here rather than
|
|
2426
|
-
// 'of type `object`'.
|
|
2427
|
-
var preciseType = getPreciseType(propValue);
|
|
2428
|
-
|
|
2429
|
-
return new PropTypeError(
|
|
2430
|
-
'Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + preciseType + '` supplied to `' + componentName + '`, expected ') + ('`' + expectedType + '`.'),
|
|
2431
|
-
{expectedType: expectedType}
|
|
2432
|
-
);
|
|
2433
|
-
}
|
|
2434
|
-
return null;
|
|
2435
|
-
}
|
|
2436
|
-
return createChainableTypeChecker(validate);
|
|
2437
|
-
}
|
|
2438
|
-
|
|
2439
|
-
function createAnyTypeChecker() {
|
|
2440
|
-
return createChainableTypeChecker(emptyFunctionThatReturnsNull);
|
|
2441
|
-
}
|
|
2442
|
-
|
|
2443
|
-
function createArrayOfTypeChecker(typeChecker) {
|
|
2444
|
-
function validate(props, propName, componentName, location, propFullName) {
|
|
2445
|
-
if (typeof typeChecker !== 'function') {
|
|
2446
|
-
return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside arrayOf.');
|
|
2447
|
-
}
|
|
2448
|
-
var propValue = props[propName];
|
|
2449
|
-
if (!Array.isArray(propValue)) {
|
|
2450
|
-
var propType = getPropType(propValue);
|
|
2451
|
-
return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an array.'));
|
|
2452
|
-
}
|
|
2453
|
-
for (var i = 0; i < propValue.length; i++) {
|
|
2454
|
-
var error = typeChecker(propValue, i, componentName, location, propFullName + '[' + i + ']', ReactPropTypesSecret);
|
|
2455
|
-
if (error instanceof Error) {
|
|
2456
|
-
return error;
|
|
2457
|
-
}
|
|
2458
|
-
}
|
|
2459
|
-
return null;
|
|
2460
|
-
}
|
|
2461
|
-
return createChainableTypeChecker(validate);
|
|
2462
|
-
}
|
|
2463
|
-
|
|
2464
|
-
function createElementTypeChecker() {
|
|
2465
|
-
function validate(props, propName, componentName, location, propFullName) {
|
|
2466
|
-
var propValue = props[propName];
|
|
2467
|
-
if (!isValidElement(propValue)) {
|
|
2468
|
-
var propType = getPropType(propValue);
|
|
2469
|
-
return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement.'));
|
|
2470
|
-
}
|
|
2471
|
-
return null;
|
|
2472
|
-
}
|
|
2473
|
-
return createChainableTypeChecker(validate);
|
|
2474
|
-
}
|
|
2475
|
-
|
|
2476
|
-
function createElementTypeTypeChecker() {
|
|
2477
|
-
function validate(props, propName, componentName, location, propFullName) {
|
|
2478
|
-
var propValue = props[propName];
|
|
2479
|
-
if (!ReactIs.isValidElementType(propValue)) {
|
|
2480
|
-
var propType = getPropType(propValue);
|
|
2481
|
-
return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected a single ReactElement type.'));
|
|
2482
|
-
}
|
|
2483
|
-
return null;
|
|
2484
|
-
}
|
|
2485
|
-
return createChainableTypeChecker(validate);
|
|
2486
|
-
}
|
|
2487
|
-
|
|
2488
|
-
function createInstanceTypeChecker(expectedClass) {
|
|
2489
|
-
function validate(props, propName, componentName, location, propFullName) {
|
|
2490
|
-
if (!(props[propName] instanceof expectedClass)) {
|
|
2491
|
-
var expectedClassName = expectedClass.name || ANONYMOUS;
|
|
2492
|
-
var actualClassName = getClassName(props[propName]);
|
|
2493
|
-
return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + actualClassName + '` supplied to `' + componentName + '`, expected ') + ('instance of `' + expectedClassName + '`.'));
|
|
2494
|
-
}
|
|
2495
|
-
return null;
|
|
2496
|
-
}
|
|
2497
|
-
return createChainableTypeChecker(validate);
|
|
2498
|
-
}
|
|
2499
|
-
|
|
2500
|
-
function createEnumTypeChecker(expectedValues) {
|
|
2501
|
-
if (!Array.isArray(expectedValues)) {
|
|
2502
|
-
if (process.env.NODE_ENV !== 'production') {
|
|
2503
|
-
if (arguments.length > 1) {
|
|
2504
|
-
printWarning(
|
|
2505
|
-
'Invalid arguments supplied to oneOf, expected an array, got ' + arguments.length + ' arguments. ' +
|
|
2506
|
-
'A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).'
|
|
2507
|
-
);
|
|
2508
|
-
} else {
|
|
2509
|
-
printWarning('Invalid argument supplied to oneOf, expected an array.');
|
|
2510
|
-
}
|
|
2511
|
-
}
|
|
2512
|
-
return emptyFunctionThatReturnsNull;
|
|
2513
|
-
}
|
|
2514
|
-
|
|
2515
|
-
function validate(props, propName, componentName, location, propFullName) {
|
|
2516
|
-
var propValue = props[propName];
|
|
2517
|
-
for (var i = 0; i < expectedValues.length; i++) {
|
|
2518
|
-
if (is(propValue, expectedValues[i])) {
|
|
2519
|
-
return null;
|
|
2520
|
-
}
|
|
2521
|
-
}
|
|
2522
|
-
|
|
2523
|
-
var valuesString = JSON.stringify(expectedValues, function replacer(key, value) {
|
|
2524
|
-
var type = getPreciseType(value);
|
|
2525
|
-
if (type === 'symbol') {
|
|
2526
|
-
return String(value);
|
|
2527
|
-
}
|
|
2528
|
-
return value;
|
|
2529
|
-
});
|
|
2530
|
-
return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of value `' + String(propValue) + '` ' + ('supplied to `' + componentName + '`, expected one of ' + valuesString + '.'));
|
|
2531
|
-
}
|
|
2532
|
-
return createChainableTypeChecker(validate);
|
|
2533
|
-
}
|
|
2534
|
-
|
|
2535
|
-
function createObjectOfTypeChecker(typeChecker) {
|
|
2536
|
-
function validate(props, propName, componentName, location, propFullName) {
|
|
2537
|
-
if (typeof typeChecker !== 'function') {
|
|
2538
|
-
return new PropTypeError('Property `' + propFullName + '` of component `' + componentName + '` has invalid PropType notation inside objectOf.');
|
|
2539
|
-
}
|
|
2540
|
-
var propValue = props[propName];
|
|
2541
|
-
var propType = getPropType(propValue);
|
|
2542
|
-
if (propType !== 'object') {
|
|
2543
|
-
return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type ' + ('`' + propType + '` supplied to `' + componentName + '`, expected an object.'));
|
|
2544
|
-
}
|
|
2545
|
-
for (var key in propValue) {
|
|
2546
|
-
if (has(propValue, key)) {
|
|
2547
|
-
var error = typeChecker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);
|
|
2548
|
-
if (error instanceof Error) {
|
|
2549
|
-
return error;
|
|
2550
|
-
}
|
|
2551
|
-
}
|
|
2552
|
-
}
|
|
2553
|
-
return null;
|
|
2554
|
-
}
|
|
2555
|
-
return createChainableTypeChecker(validate);
|
|
2556
|
-
}
|
|
2557
|
-
|
|
2558
|
-
function createUnionTypeChecker(arrayOfTypeCheckers) {
|
|
2559
|
-
if (!Array.isArray(arrayOfTypeCheckers)) {
|
|
2560
|
-
process.env.NODE_ENV !== 'production' ? printWarning('Invalid argument supplied to oneOfType, expected an instance of array.') : void 0;
|
|
2561
|
-
return emptyFunctionThatReturnsNull;
|
|
2562
|
-
}
|
|
2563
|
-
|
|
2564
|
-
for (var i = 0; i < arrayOfTypeCheckers.length; i++) {
|
|
2565
|
-
var checker = arrayOfTypeCheckers[i];
|
|
2566
|
-
if (typeof checker !== 'function') {
|
|
2567
|
-
printWarning(
|
|
2568
|
-
'Invalid argument supplied to oneOfType. Expected an array of check functions, but ' +
|
|
2569
|
-
'received ' + getPostfixForTypeWarning(checker) + ' at index ' + i + '.'
|
|
2570
|
-
);
|
|
2571
|
-
return emptyFunctionThatReturnsNull;
|
|
2572
|
-
}
|
|
2573
|
-
}
|
|
2574
|
-
|
|
2575
|
-
function validate(props, propName, componentName, location, propFullName) {
|
|
2576
|
-
var expectedTypes = [];
|
|
2577
|
-
for (var i = 0; i < arrayOfTypeCheckers.length; i++) {
|
|
2578
|
-
var checker = arrayOfTypeCheckers[i];
|
|
2579
|
-
var checkerResult = checker(props, propName, componentName, location, propFullName, ReactPropTypesSecret);
|
|
2580
|
-
if (checkerResult == null) {
|
|
2581
|
-
return null;
|
|
2582
|
-
}
|
|
2583
|
-
if (checkerResult.data && has(checkerResult.data, 'expectedType')) {
|
|
2584
|
-
expectedTypes.push(checkerResult.data.expectedType);
|
|
2585
|
-
}
|
|
2586
|
-
}
|
|
2587
|
-
var expectedTypesMessage = (expectedTypes.length > 0) ? ', expected one of type [' + expectedTypes.join(', ') + ']': '';
|
|
2588
|
-
return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`' + expectedTypesMessage + '.'));
|
|
2589
|
-
}
|
|
2590
|
-
return createChainableTypeChecker(validate);
|
|
2591
|
-
}
|
|
2592
|
-
|
|
2593
|
-
function createNodeChecker() {
|
|
2594
|
-
function validate(props, propName, componentName, location, propFullName) {
|
|
2595
|
-
if (!isNode(props[propName])) {
|
|
2596
|
-
return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` supplied to ' + ('`' + componentName + '`, expected a ReactNode.'));
|
|
2597
|
-
}
|
|
2598
|
-
return null;
|
|
2599
|
-
}
|
|
2600
|
-
return createChainableTypeChecker(validate);
|
|
2601
|
-
}
|
|
2602
|
-
|
|
2603
|
-
function invalidValidatorError(componentName, location, propFullName, key, type) {
|
|
2604
|
-
return new PropTypeError(
|
|
2605
|
-
(componentName || 'React class') + ': ' + location + ' type `' + propFullName + '.' + key + '` is invalid; ' +
|
|
2606
|
-
'it must be a function, usually from the `prop-types` package, but received `' + type + '`.'
|
|
2607
|
-
);
|
|
2608
|
-
}
|
|
2609
|
-
|
|
2610
|
-
function createShapeTypeChecker(shapeTypes) {
|
|
2611
|
-
function validate(props, propName, componentName, location, propFullName) {
|
|
2612
|
-
var propValue = props[propName];
|
|
2613
|
-
var propType = getPropType(propValue);
|
|
2614
|
-
if (propType !== 'object') {
|
|
2615
|
-
return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));
|
|
2616
|
-
}
|
|
2617
|
-
for (var key in shapeTypes) {
|
|
2618
|
-
var checker = shapeTypes[key];
|
|
2619
|
-
if (typeof checker !== 'function') {
|
|
2620
|
-
return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));
|
|
2621
|
-
}
|
|
2622
|
-
var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);
|
|
2623
|
-
if (error) {
|
|
2624
|
-
return error;
|
|
2625
|
-
}
|
|
2626
|
-
}
|
|
2627
|
-
return null;
|
|
2628
|
-
}
|
|
2629
|
-
return createChainableTypeChecker(validate);
|
|
2630
|
-
}
|
|
2631
|
-
|
|
2632
|
-
function createStrictShapeTypeChecker(shapeTypes) {
|
|
2633
|
-
function validate(props, propName, componentName, location, propFullName) {
|
|
2634
|
-
var propValue = props[propName];
|
|
2635
|
-
var propType = getPropType(propValue);
|
|
2636
|
-
if (propType !== 'object') {
|
|
2637
|
-
return new PropTypeError('Invalid ' + location + ' `' + propFullName + '` of type `' + propType + '` ' + ('supplied to `' + componentName + '`, expected `object`.'));
|
|
2638
|
-
}
|
|
2639
|
-
// We need to check all keys in case some are required but missing from props.
|
|
2640
|
-
var allKeys = assign({}, props[propName], shapeTypes);
|
|
2641
|
-
for (var key in allKeys) {
|
|
2642
|
-
var checker = shapeTypes[key];
|
|
2643
|
-
if (has(shapeTypes, key) && typeof checker !== 'function') {
|
|
2644
|
-
return invalidValidatorError(componentName, location, propFullName, key, getPreciseType(checker));
|
|
2645
|
-
}
|
|
2646
|
-
if (!checker) {
|
|
2647
|
-
return new PropTypeError(
|
|
2648
|
-
'Invalid ' + location + ' `' + propFullName + '` key `' + key + '` supplied to `' + componentName + '`.' +
|
|
2649
|
-
'\nBad object: ' + JSON.stringify(props[propName], null, ' ') +
|
|
2650
|
-
'\nValid keys: ' + JSON.stringify(Object.keys(shapeTypes), null, ' ')
|
|
2651
|
-
);
|
|
2652
|
-
}
|
|
2653
|
-
var error = checker(propValue, key, componentName, location, propFullName + '.' + key, ReactPropTypesSecret);
|
|
2654
|
-
if (error) {
|
|
2655
|
-
return error;
|
|
2656
|
-
}
|
|
2657
|
-
}
|
|
2658
|
-
return null;
|
|
2659
|
-
}
|
|
2660
|
-
|
|
2661
|
-
return createChainableTypeChecker(validate);
|
|
2662
|
-
}
|
|
2663
|
-
|
|
2664
|
-
function isNode(propValue) {
|
|
2665
|
-
switch (typeof propValue) {
|
|
2666
|
-
case 'number':
|
|
2667
|
-
case 'string':
|
|
2668
|
-
case 'undefined':
|
|
2669
|
-
return true;
|
|
2670
|
-
case 'boolean':
|
|
2671
|
-
return !propValue;
|
|
2672
|
-
case 'object':
|
|
2673
|
-
if (Array.isArray(propValue)) {
|
|
2674
|
-
return propValue.every(isNode);
|
|
2675
|
-
}
|
|
2676
|
-
if (propValue === null || isValidElement(propValue)) {
|
|
2677
|
-
return true;
|
|
2678
|
-
}
|
|
2679
|
-
|
|
2680
|
-
var iteratorFn = getIteratorFn(propValue);
|
|
2681
|
-
if (iteratorFn) {
|
|
2682
|
-
var iterator = iteratorFn.call(propValue);
|
|
2683
|
-
var step;
|
|
2684
|
-
if (iteratorFn !== propValue.entries) {
|
|
2685
|
-
while (!(step = iterator.next()).done) {
|
|
2686
|
-
if (!isNode(step.value)) {
|
|
2687
|
-
return false;
|
|
2688
|
-
}
|
|
2689
|
-
}
|
|
2690
|
-
} else {
|
|
2691
|
-
// Iterator will provide entry [k,v] tuples rather than values.
|
|
2692
|
-
while (!(step = iterator.next()).done) {
|
|
2693
|
-
var entry = step.value;
|
|
2694
|
-
if (entry) {
|
|
2695
|
-
if (!isNode(entry[1])) {
|
|
2696
|
-
return false;
|
|
2697
|
-
}
|
|
2698
|
-
}
|
|
2699
|
-
}
|
|
2700
|
-
}
|
|
2701
|
-
} else {
|
|
2702
|
-
return false;
|
|
2703
|
-
}
|
|
2704
|
-
|
|
2705
|
-
return true;
|
|
2706
|
-
default:
|
|
2707
|
-
return false;
|
|
2708
|
-
}
|
|
2709
|
-
}
|
|
2710
|
-
|
|
2711
|
-
function isSymbol(propType, propValue) {
|
|
2712
|
-
// Native Symbol.
|
|
2713
|
-
if (propType === 'symbol') {
|
|
2714
|
-
return true;
|
|
2715
|
-
}
|
|
2716
|
-
|
|
2717
|
-
// falsy value can't be a Symbol
|
|
2718
|
-
if (!propValue) {
|
|
2719
|
-
return false;
|
|
2720
|
-
}
|
|
2721
|
-
|
|
2722
|
-
// 19.4.3.5 Symbol.prototype[@@toStringTag] === 'Symbol'
|
|
2723
|
-
if (propValue['@@toStringTag'] === 'Symbol') {
|
|
2724
|
-
return true;
|
|
2725
|
-
}
|
|
2726
|
-
|
|
2727
|
-
// Fallback for non-spec compliant Symbols which are polyfilled.
|
|
2728
|
-
if (typeof Symbol === 'function' && propValue instanceof Symbol) {
|
|
2729
|
-
return true;
|
|
2730
|
-
}
|
|
2731
|
-
|
|
2732
|
-
return false;
|
|
2733
|
-
}
|
|
2734
|
-
|
|
2735
|
-
// Equivalent of `typeof` but with special handling for array and regexp.
|
|
2736
|
-
function getPropType(propValue) {
|
|
2737
|
-
var propType = typeof propValue;
|
|
2738
|
-
if (Array.isArray(propValue)) {
|
|
2739
|
-
return 'array';
|
|
2740
|
-
}
|
|
2741
|
-
if (propValue instanceof RegExp) {
|
|
2742
|
-
// Old webkits (at least until Android 4.0) return 'function' rather than
|
|
2743
|
-
// 'object' for typeof a RegExp. We'll normalize this here so that /bla/
|
|
2744
|
-
// passes PropTypes.object.
|
|
2745
|
-
return 'object';
|
|
2746
|
-
}
|
|
2747
|
-
if (isSymbol(propType, propValue)) {
|
|
2748
|
-
return 'symbol';
|
|
2749
|
-
}
|
|
2750
|
-
return propType;
|
|
2751
|
-
}
|
|
2752
|
-
|
|
2753
|
-
// This handles more types than `getPropType`. Only used for error messages.
|
|
2754
|
-
// See `createPrimitiveTypeChecker`.
|
|
2755
|
-
function getPreciseType(propValue) {
|
|
2756
|
-
if (typeof propValue === 'undefined' || propValue === null) {
|
|
2757
|
-
return '' + propValue;
|
|
2758
|
-
}
|
|
2759
|
-
var propType = getPropType(propValue);
|
|
2760
|
-
if (propType === 'object') {
|
|
2761
|
-
if (propValue instanceof Date) {
|
|
2762
|
-
return 'date';
|
|
2763
|
-
} else if (propValue instanceof RegExp) {
|
|
2764
|
-
return 'regexp';
|
|
2765
|
-
}
|
|
2766
|
-
}
|
|
2767
|
-
return propType;
|
|
2768
|
-
}
|
|
2769
|
-
|
|
2770
|
-
// Returns a string that is postfixed to a warning about an invalid type.
|
|
2771
|
-
// For example, "undefined" or "of type array"
|
|
2772
|
-
function getPostfixForTypeWarning(value) {
|
|
2773
|
-
var type = getPreciseType(value);
|
|
2774
|
-
switch (type) {
|
|
2775
|
-
case 'array':
|
|
2776
|
-
case 'object':
|
|
2777
|
-
return 'an ' + type;
|
|
2778
|
-
case 'boolean':
|
|
2779
|
-
case 'date':
|
|
2780
|
-
case 'regexp':
|
|
2781
|
-
return 'a ' + type;
|
|
2782
|
-
default:
|
|
2783
|
-
return type;
|
|
2784
|
-
}
|
|
2785
|
-
}
|
|
2786
|
-
|
|
2787
|
-
// Returns class name of the object, if any.
|
|
2788
|
-
function getClassName(propValue) {
|
|
2789
|
-
if (!propValue.constructor || !propValue.constructor.name) {
|
|
2790
|
-
return ANONYMOUS;
|
|
2791
|
-
}
|
|
2792
|
-
return propValue.constructor.name;
|
|
2793
|
-
}
|
|
2794
|
-
|
|
2795
|
-
ReactPropTypes.checkPropTypes = checkPropTypes;
|
|
2796
|
-
ReactPropTypes.resetWarningCache = checkPropTypes.resetWarningCache;
|
|
2797
|
-
ReactPropTypes.PropTypes = ReactPropTypes;
|
|
2798
|
-
|
|
2799
|
-
return ReactPropTypes;
|
|
2800
|
-
};
|
|
2801
|
-
return factoryWithTypeCheckers;
|
|
2802
|
-
}
|
|
2803
|
-
|
|
2804
|
-
/**
|
|
2805
|
-
* Copyright (c) 2013-present, Facebook, Inc.
|
|
2806
|
-
*
|
|
2807
|
-
* This source code is licensed under the MIT license found in the
|
|
2808
|
-
* LICENSE file in the root directory of this source tree.
|
|
2809
|
-
*/
|
|
2810
|
-
|
|
2811
|
-
var factoryWithThrowingShims;
|
|
2812
|
-
var hasRequiredFactoryWithThrowingShims;
|
|
2813
|
-
|
|
2814
|
-
function requireFactoryWithThrowingShims () {
|
|
2815
|
-
if (hasRequiredFactoryWithThrowingShims) return factoryWithThrowingShims;
|
|
2816
|
-
hasRequiredFactoryWithThrowingShims = 1;
|
|
2817
|
-
|
|
2818
|
-
var ReactPropTypesSecret = requireReactPropTypesSecret();
|
|
2819
|
-
|
|
2820
|
-
function emptyFunction() {}
|
|
2821
|
-
function emptyFunctionWithReset() {}
|
|
2822
|
-
emptyFunctionWithReset.resetWarningCache = emptyFunction;
|
|
2823
|
-
|
|
2824
|
-
factoryWithThrowingShims = function() {
|
|
2825
|
-
function shim(props, propName, componentName, location, propFullName, secret) {
|
|
2826
|
-
if (secret === ReactPropTypesSecret) {
|
|
2827
|
-
// It is still safe when called from React.
|
|
2828
|
-
return;
|
|
2829
|
-
}
|
|
2830
|
-
var err = new Error(
|
|
2831
|
-
'Calling PropTypes validators directly is not supported by the `prop-types` package. ' +
|
|
2832
|
-
'Use PropTypes.checkPropTypes() to call them. ' +
|
|
2833
|
-
'Read more at http://fb.me/use-check-prop-types'
|
|
2834
|
-
);
|
|
2835
|
-
err.name = 'Invariant Violation';
|
|
2836
|
-
throw err;
|
|
2837
|
-
} shim.isRequired = shim;
|
|
2838
|
-
function getShim() {
|
|
2839
|
-
return shim;
|
|
2840
|
-
} // Important!
|
|
2841
|
-
// Keep this list in sync with production version in `./factoryWithTypeCheckers.js`.
|
|
2842
|
-
var ReactPropTypes = {
|
|
2843
|
-
array: shim,
|
|
2844
|
-
bigint: shim,
|
|
2845
|
-
bool: shim,
|
|
2846
|
-
func: shim,
|
|
2847
|
-
number: shim,
|
|
2848
|
-
object: shim,
|
|
2849
|
-
string: shim,
|
|
2850
|
-
symbol: shim,
|
|
2851
|
-
|
|
2852
|
-
any: shim,
|
|
2853
|
-
arrayOf: getShim,
|
|
2854
|
-
element: shim,
|
|
2855
|
-
elementType: shim,
|
|
2856
|
-
instanceOf: getShim,
|
|
2857
|
-
node: shim,
|
|
2858
|
-
objectOf: getShim,
|
|
2859
|
-
oneOf: getShim,
|
|
2860
|
-
oneOfType: getShim,
|
|
2861
|
-
shape: getShim,
|
|
2862
|
-
exact: getShim,
|
|
2863
|
-
|
|
2864
|
-
checkPropTypes: emptyFunctionWithReset,
|
|
2865
|
-
resetWarningCache: emptyFunction
|
|
2866
|
-
};
|
|
2867
|
-
|
|
2868
|
-
ReactPropTypes.PropTypes = ReactPropTypes;
|
|
2869
|
-
|
|
2870
|
-
return ReactPropTypes;
|
|
2871
|
-
};
|
|
2872
|
-
return factoryWithThrowingShims;
|
|
2873
|
-
}
|
|
2874
|
-
|
|
2875
|
-
/**
|
|
2876
|
-
* Copyright (c) 2013-present, Facebook, Inc.
|
|
2877
|
-
*
|
|
2878
|
-
* This source code is licensed under the MIT license found in the
|
|
2879
|
-
* LICENSE file in the root directory of this source tree.
|
|
2880
|
-
*/
|
|
2881
|
-
|
|
2882
|
-
if (process.env.NODE_ENV !== 'production') {
|
|
2883
|
-
var ReactIs = requireReactIs();
|
|
2884
|
-
|
|
2885
|
-
// By explicitly using `prop-types` you are opting into new development behavior.
|
|
2886
|
-
// http://fb.me/prop-types-in-prod
|
|
2887
|
-
var throwOnDirectAccess = true;
|
|
2888
|
-
propTypes.exports = requireFactoryWithTypeCheckers()(ReactIs.isElement, throwOnDirectAccess);
|
|
2889
|
-
} else {
|
|
2890
|
-
// By explicitly using `prop-types` you are opting into new production behavior.
|
|
2891
|
-
// http://fb.me/prop-types-in-prod
|
|
2892
|
-
propTypes.exports = requireFactoryWithThrowingShims()();
|
|
2893
|
-
}
|
|
2894
|
-
|
|
2895
1603
|
/**
|
|
2896
1604
|
* Checks if a given element has a CSS class.
|
|
2897
1605
|
*
|
|
@@ -2939,24 +1647,6 @@ var config = {
|
|
|
2939
1647
|
disabled: false
|
|
2940
1648
|
};
|
|
2941
1649
|
|
|
2942
|
-
var timeoutsShape = process.env.NODE_ENV !== 'production' ? propTypes.exports.oneOfType([propTypes.exports.number, propTypes.exports.shape({
|
|
2943
|
-
enter: propTypes.exports.number,
|
|
2944
|
-
exit: propTypes.exports.number,
|
|
2945
|
-
appear: propTypes.exports.number
|
|
2946
|
-
}).isRequired]) : null;
|
|
2947
|
-
var classNamesShape = process.env.NODE_ENV !== 'production' ? propTypes.exports.oneOfType([propTypes.exports.string, propTypes.exports.shape({
|
|
2948
|
-
enter: propTypes.exports.string,
|
|
2949
|
-
exit: propTypes.exports.string,
|
|
2950
|
-
active: propTypes.exports.string
|
|
2951
|
-
}), propTypes.exports.shape({
|
|
2952
|
-
enter: propTypes.exports.string,
|
|
2953
|
-
enterDone: propTypes.exports.string,
|
|
2954
|
-
enterActive: propTypes.exports.string,
|
|
2955
|
-
exit: propTypes.exports.string,
|
|
2956
|
-
exitDone: propTypes.exports.string,
|
|
2957
|
-
exitActive: propTypes.exports.string
|
|
2958
|
-
})]) : null;
|
|
2959
|
-
|
|
2960
1650
|
var TransitionGroupContext = React__default["default"].createContext(null);
|
|
2961
1651
|
|
|
2962
1652
|
var forceReflow = function forceReflow(node) {
|
|
@@ -3369,193 +2059,7 @@ var Transition = /*#__PURE__*/function (_React$Component) {
|
|
|
3369
2059
|
}(React__default["default"].Component);
|
|
3370
2060
|
|
|
3371
2061
|
Transition.contextType = TransitionGroupContext;
|
|
3372
|
-
Transition.propTypes =
|
|
3373
|
-
/**
|
|
3374
|
-
* A React reference to DOM element that need to transition:
|
|
3375
|
-
* https://stackoverflow.com/a/51127130/4671932
|
|
3376
|
-
*
|
|
3377
|
-
* - When `nodeRef` prop is used, `node` is not passed to callback functions
|
|
3378
|
-
* (e.g. `onEnter`) because user already has direct access to the node.
|
|
3379
|
-
* - When changing `key` prop of `Transition` in a `TransitionGroup` a new
|
|
3380
|
-
* `nodeRef` need to be provided to `Transition` with changed `key` prop
|
|
3381
|
-
* (see
|
|
3382
|
-
* [test/CSSTransition-test.js](https://github.com/reactjs/react-transition-group/blob/13435f897b3ab71f6e19d724f145596f5910581c/test/CSSTransition-test.js#L362-L437)).
|
|
3383
|
-
*/
|
|
3384
|
-
nodeRef: propTypes.exports.shape({
|
|
3385
|
-
current: typeof Element === 'undefined' ? propTypes.exports.any : function (propValue, key, componentName, location, propFullName, secret) {
|
|
3386
|
-
var value = propValue[key];
|
|
3387
|
-
return propTypes.exports.instanceOf(value && 'ownerDocument' in value ? value.ownerDocument.defaultView.Element : Element)(propValue, key, componentName, location, propFullName, secret);
|
|
3388
|
-
}
|
|
3389
|
-
}),
|
|
3390
|
-
|
|
3391
|
-
/**
|
|
3392
|
-
* A `function` child can be used instead of a React element. This function is
|
|
3393
|
-
* called with the current transition status (`'entering'`, `'entered'`,
|
|
3394
|
-
* `'exiting'`, `'exited'`), which can be used to apply context
|
|
3395
|
-
* specific props to a component.
|
|
3396
|
-
*
|
|
3397
|
-
* ```jsx
|
|
3398
|
-
* <Transition in={this.state.in} timeout={150}>
|
|
3399
|
-
* {state => (
|
|
3400
|
-
* <MyComponent className={`fade fade-${state}`} />
|
|
3401
|
-
* )}
|
|
3402
|
-
* </Transition>
|
|
3403
|
-
* ```
|
|
3404
|
-
*/
|
|
3405
|
-
children: propTypes.exports.oneOfType([propTypes.exports.func.isRequired, propTypes.exports.element.isRequired]).isRequired,
|
|
3406
|
-
|
|
3407
|
-
/**
|
|
3408
|
-
* Show the component; triggers the enter or exit states
|
|
3409
|
-
*/
|
|
3410
|
-
in: propTypes.exports.bool,
|
|
3411
|
-
|
|
3412
|
-
/**
|
|
3413
|
-
* By default the child component is mounted immediately along with
|
|
3414
|
-
* the parent `Transition` component. If you want to "lazy mount" the component on the
|
|
3415
|
-
* first `in={true}` you can set `mountOnEnter`. After the first enter transition the component will stay
|
|
3416
|
-
* mounted, even on "exited", unless you also specify `unmountOnExit`.
|
|
3417
|
-
*/
|
|
3418
|
-
mountOnEnter: propTypes.exports.bool,
|
|
3419
|
-
|
|
3420
|
-
/**
|
|
3421
|
-
* By default the child component stays mounted after it reaches the `'exited'` state.
|
|
3422
|
-
* Set `unmountOnExit` if you'd prefer to unmount the component after it finishes exiting.
|
|
3423
|
-
*/
|
|
3424
|
-
unmountOnExit: propTypes.exports.bool,
|
|
3425
|
-
|
|
3426
|
-
/**
|
|
3427
|
-
* By default the child component does not perform the enter transition when
|
|
3428
|
-
* it first mounts, regardless of the value of `in`. If you want this
|
|
3429
|
-
* behavior, set both `appear` and `in` to `true`.
|
|
3430
|
-
*
|
|
3431
|
-
* > **Note**: there are no special appear states like `appearing`/`appeared`, this prop
|
|
3432
|
-
* > only adds an additional enter transition. However, in the
|
|
3433
|
-
* > `<CSSTransition>` component that first enter transition does result in
|
|
3434
|
-
* > additional `.appear-*` classes, that way you can choose to style it
|
|
3435
|
-
* > differently.
|
|
3436
|
-
*/
|
|
3437
|
-
appear: propTypes.exports.bool,
|
|
3438
|
-
|
|
3439
|
-
/**
|
|
3440
|
-
* Enable or disable enter transitions.
|
|
3441
|
-
*/
|
|
3442
|
-
enter: propTypes.exports.bool,
|
|
3443
|
-
|
|
3444
|
-
/**
|
|
3445
|
-
* Enable or disable exit transitions.
|
|
3446
|
-
*/
|
|
3447
|
-
exit: propTypes.exports.bool,
|
|
3448
|
-
|
|
3449
|
-
/**
|
|
3450
|
-
* The duration of the transition, in milliseconds.
|
|
3451
|
-
* Required unless `addEndListener` is provided.
|
|
3452
|
-
*
|
|
3453
|
-
* You may specify a single timeout for all transitions:
|
|
3454
|
-
*
|
|
3455
|
-
* ```jsx
|
|
3456
|
-
* timeout={500}
|
|
3457
|
-
* ```
|
|
3458
|
-
*
|
|
3459
|
-
* or individually:
|
|
3460
|
-
*
|
|
3461
|
-
* ```jsx
|
|
3462
|
-
* timeout={{
|
|
3463
|
-
* appear: 500,
|
|
3464
|
-
* enter: 300,
|
|
3465
|
-
* exit: 500,
|
|
3466
|
-
* }}
|
|
3467
|
-
* ```
|
|
3468
|
-
*
|
|
3469
|
-
* - `appear` defaults to the value of `enter`
|
|
3470
|
-
* - `enter` defaults to `0`
|
|
3471
|
-
* - `exit` defaults to `0`
|
|
3472
|
-
*
|
|
3473
|
-
* @type {number | { enter?: number, exit?: number, appear?: number }}
|
|
3474
|
-
*/
|
|
3475
|
-
timeout: function timeout(props) {
|
|
3476
|
-
var pt = timeoutsShape;
|
|
3477
|
-
if (!props.addEndListener) pt = pt.isRequired;
|
|
3478
|
-
|
|
3479
|
-
for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {
|
|
3480
|
-
args[_key - 1] = arguments[_key];
|
|
3481
|
-
}
|
|
3482
|
-
|
|
3483
|
-
return pt.apply(void 0, [props].concat(args));
|
|
3484
|
-
},
|
|
3485
|
-
|
|
3486
|
-
/**
|
|
3487
|
-
* Add a custom transition end trigger. Called with the transitioning
|
|
3488
|
-
* DOM node and a `done` callback. Allows for more fine grained transition end
|
|
3489
|
-
* logic. Timeouts are still used as a fallback if provided.
|
|
3490
|
-
*
|
|
3491
|
-
* **Note**: when `nodeRef` prop is passed, `node` is not passed.
|
|
3492
|
-
*
|
|
3493
|
-
* ```jsx
|
|
3494
|
-
* addEndListener={(node, done) => {
|
|
3495
|
-
* // use the css transitionend event to mark the finish of a transition
|
|
3496
|
-
* node.addEventListener('transitionend', done, false);
|
|
3497
|
-
* }}
|
|
3498
|
-
* ```
|
|
3499
|
-
*/
|
|
3500
|
-
addEndListener: propTypes.exports.func,
|
|
3501
|
-
|
|
3502
|
-
/**
|
|
3503
|
-
* Callback fired before the "entering" status is applied. An extra parameter
|
|
3504
|
-
* `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount
|
|
3505
|
-
*
|
|
3506
|
-
* **Note**: when `nodeRef` prop is passed, `node` is not passed.
|
|
3507
|
-
*
|
|
3508
|
-
* @type Function(node: HtmlElement, isAppearing: bool) -> void
|
|
3509
|
-
*/
|
|
3510
|
-
onEnter: propTypes.exports.func,
|
|
3511
|
-
|
|
3512
|
-
/**
|
|
3513
|
-
* Callback fired after the "entering" status is applied. An extra parameter
|
|
3514
|
-
* `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount
|
|
3515
|
-
*
|
|
3516
|
-
* **Note**: when `nodeRef` prop is passed, `node` is not passed.
|
|
3517
|
-
*
|
|
3518
|
-
* @type Function(node: HtmlElement, isAppearing: bool)
|
|
3519
|
-
*/
|
|
3520
|
-
onEntering: propTypes.exports.func,
|
|
3521
|
-
|
|
3522
|
-
/**
|
|
3523
|
-
* Callback fired after the "entered" status is applied. An extra parameter
|
|
3524
|
-
* `isAppearing` is supplied to indicate if the enter stage is occurring on the initial mount
|
|
3525
|
-
*
|
|
3526
|
-
* **Note**: when `nodeRef` prop is passed, `node` is not passed.
|
|
3527
|
-
*
|
|
3528
|
-
* @type Function(node: HtmlElement, isAppearing: bool) -> void
|
|
3529
|
-
*/
|
|
3530
|
-
onEntered: propTypes.exports.func,
|
|
3531
|
-
|
|
3532
|
-
/**
|
|
3533
|
-
* Callback fired before the "exiting" status is applied.
|
|
3534
|
-
*
|
|
3535
|
-
* **Note**: when `nodeRef` prop is passed, `node` is not passed.
|
|
3536
|
-
*
|
|
3537
|
-
* @type Function(node: HtmlElement) -> void
|
|
3538
|
-
*/
|
|
3539
|
-
onExit: propTypes.exports.func,
|
|
3540
|
-
|
|
3541
|
-
/**
|
|
3542
|
-
* Callback fired after the "exiting" status is applied.
|
|
3543
|
-
*
|
|
3544
|
-
* **Note**: when `nodeRef` prop is passed, `node` is not passed.
|
|
3545
|
-
*
|
|
3546
|
-
* @type Function(node: HtmlElement) -> void
|
|
3547
|
-
*/
|
|
3548
|
-
onExiting: propTypes.exports.func,
|
|
3549
|
-
|
|
3550
|
-
/**
|
|
3551
|
-
* Callback fired after the "exited" status is applied.
|
|
3552
|
-
*
|
|
3553
|
-
* **Note**: when `nodeRef` prop is passed, `node` is not passed
|
|
3554
|
-
*
|
|
3555
|
-
* @type Function(node: HtmlElement) -> void
|
|
3556
|
-
*/
|
|
3557
|
-
onExited: propTypes.exports.func
|
|
3558
|
-
} : {}; // Name the function so it is clearer in the documentation
|
|
2062
|
+
Transition.propTypes = {}; // Name the function so it is clearer in the documentation
|
|
3559
2063
|
|
|
3560
2064
|
function noop() {}
|
|
3561
2065
|
|
|
@@ -3850,136 +2354,7 @@ var CSSTransition = /*#__PURE__*/function (_React$Component) {
|
|
|
3850
2354
|
CSSTransition.defaultProps = {
|
|
3851
2355
|
classNames: ''
|
|
3852
2356
|
};
|
|
3853
|
-
CSSTransition.propTypes =
|
|
3854
|
-
/**
|
|
3855
|
-
* The animation classNames applied to the component as it appears, enters,
|
|
3856
|
-
* exits or has finished the transition. A single name can be provided, which
|
|
3857
|
-
* will be suffixed for each stage, e.g. `classNames="fade"` applies:
|
|
3858
|
-
*
|
|
3859
|
-
* - `fade-appear`, `fade-appear-active`, `fade-appear-done`
|
|
3860
|
-
* - `fade-enter`, `fade-enter-active`, `fade-enter-done`
|
|
3861
|
-
* - `fade-exit`, `fade-exit-active`, `fade-exit-done`
|
|
3862
|
-
*
|
|
3863
|
-
* A few details to note about how these classes are applied:
|
|
3864
|
-
*
|
|
3865
|
-
* 1. They are _joined_ with the ones that are already defined on the child
|
|
3866
|
-
* component, so if you want to add some base styles, you can use
|
|
3867
|
-
* `className` without worrying that it will be overridden.
|
|
3868
|
-
*
|
|
3869
|
-
* 2. If the transition component mounts with `in={false}`, no classes are
|
|
3870
|
-
* applied yet. You might be expecting `*-exit-done`, but if you think
|
|
3871
|
-
* about it, a component cannot finish exiting if it hasn't entered yet.
|
|
3872
|
-
*
|
|
3873
|
-
* 2. `fade-appear-done` and `fade-enter-done` will _both_ be applied. This
|
|
3874
|
-
* allows you to define different behavior for when appearing is done and
|
|
3875
|
-
* when regular entering is done, using selectors like
|
|
3876
|
-
* `.fade-enter-done:not(.fade-appear-done)`. For example, you could apply
|
|
3877
|
-
* an epic entrance animation when element first appears in the DOM using
|
|
3878
|
-
* [Animate.css](https://daneden.github.io/animate.css/). Otherwise you can
|
|
3879
|
-
* simply use `fade-enter-done` for defining both cases.
|
|
3880
|
-
*
|
|
3881
|
-
* Each individual classNames can also be specified independently like:
|
|
3882
|
-
*
|
|
3883
|
-
* ```js
|
|
3884
|
-
* classNames={{
|
|
3885
|
-
* appear: 'my-appear',
|
|
3886
|
-
* appearActive: 'my-active-appear',
|
|
3887
|
-
* appearDone: 'my-done-appear',
|
|
3888
|
-
* enter: 'my-enter',
|
|
3889
|
-
* enterActive: 'my-active-enter',
|
|
3890
|
-
* enterDone: 'my-done-enter',
|
|
3891
|
-
* exit: 'my-exit',
|
|
3892
|
-
* exitActive: 'my-active-exit',
|
|
3893
|
-
* exitDone: 'my-done-exit',
|
|
3894
|
-
* }}
|
|
3895
|
-
* ```
|
|
3896
|
-
*
|
|
3897
|
-
* If you want to set these classes using CSS Modules:
|
|
3898
|
-
*
|
|
3899
|
-
* ```js
|
|
3900
|
-
* import styles from './styles.css';
|
|
3901
|
-
* ```
|
|
3902
|
-
*
|
|
3903
|
-
* you might want to use camelCase in your CSS file, that way could simply
|
|
3904
|
-
* spread them instead of listing them one by one:
|
|
3905
|
-
*
|
|
3906
|
-
* ```js
|
|
3907
|
-
* classNames={{ ...styles }}
|
|
3908
|
-
* ```
|
|
3909
|
-
*
|
|
3910
|
-
* @type {string | {
|
|
3911
|
-
* appear?: string,
|
|
3912
|
-
* appearActive?: string,
|
|
3913
|
-
* appearDone?: string,
|
|
3914
|
-
* enter?: string,
|
|
3915
|
-
* enterActive?: string,
|
|
3916
|
-
* enterDone?: string,
|
|
3917
|
-
* exit?: string,
|
|
3918
|
-
* exitActive?: string,
|
|
3919
|
-
* exitDone?: string,
|
|
3920
|
-
* }}
|
|
3921
|
-
*/
|
|
3922
|
-
classNames: classNamesShape,
|
|
3923
|
-
|
|
3924
|
-
/**
|
|
3925
|
-
* A `<Transition>` callback fired immediately after the 'enter' or 'appear' class is
|
|
3926
|
-
* applied.
|
|
3927
|
-
*
|
|
3928
|
-
* **Note**: when `nodeRef` prop is passed, `node` is not passed.
|
|
3929
|
-
*
|
|
3930
|
-
* @type Function(node: HtmlElement, isAppearing: bool)
|
|
3931
|
-
*/
|
|
3932
|
-
onEnter: propTypes.exports.func,
|
|
3933
|
-
|
|
3934
|
-
/**
|
|
3935
|
-
* A `<Transition>` callback fired immediately after the 'enter-active' or
|
|
3936
|
-
* 'appear-active' class is applied.
|
|
3937
|
-
*
|
|
3938
|
-
* **Note**: when `nodeRef` prop is passed, `node` is not passed.
|
|
3939
|
-
*
|
|
3940
|
-
* @type Function(node: HtmlElement, isAppearing: bool)
|
|
3941
|
-
*/
|
|
3942
|
-
onEntering: propTypes.exports.func,
|
|
3943
|
-
|
|
3944
|
-
/**
|
|
3945
|
-
* A `<Transition>` callback fired immediately after the 'enter' or
|
|
3946
|
-
* 'appear' classes are **removed** and the `done` class is added to the DOM node.
|
|
3947
|
-
*
|
|
3948
|
-
* **Note**: when `nodeRef` prop is passed, `node` is not passed.
|
|
3949
|
-
*
|
|
3950
|
-
* @type Function(node: HtmlElement, isAppearing: bool)
|
|
3951
|
-
*/
|
|
3952
|
-
onEntered: propTypes.exports.func,
|
|
3953
|
-
|
|
3954
|
-
/**
|
|
3955
|
-
* A `<Transition>` callback fired immediately after the 'exit' class is
|
|
3956
|
-
* applied.
|
|
3957
|
-
*
|
|
3958
|
-
* **Note**: when `nodeRef` prop is passed, `node` is not passed
|
|
3959
|
-
*
|
|
3960
|
-
* @type Function(node: HtmlElement)
|
|
3961
|
-
*/
|
|
3962
|
-
onExit: propTypes.exports.func,
|
|
3963
|
-
|
|
3964
|
-
/**
|
|
3965
|
-
* A `<Transition>` callback fired immediately after the 'exit-active' is applied.
|
|
3966
|
-
*
|
|
3967
|
-
* **Note**: when `nodeRef` prop is passed, `node` is not passed
|
|
3968
|
-
*
|
|
3969
|
-
* @type Function(node: HtmlElement)
|
|
3970
|
-
*/
|
|
3971
|
-
onExiting: propTypes.exports.func,
|
|
3972
|
-
|
|
3973
|
-
/**
|
|
3974
|
-
* A `<Transition>` callback fired immediately after the 'exit' classes
|
|
3975
|
-
* are **removed** and the `exit-done` class is added to the DOM node.
|
|
3976
|
-
*
|
|
3977
|
-
* **Note**: when `nodeRef` prop is passed, `node` is not passed
|
|
3978
|
-
*
|
|
3979
|
-
* @type Function(node: HtmlElement)
|
|
3980
|
-
*/
|
|
3981
|
-
onExited: propTypes.exports.func
|
|
3982
|
-
}) : {};
|
|
2357
|
+
CSSTransition.propTypes = {};
|
|
3983
2358
|
var CSSTransition$1 = CSSTransition;
|
|
3984
2359
|
|
|
3985
2360
|
var Body = function Body(_ref) {
|
|
@@ -4042,7 +2417,7 @@ var Slider = function Slider(_ref) {
|
|
|
4042
2417
|
timeout: 300
|
|
4043
2418
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
4044
2419
|
className: "neeto-filters-slider__pane"
|
|
4045
|
-
}, /*#__PURE__*/React__default["default"].createElement("div", _extends
|
|
2420
|
+
}, /*#__PURE__*/React__default["default"].createElement("div", _extends({
|
|
4046
2421
|
className: classnames__default["default"]("neeto-filters-slider__wrapper", _defineProperty({
|
|
4047
2422
|
"neeto-filters-slider__wrapper--xsmall": size === SIZES.xsmall,
|
|
4048
2423
|
"neeto-filters-slider__wrapper--small": size === SIZES.small,
|
|
@@ -4081,7 +2456,7 @@ var useFilters = function useFilters(_ref) {
|
|
|
4081
2456
|
var handlePrecenseOfDefaultFilters = function handlePrecenseOfDefaultFilters(defaultFilters) {
|
|
4082
2457
|
var params = buildUrlFromFilters({
|
|
4083
2458
|
columns: columns,
|
|
4084
|
-
filters: isNotEmpty(getSearchTermFromUrl()) ? [].concat(_toConsumableArray(defaultFilters), [keywordFilter]) : defaultFilters
|
|
2459
|
+
filters: isKeywordFilterPresent(keywordFilter) && neetoCist.isNotEmpty(getSearchTermFromUrl()) ? [].concat(_toConsumableArray(defaultFilters), [keywordFilter]) : defaultFilters
|
|
4085
2460
|
});
|
|
4086
2461
|
history.replace({
|
|
4087
2462
|
search: params
|
|
@@ -4101,7 +2476,7 @@ var useFilters = function useFilters(_ref) {
|
|
|
4101
2476
|
return;
|
|
4102
2477
|
}
|
|
4103
2478
|
var newFilters = buildFiltersFromSearchParams(columns);
|
|
4104
|
-
var filtersPayload = isNotEmpty(getSearchTermFromUrl()) ? ramda.append(keywordFilter, newFilters) : newFilters;
|
|
2479
|
+
var filtersPayload = isKeywordFilterPresent(keywordFilter) && neetoCist.isNotEmpty(getSearchTermFromUrl()) ? ramda.append(keywordFilter, newFilters) : newFilters;
|
|
4105
2480
|
handleFiltersChange(filtersPayload);
|
|
4106
2481
|
onSelectorsChange(buildSelectorsFromURL(columns));
|
|
4107
2482
|
};
|
|
@@ -4126,7 +2501,7 @@ var useFilters = function useFilters(_ref) {
|
|
|
4126
2501
|
initialRender.current = false;
|
|
4127
2502
|
var keywordValue = getSearchTermFromUrl();
|
|
4128
2503
|
var defaultFilters = buildDefaultFilters(columns, filters);
|
|
4129
|
-
isNotEmpty(defaultFilters) && handlePrecenseOfDefaultFilters(defaultFilters);
|
|
2504
|
+
neetoCist.isNotEmpty(defaultFilters) && handlePrecenseOfDefaultFilters(defaultFilters);
|
|
4130
2505
|
prevFilters.current = ramda.append(ramda.mergeRight(keywordFilter, {
|
|
4131
2506
|
value: keywordValue
|
|
4132
2507
|
}), filters);
|
|
@@ -4150,14 +2525,14 @@ var buildDropdownValue = function buildDropdownValue(_ref) {
|
|
|
4150
2525
|
return filter.value.includes(value);
|
|
4151
2526
|
});
|
|
4152
2527
|
}
|
|
4153
|
-
return findBy({
|
|
2528
|
+
return neetoCist.findBy({
|
|
4154
2529
|
value: filter.value
|
|
4155
2530
|
}, options);
|
|
4156
2531
|
};
|
|
4157
2532
|
var buildSingleTimeValue = function buildSingleTimeValue(filter) {
|
|
4158
2533
|
var _findBy2;
|
|
4159
2534
|
if (!filter) return null;
|
|
4160
|
-
return (_findBy2 = findBy({
|
|
2535
|
+
return (_findBy2 = neetoCist.findBy({
|
|
4161
2536
|
value: filter.value
|
|
4162
2537
|
}, TIME_OPTIONS)) !== null && _findBy2 !== void 0 ? _findBy2 : ramda.last(TIME_OPTIONS);
|
|
4163
2538
|
};
|
|
@@ -4174,24 +2549,24 @@ var buildDropdownOptions = function buildDropdownOptions(_ref3) {
|
|
|
4174
2549
|
if (!filter) return options;
|
|
4175
2550
|
if (isMulti(defaultType)) {
|
|
4176
2551
|
var selectedOptions = filter.value.map(function (value) {
|
|
4177
|
-
return findBy({
|
|
2552
|
+
return neetoCist.findBy({
|
|
4178
2553
|
value: value
|
|
4179
|
-
}, options) || toLabelAndValue(value);
|
|
2554
|
+
}, options) || neetoCist.toLabelAndValue(value);
|
|
4180
2555
|
});
|
|
4181
2556
|
var nonSelectedOptions = options.filter(function (option) {
|
|
4182
2557
|
return !filter.value.includes(option.value);
|
|
4183
2558
|
});
|
|
4184
2559
|
return ramda.concat(selectedOptions, nonSelectedOptions);
|
|
4185
2560
|
}
|
|
4186
|
-
if (!findBy({
|
|
2561
|
+
if (!neetoCist.findBy({
|
|
4187
2562
|
value: filter.value
|
|
4188
2563
|
}, options)) {
|
|
4189
|
-
return ramda.append(toLabelAndValue(filter.value), options);
|
|
2564
|
+
return ramda.append(neetoCist.toLabelAndValue(filter.value), options);
|
|
4190
2565
|
}
|
|
4191
2566
|
return options;
|
|
4192
2567
|
};
|
|
4193
2568
|
var initializeDateRule = function initializeDateRule(filter) {
|
|
4194
|
-
return filter ? findBy({
|
|
2569
|
+
return filter ? neetoCist.findBy({
|
|
4195
2570
|
value: filter === null || filter === void 0 ? void 0 : filter.value
|
|
4196
2571
|
}, DATE_OPTIONS) || findDateOption(filter, DATE_OPTIONS) : {};
|
|
4197
2572
|
};
|
|
@@ -4202,20 +2577,20 @@ var getDateValue = function getDateValue(value, rule) {
|
|
|
4202
2577
|
if (rule.value === "custom-date-range") {
|
|
4203
2578
|
return value;
|
|
4204
2579
|
}
|
|
4205
|
-
return rule.value === "before" ?
|
|
2580
|
+
return rule.value === "before" ? dayjs(value[1]).add(1, "day") : dayjs(value[0]).subtract(1, "day");
|
|
4206
2581
|
};
|
|
4207
2582
|
var findDateOption = function findDateOption(filter, options) {
|
|
4208
2583
|
var value = filter.value;
|
|
4209
|
-
var isBeforeOrAfter =
|
|
2584
|
+
var isBeforeOrAfter = dayjs(value[1]).diff(dayjs(value[0]), "year") >= 90;
|
|
4210
2585
|
if (ramda.not(isBeforeOrAfter)) {
|
|
4211
2586
|
return ramda.last(options);
|
|
4212
2587
|
}
|
|
4213
|
-
var currentMoment =
|
|
4214
|
-
var diffWithStart = Math.abs(currentMoment.diff(
|
|
4215
|
-
var diffWithEnd = Math.abs(currentMoment.diff(
|
|
4216
|
-
var returnOption = diffWithStart < diffWithEnd ? findBy({
|
|
2588
|
+
var currentMoment = dayjs();
|
|
2589
|
+
var diffWithStart = Math.abs(currentMoment.diff(dayjs(value[0]), "year"));
|
|
2590
|
+
var diffWithEnd = Math.abs(currentMoment.diff(dayjs(value[1]), "year"));
|
|
2591
|
+
var returnOption = diffWithStart < diffWithEnd ? neetoCist.findBy({
|
|
4217
2592
|
value: "after"
|
|
4218
|
-
}, options) : findBy({
|
|
2593
|
+
}, options) : neetoCist.findBy({
|
|
4219
2594
|
value: "before"
|
|
4220
2595
|
}, options);
|
|
4221
2596
|
return returnOption;
|
|
@@ -4262,7 +2637,7 @@ var Boolean = function Boolean(_ref) {
|
|
|
4262
2637
|
});
|
|
4263
2638
|
handleApplyFilter(updatedFilter);
|
|
4264
2639
|
};
|
|
4265
|
-
return /*#__PURE__*/React__default["default"].createElement(neetoui.Select, _extends
|
|
2640
|
+
return /*#__PURE__*/React__default["default"].createElement(neetoui.Select, _extends({
|
|
4266
2641
|
autoFocus: autoFocus,
|
|
4267
2642
|
label: label,
|
|
4268
2643
|
options: options,
|
|
@@ -4347,7 +2722,7 @@ var Datetime = function Datetime(_ref) {
|
|
|
4347
2722
|
resource: label.toLocaleLowerCase()
|
|
4348
2723
|
}),
|
|
4349
2724
|
onChange: handleChange
|
|
4350
|
-
}), isDatePickerShown && /*#__PURE__*/React__default["default"].createElement(neetoui.DatePicker, _extends
|
|
2725
|
+
}), isDatePickerShown && /*#__PURE__*/React__default["default"].createElement(neetoui.DatePicker, _extends({
|
|
4351
2726
|
"data-cy": "neeto-filters-".concat(key, "-date-range"),
|
|
4352
2727
|
getPopupContainer: ramda.prop("parentNode"),
|
|
4353
2728
|
type: (selectedRule === null || selectedRule === void 0 ? void 0 : selectedRule.value) === "custom-date-range" ? "range" : "date",
|
|
@@ -4397,7 +2772,7 @@ var Dropdown = function Dropdown(_ref) {
|
|
|
4397
2772
|
});
|
|
4398
2773
|
handleApplyFilter(updatedFilter);
|
|
4399
2774
|
};
|
|
4400
|
-
return /*#__PURE__*/React__default["default"].createElement(neetoui.Select, _extends
|
|
2775
|
+
return /*#__PURE__*/React__default["default"].createElement(neetoui.Select, _extends({
|
|
4401
2776
|
autoFocus: autoFocus,
|
|
4402
2777
|
label: label,
|
|
4403
2778
|
options: options,
|
|
@@ -4421,7 +2796,7 @@ var SingleDatetime = function SingleDatetime(_ref) {
|
|
|
4421
2796
|
handleApplyFilter = _ref.handleApplyFilter,
|
|
4422
2797
|
autoFocus = _ref.autoFocus;
|
|
4423
2798
|
var _useState = React.useState(function () {
|
|
4424
|
-
return findBy({
|
|
2799
|
+
return neetoCist.findBy({
|
|
4425
2800
|
value: filter === null || filter === void 0 ? void 0 : filter.rule
|
|
4426
2801
|
}, SINGLE_DATE_OPTIONS) || SINGLE_DATE_OPTIONS[0];
|
|
4427
2802
|
}),
|
|
@@ -4438,9 +2813,8 @@ var SingleDatetime = function SingleDatetime(_ref) {
|
|
|
4438
2813
|
|
|
4439
2814
|
// Reset states when "Clear filters" button is clicked.
|
|
4440
2815
|
React.useEffect(function () {
|
|
4441
|
-
if (ramda.isEmpty(filters))
|
|
4442
|
-
|
|
4443
|
-
}
|
|
2816
|
+
if (!ramda.isEmpty(filters)) return;
|
|
2817
|
+
setSelectedRule(SINGLE_DATE_OPTIONS[0]);
|
|
4444
2818
|
}, [filters]);
|
|
4445
2819
|
var handleRuleChange = function handleRuleChange(ruleOption) {
|
|
4446
2820
|
setSelectedRule(ruleOption);
|
|
@@ -4488,7 +2862,7 @@ var SingleDatetime = function SingleDatetime(_ref) {
|
|
|
4488
2862
|
strategy: "fixed",
|
|
4489
2863
|
value: selectedRule,
|
|
4490
2864
|
onChange: handleRuleChange
|
|
4491
|
-
}), /*#__PURE__*/React__default["default"].createElement(neetoui.DatePicker, _extends
|
|
2865
|
+
}), /*#__PURE__*/React__default["default"].createElement(neetoui.DatePicker, _extends({
|
|
4492
2866
|
autoFocus: autoFocus,
|
|
4493
2867
|
value: value,
|
|
4494
2868
|
"data-cy": "neeto-filters-".concat(key, "-filter"),
|
|
@@ -4505,7 +2879,7 @@ var SingleTime = function SingleTime(_ref) {
|
|
|
4505
2879
|
handleApplyFilter = _ref.handleApplyFilter,
|
|
4506
2880
|
autoFocus = _ref.autoFocus;
|
|
4507
2881
|
var _useState = React.useState(function () {
|
|
4508
|
-
return findBy({
|
|
2882
|
+
return neetoCist.findBy({
|
|
4509
2883
|
value: filter === null || filter === void 0 ? void 0 : filter.rule
|
|
4510
2884
|
}, SINGLE_TIME_OPTIONS) || SINGLE_TIME_OPTIONS[0];
|
|
4511
2885
|
}),
|
|
@@ -4520,9 +2894,8 @@ var SingleTime = function SingleTime(_ref) {
|
|
|
4520
2894
|
var timePickerType = selectedRule.value === "between" ? "range" : "time";
|
|
4521
2895
|
var value = filter === null || filter === void 0 ? void 0 : filter.value;
|
|
4522
2896
|
React.useEffect(function () {
|
|
4523
|
-
if (ramda.isEmpty(filters))
|
|
4524
|
-
|
|
4525
|
-
}
|
|
2897
|
+
if (!ramda.isEmpty(filters)) return;
|
|
2898
|
+
setSelectedRule(SINGLE_TIME_OPTIONS[0]);
|
|
4526
2899
|
}, [filters]);
|
|
4527
2900
|
var handleRuleChange = function handleRuleChange(ruleOption) {
|
|
4528
2901
|
setSelectedRule(ruleOption);
|
|
@@ -4563,10 +2936,10 @@ var SingleTime = function SingleTime(_ref) {
|
|
|
4563
2936
|
strategy: "fixed",
|
|
4564
2937
|
value: selectedRule,
|
|
4565
2938
|
onChange: handleRuleChange
|
|
4566
|
-
}), /*#__PURE__*/React__default["default"].createElement(neetoui.TimePicker, _extends
|
|
4567
|
-
use12Hours: true,
|
|
2939
|
+
}), /*#__PURE__*/React__default["default"].createElement(neetoui.TimePicker, _extends({
|
|
4568
2940
|
autoFocus: autoFocus,
|
|
4569
2941
|
value: value,
|
|
2942
|
+
use12Hours: true,
|
|
4570
2943
|
className: "w-full",
|
|
4571
2944
|
"data-cy": "neeto-filters-".concat(key, "-filter"),
|
|
4572
2945
|
format: "h:mm A",
|
|
@@ -4599,7 +2972,7 @@ var Text = function Text(_ref) {
|
|
|
4599
2972
|
inputValue = _useState2[0],
|
|
4600
2973
|
setInputValue = _useState2[1];
|
|
4601
2974
|
var _useState3 = React.useState(function () {
|
|
4602
|
-
return findBy({
|
|
2975
|
+
return neetoCist.findBy({
|
|
4603
2976
|
value: filter === null || filter === void 0 ? void 0 : filter.rule
|
|
4604
2977
|
}, ruleOptions) || ruleOptions[0];
|
|
4605
2978
|
}),
|
|
@@ -4623,10 +2996,9 @@ var Text = function Text(_ref) {
|
|
|
4623
2996
|
handleApplyFilter(updatedFilter);
|
|
4624
2997
|
};
|
|
4625
2998
|
var handleKeydown = function handleKeydown(e) {
|
|
4626
|
-
if (e.key === "Enter")
|
|
4627
|
-
|
|
4628
|
-
|
|
4629
|
-
}
|
|
2999
|
+
if (!(e.key === "Enter")) return;
|
|
3000
|
+
handleUpdateAndApplyFilter(inputValue);
|
|
3001
|
+
onClose();
|
|
4630
3002
|
};
|
|
4631
3003
|
var handleRuleChange = function handleRuleChange(ruleOption) {
|
|
4632
3004
|
setSelectedRule(ruleOption);
|
|
@@ -4657,7 +3029,7 @@ var Text = function Text(_ref) {
|
|
|
4657
3029
|
strategy: "fixed",
|
|
4658
3030
|
value: selectedRule,
|
|
4659
3031
|
onChange: handleRuleChange
|
|
4660
|
-
}), /*#__PURE__*/React__default["default"].createElement(neetoui.Input, _extends
|
|
3032
|
+
}), /*#__PURE__*/React__default["default"].createElement(neetoui.Input, _extends({
|
|
4661
3033
|
autoFocus: autoFocus,
|
|
4662
3034
|
"data-cy": "neeto-filters-".concat(key, "-filter"),
|
|
4663
3035
|
label: !showRuleSelector && label,
|
|
@@ -4727,7 +3099,7 @@ var Time = function Time(_ref) {
|
|
|
4727
3099
|
resource: label.toLocaleLowerCase()
|
|
4728
3100
|
}),
|
|
4729
3101
|
onChange: handleChange
|
|
4730
|
-
}), isCustomTimeRangeShown && /*#__PURE__*/React__default["default"].createElement(neetoui.TimePicker, _extends
|
|
3102
|
+
}), isCustomTimeRangeShown && /*#__PURE__*/React__default["default"].createElement(neetoui.TimePicker, _extends({
|
|
4731
3103
|
use12Hours: true,
|
|
4732
3104
|
"data-cy": "neeto-filters-".concat(key, "-date-range"),
|
|
4733
3105
|
format: "h:mm A",
|
|
@@ -4749,14 +3121,14 @@ var Item = function Item(_ref) {
|
|
|
4749
3121
|
_column$defaultType = column.defaultType,
|
|
4750
3122
|
defaultType = _column$defaultType === void 0 ? column.type : _column$defaultType;
|
|
4751
3123
|
var filter = React.useMemo(function () {
|
|
4752
|
-
return findBy({
|
|
3124
|
+
return neetoCist.findBy({
|
|
4753
3125
|
key: key
|
|
4754
3126
|
}, filters);
|
|
4755
3127
|
}, [filters, key]);
|
|
4756
3128
|
var handleApplyFilter = function handleApplyFilter(updatedFilter) {
|
|
4757
|
-
if (updatedFilter._delete) onChange(removeBy({
|
|
3129
|
+
if (updatedFilter._delete) onChange(neetoCist.removeBy({
|
|
4758
3130
|
key: key
|
|
4759
|
-
}, filters));else if (!filter) onChange(ramda.append(updatedFilter, filters));else onChange(replaceBy({
|
|
3131
|
+
}, filters));else if (!filter) onChange(ramda.append(updatedFilter, filters));else onChange(neetoCist.replaceBy({
|
|
4760
3132
|
key: key
|
|
4761
3133
|
}, updatedFilter, filters));
|
|
4762
3134
|
};
|
|
@@ -4855,19 +3227,6 @@ var Pane = function Pane(_ref) {
|
|
|
4855
3227
|
groupedColumns = _buildFilteredColumns2 === void 0 ? [] : _buildFilteredColumns2,
|
|
4856
3228
|
_buildFilteredColumns3 = _buildFilteredColumns.ungroupedColumns,
|
|
4857
3229
|
ungroupedColumns = _buildFilteredColumns3 === void 0 ? [] : _buildFilteredColumns3;
|
|
4858
|
-
var handleChange = function handleChange(newFilters) {
|
|
4859
|
-
var isClearAll = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
|
|
4860
|
-
var params = buildUrlFromFilters(_objectSpread$1({
|
|
4861
|
-
columns: columns,
|
|
4862
|
-
filters: isNotEmpty(getSearchTermFromUrl()) ? [].concat(_toConsumableArray(newFilters), [keywordFilter]) : newFilters
|
|
4863
|
-
}, isClearAll && {
|
|
4864
|
-
isClearAll: true,
|
|
4865
|
-
childrenKeys: childrenKeys
|
|
4866
|
-
}));
|
|
4867
|
-
history.push({
|
|
4868
|
-
search: params
|
|
4869
|
-
});
|
|
4870
|
-
};
|
|
4871
3230
|
var keywordFilter = _objectSpread$1(_objectSpread$1({
|
|
4872
3231
|
type: "text",
|
|
4873
3232
|
rule: "contains",
|
|
@@ -4882,8 +3241,21 @@ var Pane = function Pane(_ref) {
|
|
|
4882
3241
|
keywordFilter: keywordFilter,
|
|
4883
3242
|
onSelectorsChange: onSelectorsChange
|
|
4884
3243
|
});
|
|
3244
|
+
var handleChange = function handleChange(newFilters) {
|
|
3245
|
+
var isClearAll = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
|
|
3246
|
+
var params = buildUrlFromFilters(_objectSpread$1({
|
|
3247
|
+
columns: columns,
|
|
3248
|
+
filters: isKeywordFilterPresent(keywordFilter) && neetoCist.isNotEmpty(getSearchTermFromUrl()) ? [].concat(_toConsumableArray(newFilters), [keywordFilter]) : newFilters
|
|
3249
|
+
}, isClearAll && {
|
|
3250
|
+
isClearAll: true,
|
|
3251
|
+
childrenKeys: childrenKeys
|
|
3252
|
+
}));
|
|
3253
|
+
history.push({
|
|
3254
|
+
search: params
|
|
3255
|
+
});
|
|
3256
|
+
};
|
|
4885
3257
|
var handleClearAll = function handleClearAll() {
|
|
4886
|
-
var params = ramda.omit(["search_term"], utils.getQueryParams());
|
|
3258
|
+
var params = isKeywordFilterPresent(keywordFilter) ? ramda.omit(["search_term"], utils.getQueryParams()) : utils.getQueryParams();
|
|
4887
3259
|
var pathname = window.location.pathname;
|
|
4888
3260
|
history.push(utils.buildUrl(pathname, params));
|
|
4889
3261
|
handleChange([], true);
|
|
@@ -4891,7 +3263,7 @@ var Pane = function Pane(_ref) {
|
|
|
4891
3263
|
var handleClose = function handleClose() {
|
|
4892
3264
|
columns.forEach(function (_ref2) {
|
|
4893
3265
|
var key = _ref2.key;
|
|
4894
|
-
var filter = findBy({
|
|
3266
|
+
var filter = neetoCist.findBy({
|
|
4895
3267
|
key: key
|
|
4896
3268
|
}, filters);
|
|
4897
3269
|
if ((filter === null || filter === void 0 ? void 0 : filter.value) === "") delete searchParams[key];
|
|
@@ -4901,13 +3273,13 @@ var Pane = function Pane(_ref) {
|
|
|
4901
3273
|
var isClearFiltersDisabled = !filters.some(function (_ref3) {
|
|
4902
3274
|
var value = _ref3.value,
|
|
4903
3275
|
defaultValue = _ref3.defaultValue;
|
|
4904
|
-
return isPresent(value) && value !== defaultValue;
|
|
3276
|
+
return neetoCist.isPresent(value) && value !== defaultValue;
|
|
4905
3277
|
}) && !childrenKeys.some(function (key) {
|
|
4906
3278
|
return searchParams[key];
|
|
4907
3279
|
});
|
|
4908
3280
|
return /*#__PURE__*/React__default["default"].createElement(Portal, {
|
|
4909
3281
|
rootId: "neeto-filters-portal"
|
|
4910
|
-
}, /*#__PURE__*/React__default["default"].createElement(Slider, _extends
|
|
3282
|
+
}, /*#__PURE__*/React__default["default"].createElement(Slider, _extends({
|
|
4911
3283
|
isOpen: isOpen,
|
|
4912
3284
|
size: size,
|
|
4913
3285
|
onClose: handleClose
|
|
@@ -4936,10 +3308,10 @@ var Pane = function Pane(_ref) {
|
|
|
4936
3308
|
key: column.key,
|
|
4937
3309
|
onChange: handleChange
|
|
4938
3310
|
});
|
|
4939
|
-
}), isPresent(groupedColumns) && /*#__PURE__*/React__default["default"].createElement(neetoui.Accordion, {
|
|
3311
|
+
}), neetoCist.isPresent(groupedColumns) && /*#__PURE__*/React__default["default"].createElement(neetoui.Accordion, {
|
|
4940
3312
|
defaultActiveKey: groupedColumns.findIndex(function (_ref4) {
|
|
4941
3313
|
var columns = _ref4.columns;
|
|
4942
|
-
return existsBy({
|
|
3314
|
+
return neetoCist.existsBy({
|
|
4943
3315
|
key: isOpen
|
|
4944
3316
|
}, columns);
|
|
4945
3317
|
})
|
|
@@ -4980,7 +3352,7 @@ var Pane = function Pane(_ref) {
|
|
|
4980
3352
|
|
|
4981
3353
|
var e=[],t=[];function n(n,r){if(n&&"undefined"!=typeof document){var a,s=!0===r.prepend?"prepend":"append",d=!0===r.singleTag,i="string"==typeof r.container?document.querySelector(r.container):document.getElementsByTagName("head")[0];if(d){var u=e.indexOf(i);-1===u&&(u=e.push(i)-1,t[u]={}),a=t[u]&&t[u][s]?t[u][s]:t[u][s]=c();}else a=c();65279===n.charCodeAt(0)&&(n=n.substring(1)),a.styleSheet?a.styleSheet.cssText+=n:a.appendChild(document.createTextNode(n));}function c(){var e=document.createElement("style");if(e.setAttribute("type","text/css"),r.attributes)for(var t=Object.keys(r.attributes),n=0;n<t.length;n++)e.setAttribute(t[n],r.attributes[t[n]]);var a="prepend"===s?"afterbegin":"beforeend";return i.insertAdjacentElement(a,e),e}}
|
|
4982
3354
|
|
|
4983
|
-
var css = ".neeto-filters-bar{align-items:center;display:flex;flex-wrap:wrap}.neeto-filters-bar__block{border-radius:var(--neeto-ui-rounded);display:flex;gap:4px;margin:4px 0;max-width:384px;overflow:hidden;padding:4px 8px;position:relative;transition:var(--neeto-ui-transition);white-space:nowrap}.neeto-filters-bar__block p:first-child{color:rgb(var(--neeto-ui-gray-700))}.neeto-filters-bar__block-close{background-image:linear-gradient(90deg,rgba(var(--neeto-ui-gray-200),.5) 0,rgba(var(--neeto-ui-gray-200),1) 25%);color:rgb(var(--neeto-ui-gray-800));opacity:0;padding:8px;position:absolute;right:0;top:0;transition:var(--neeto-ui-transition)}.neeto-filters-bar__block:active,.neeto-filters-bar__block:hover{background-color:rgb(var(--neeto-ui-gray-200));cursor:pointer}.neeto-filters-bar__block:active .neeto-filters-bar__block-close,.neeto-filters-bar__block:hover .neeto-filters-bar__block-close{border-radius:var(--neeto-ui-rounded);color:rgb(var(--neeto-ui-black));opacity:1}.neeto-filters-bar__block:focus{box-shadow:0 0 0 3px rgba(var(--neeto-ui-gray-800),15%);outline:none}.neeto-filters-bar--separator{align-self:stretch;border-left:1px solid rgb(var(--neeto-ui-gray-400));margin:12px 8px}.neeto-filters-slider__pane{border-radius:12px 0 0 12px;position:fixed;right:0;top:0;z-index:99998}.neeto-filters-slider__wrapper{background-color:rgb(var(--neeto-ui-white));box-shadow:var(--neeto-ui-shadow-m);height:100vh;max-width:100%;transform:translateX(100%);transition:all .3s}.neeto-filters-slider__wrapper--xsmall{width:360px}.neeto-filters-slider__wrapper--small{width:480px}.neeto-filters-slider__wrapper--large{width:50vw}@media screen and (max-width:767px){.neeto-filters-slider__wrapper{width:100vw}}.neeto-filters-slider__close{position:absolute!important;right:24px;top:24px}.neeto-filters-slider__header{padding:24px 60px 24px 24px;width:100%}.neeto-filters-slider__body{font-size:var(--neeto-ui-text-sm);height:calc(100vh - var(--neeto-ui-pane-header-height));overflow-y:auto;padding:0 24px;width:100%}.neeto-filters-slider__body.neeto-filters-slider__body--has-footer{height:calc(100vh - var(--neeto-ui-pane-header-height) - var(--neeto-ui-pane-footer-height))}.neeto-filters-slider__footer{background-color:rgb(var(--neeto-ui-white));min-height:var(--neeto-ui-pane-footer-height);padding:24px;width:100%}.neeto-filters-slider__footer.neeto-filters-slider__footer__absolute{bottom:0;left:0;position:absolute;width:100%}.neeto-filters-slider-enter .neeto-filters-slider__wrapper{transform:translateX(100%)}.neeto-filters-slider-enter-active .neeto-filters-slider__wrapper,.neeto-filters-slider-enter-done .neeto-filters-slider__wrapper{transform:translateX(0)}.neeto-filters-slider-exit .neeto-filters-slider__wrapper,.neeto-filters-slider-exit-active .neeto-filters-slider__wrapper{transform:translateX(100%)}.neeto-filters-pane-filter__body{align-items:stretch!important;gap:20px}.neeto-filters-pane-filter__body>*{flex-grow:0!important}.neeto-filters-pane-filter__body p{text-align:center}.neeto-filters-pane-filter__body .neeto-filters-pane-filter__item-wrapper{display:flex;flex-direction:column;gap:8px}.neeto-filters-pane-filter__body .accordion_item .neeto-filters-pane-filter__item-wrapper{margin-top:16px}.neeto-filters-pane-filter__body .accordion_item .neeto-filters-pane-filter__item-wrapper:first-of-type{margin-top:0}.neeto-filters-pane-filter__body .accordion_item .neeto-ui-input__wrapper{margin-top:16px}.neeto-filters-pane-filter__body .accordion_item .neeto-ui-input__wrapper:first-of-type{margin-top:0}.neeto-filters-pane-filter__body .accordion_item:first-of-type .neeto-ui-accordion__item{padding-top:0}.neeto-filters-pane-filter__body .neeto-ui-accordion__wrapper--last-item{border-bottom:thin solid rgb(var(--neeto-ui-gray-300))}.neeto-filters-pane-filter__footer{justify-content:space-between}.neeto-filters-pane-filter__footer div{display:flex;gap:8px}\n/*# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInNyYy9zdHlsZXNoZWV0cy9jb21wb25lbnRzL19iYXIuc2NzcyIsInNyYy9zdHlsZXNoZWV0cy9pbmRleC5zY3NzIiwic3JjL3N0eWxlc2hlZXRzL2NvbXBvbmVudHMvX3NsaWRlci5zY3NzIiwic3JjL3N0eWxlc2hlZXRzL2Fic3RyYWN0cy9fbWl4aW5zLnNjc3MiLCJzcmMvc3R5bGVzaGVldHMvY29tcG9uZW50cy9fZmlsdGVycy5zY3NzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLG1CQUdFLGtCQUFBLENBRkEsWUFBQSxDQUNBLGNDRUYsQ0RDRSwwQkFLRSxxQ0FBQSxDQUhBLFlBQUEsQ0FFQSxPQUFBLENBR0EsWUFBQSxDQUNBLGVBQUEsQ0FFQSxlQUFBLENBVEEsZUFBQSxDQUVBLGlCQUFBLENBR0EscUNBQUEsQ0FHQSxrQkNFSixDRENJLHdDQUNFLG1DQ0NOLENERUksZ0NBUUUsZ0hBQUEsQ0FGQSxtQ0FBQSxDQURBLFNBQUEsQ0FEQSxXQUFBLENBSEEsaUJBQUEsQ0FFQSxPQUFBLENBREEsS0FBQSxDQUtBLHFDQ0NOLENET0ksaUVBRUUsOENBQUEsQ0FDQSxjQ05OLENEUU0saUlBR0UscUNBQUEsQ0FEQSxnQ0FBQSxDQURBLFNDSlIsQ0RVSSxnQ0FFRSx1REFBQSxDQURBLFlDUE4sQ0RZRSw4QkFHRSxrQkFBQSxDQUZBLG1EQUFBLENBQ0EsZUNUSixDQzlDRSw0QkFJRSwyQkFBQSxDQUhBLG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Zmlyc3Qtb2YtdHlwZSB7XG4gICAgICAgICAgbWFyZ2luLXRvcDogMDtcbiAgICAgICAgfVxuICAgICAgfVxuXG4gICAgICAmOmZpcnN0LW9mLXR5cGUge1xuICAgICAgICAubmVldG8tdWktYWNjb3JkaW9uX19pdGVtIHtcbiAgICAgICAgICBwYWRkaW5nLXRvcDogMDtcbiAgICAgICAgfVxuICAgICAgfVxuICAgIH1cbiAgICAubmVldG8tdWktYWNjb3JkaW9uX193cmFwcGVyLS1sYXN0LWl0ZW0ge1xuICAgICAgYm9yZGVyLWJvdHRvbTogdGhpbiBzb2xpZCByZ2IodmFyKC0tbmVldG8tdWktZ3JheS0zMDApKTtcbiAgICB9XG4gIH1cblxuICAmX19mb290ZXIge1xuICAgIGp1c3RpZnktY29udGVudDogc3BhY2UtYmV0d2VlbjtcblxuICAgIGRpdiB7XG4gICAgICBkaXNwbGF5OiBmbGV4O1xuICAgICAgZ2FwOiA4cHg7XG4gICAgfVxuICB9XG59XG4iXX0= */";
|
|
3355
|
+
var css = ".neeto-filters-bar{align-items:center;display:flex;flex-wrap:wrap}.neeto-filters-bar__block{border-radius:var(--neeto-ui-rounded);display:flex;gap:4px;margin:4px 0;max-width:384px;overflow:hidden;padding:4px 8px;position:relative;transition:var(--neeto-ui-transition);white-space:nowrap}.neeto-filters-bar__block p:first-child{color:rgb(var(--neeto-ui-gray-700))}.neeto-filters-bar__block-close{background-image:linear-gradient(90deg,rgba(var(--neeto-ui-gray-200),.5) 0,rgba(var(--neeto-ui-gray-200),1) 25%);color:rgb(var(--neeto-ui-gray-800));opacity:0;padding:8px;position:absolute;right:0;top:0;transition:var(--neeto-ui-transition)}.neeto-filters-bar__block:active,.neeto-filters-bar__block:hover{background-color:rgb(var(--neeto-ui-gray-200));cursor:pointer}.neeto-filters-bar__block:active .neeto-filters-bar__block-close,.neeto-filters-bar__block:hover .neeto-filters-bar__block-close{border-radius:var(--neeto-ui-rounded);color:rgb(var(--neeto-ui-black));opacity:1}.neeto-filters-bar__block:focus{box-shadow:0 0 0 3px rgba(var(--neeto-ui-gray-800),15%);outline:none}.neeto-filters-bar--separator{align-self:stretch;border-left:1px solid rgb(var(--neeto-ui-gray-400));margin:12px 8px}.neeto-filters-slider__pane{border-radius:12px 0 0 12px;position:fixed;right:0;top:0;z-index:99998}.neeto-filters-slider__wrapper{background-color:rgb(var(--neeto-ui-white));box-shadow:var(--neeto-ui-shadow-m);height:100vh;max-width:100%;transform:translateX(100%);transition:all .3s}.neeto-filters-slider__wrapper--xsmall{width:360px}.neeto-filters-slider__wrapper--small{width:480px}.neeto-filters-slider__wrapper--large{width:50vw}@media screen and (max-width:767px){.neeto-filters-slider__wrapper{width:100vw}}.neeto-filters-slider__close{position:absolute!important;right:24px;top:24px}.neeto-filters-slider__header{padding:24px 60px 24px 24px;width:100%}.neeto-filters-slider__body{font-size:var(--neeto-ui-text-sm);height:calc(100vh - var(--neeto-ui-pane-header-height));overflow-y:auto;padding:0 24px;width:100%}.neeto-filters-slider__body.neeto-filters-slider__body--has-footer{height:calc(100vh - var(--neeto-ui-pane-header-height) - var(--neeto-ui-pane-footer-height))}.neeto-filters-slider__footer{background-color:rgb(var(--neeto-ui-white));min-height:var(--neeto-ui-pane-footer-height);padding:24px;width:100%}.neeto-filters-slider__footer.neeto-filters-slider__footer__absolute{bottom:0;left:0;position:absolute;width:100%}.neeto-filters-slider-enter .neeto-filters-slider__wrapper{transform:translateX(100%)}.neeto-filters-slider-enter-active .neeto-filters-slider__wrapper,.neeto-filters-slider-enter-done .neeto-filters-slider__wrapper{transform:translateX(0)}.neeto-filters-slider-exit .neeto-filters-slider__wrapper,.neeto-filters-slider-exit-active .neeto-filters-slider__wrapper{transform:translateX(100%)}.neeto-filters-pane-filter__body{align-items:stretch!important;gap:20px}.neeto-filters-pane-filter__body>*{flex-grow:0!important}.neeto-filters-pane-filter__body p{text-align:center}.neeto-filters-pane-filter__body .neeto-filters-pane-filter__item-wrapper{display:flex;flex-direction:column;gap:8px}.neeto-filters-pane-filter__body .accordion_item .neeto-filters-pane-filter__item-wrapper{margin-top:16px}.neeto-filters-pane-filter__body .accordion_item .neeto-filters-pane-filter__item-wrapper:first-of-type{margin-top:0}.neeto-filters-pane-filter__body .accordion_item .neeto-ui-input__wrapper{margin-top:16px}.neeto-filters-pane-filter__body .accordion_item .neeto-ui-input__wrapper:first-of-type{margin-top:0}.neeto-filters-pane-filter__body .accordion_item:first-of-type .neeto-ui-accordion__item{padding-top:0}.neeto-filters-pane-filter__body .neeto-ui-accordion__wrapper--last-item{border-bottom:thin solid rgb(var(--neeto-ui-gray-300))}.neeto-filters-pane-filter__footer{justify-content:space-between}.neeto-filters-pane-filter__footer div{display:flex;gap:8px}\n/*# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbImFwcC9qYXZhc2NyaXB0L3NyYy9zdHlsZXNoZWV0cy9jb21wb25lbnRzL19iYXIuc2NzcyIsImFwcC9qYXZhc2NyaXB0L3NyYy9zdHlsZXNoZWV0cy9pbmRleC5zY3NzIiwiYXBwL2phdmFzY3JpcHQvc3JjL3N0eWxlc2hlZXRzL2NvbXBvbmVudHMvX3NsaWRlci5zY3NzIiwiYXBwL2phdmFzY3JpcHQvc3JjL3N0eWxlc2hlZXRzL2Fic3RyYWN0cy9fbWl4aW5zLnNjc3MiLCJhcHAvamF2YXNjcmlwdC9zcmMvc3R5bGVzaGVldHMvY29tcG9uZW50cy9fZmlsdGVycy5zY3NzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLG1CQUdFLGtCQUFBLENBRkEsWUFBQSxDQUNBLGNDRUYsQ0RDRSwwQkFLRSxxQ0FBQSxDQUhBLFlBQUEsQ0FFQSxPQUFBLENBR0EsWUFBQSxDQUNBLGVBQUEsQ0FFQSxlQUFBLENBVEEsZUFBQSxDQUVBLGlCQUFBLENBR0EscUNBQUEsQ0FHQSxrQkNFSixDRENJLHdDQUNFLG1DQ0NOLENERUksZ0NBUUUsZ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G5cbiAgICAuYWNjb3JkaW9uX2l0ZW0ge1xuICAgICAgLm5lZXRvLWZpbHRlcnMtcGFuZS1maWx0ZXJfX2l0ZW0td3JhcHBlciB7XG4gICAgICAgIG1hcmdpbi10b3A6IDE2cHg7XG5cbiAgICAgICAgJjpmaXJzdC1vZi10eXBlIHtcbiAgICAgICAgICBtYXJnaW4tdG9wOiAwO1xuICAgICAgICB9XG4gICAgICB9XG4gICAgICAubmVldG8tdWktaW5wdXRfX3dyYXBwZXIge1xuICAgICAgICBtYXJnaW4tdG9wOiAxNnB4O1xuXG4gICAgICAgICY6Zmlyc3Qtb2YtdHlwZSB7XG4gICAgICAgICAgbWFyZ2luLXRvcDogMDtcbiAgICAgICAgfVxuICAgICAgfVxuXG4gICAgICAmOmZpcnN0LW9mLXR5cGUge1xuICAgICAgICAubmVldG8tdWktYWNjb3JkaW9uX19pdGVtIHtcbiAgICAgICAgICBwYWRkaW5nLXRvcDogMDtcbiAgICAgICAgfVxuICAgICAgfVxuICAgIH1cbiAgICAubmVldG8tdWktYWNjb3JkaW9uX193cmFwcGVyLS1sYXN0LWl0ZW0ge1xuICAgICAgYm9yZGVyLWJvdHRvbTogdGhpbiBzb2xpZCByZ2IodmFyKC0tbmVldG8tdWktZ3JheS0zMDApKTtcbiAgICB9XG4gIH1cblxuICAmX19mb290ZXIge1xuICAgIGp1c3RpZnktY29udGVudDogc3BhY2UtYmV0d2VlbjtcblxuICAgIGRpdiB7XG4gICAgICBkaXNwbGF5OiBmbGV4O1xuICAgICAgZ2FwOiA4cHg7XG4gICAgfVxuICB9XG59XG4iXX0= */";
|
|
4984
3356
|
n(css,{});
|
|
4985
3357
|
|
|
4986
3358
|
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
@@ -5004,25 +3376,25 @@ var Filters = reactUtils.withT(function (_ref) {
|
|
|
5004
3376
|
isSearchable = _ref$isSearchable === void 0 ? false : _ref$isSearchable,
|
|
5005
3377
|
className = _ref.className,
|
|
5006
3378
|
_ref$onSelectorsChang = _ref.onSelectorsChange,
|
|
5007
|
-
onSelectorsChange = _ref$onSelectorsChang === void 0 ? noop
|
|
3379
|
+
onSelectorsChange = _ref$onSelectorsChang === void 0 ? neetoCist.noop : _ref$onSelectorsChang,
|
|
5008
3380
|
_ref$keyword = _ref.keyword,
|
|
5009
3381
|
keyword = _ref$keyword === void 0 ? {
|
|
5010
3382
|
node: "",
|
|
5011
3383
|
value: "",
|
|
5012
|
-
setValue: noop
|
|
3384
|
+
setValue: neetoCist.noop
|
|
5013
3385
|
} : _ref$keyword,
|
|
5014
3386
|
childrenKeys = _ref.childrenKeys,
|
|
5015
3387
|
children = _ref.children;
|
|
5016
3388
|
return /*#__PURE__*/React__default["default"].createElement("span", {
|
|
5017
3389
|
className: classnames__default["default"](_defineProperty({}, className, className))
|
|
5018
|
-
}, /*#__PURE__*/React__default["default"].createElement(neetoui.Button, _extends
|
|
3390
|
+
}, /*#__PURE__*/React__default["default"].createElement(neetoui.Button, _extends({
|
|
5019
3391
|
"data-cy": "neeto-filters-toggle-btn",
|
|
5020
3392
|
label: t("neetoFilters.common.filter"),
|
|
5021
3393
|
style: "secondary",
|
|
5022
3394
|
onClick: function onClick() {
|
|
5023
3395
|
return setIsOpen(true);
|
|
5024
3396
|
}
|
|
5025
|
-
}, buttonProps)), /*#__PURE__*/React__default["default"].createElement(Pane, _extends
|
|
3397
|
+
}, buttonProps)), /*#__PURE__*/React__default["default"].createElement(Pane, _extends({
|
|
5026
3398
|
onClose: function onClose() {
|
|
5027
3399
|
return setIsOpen(false);
|
|
5028
3400
|
}
|
|
@@ -5085,7 +3457,8 @@ var DeleteAlert = function DeleteAlert(_ref) {
|
|
|
5085
3457
|
|
|
5086
3458
|
var Card = function Card(_ref) {
|
|
5087
3459
|
var segment = _ref.segment,
|
|
5088
|
-
columns = _ref.columns
|
|
3460
|
+
columns = _ref.columns,
|
|
3461
|
+
defaultSegmentName = _ref.defaultSegmentName;
|
|
5089
3462
|
var _useState = React.useState(false),
|
|
5090
3463
|
_useState2 = _slicedToArray(_useState, 2),
|
|
5091
3464
|
isEditing = _useState2[0],
|
|
@@ -5119,7 +3492,7 @@ var Card = function Card(_ref) {
|
|
|
5119
3492
|
initialValues: segment,
|
|
5120
3493
|
validateOnChange: true,
|
|
5121
3494
|
validateOnBlur: true,
|
|
5122
|
-
validationSchema:
|
|
3495
|
+
validationSchema: buildSegmentsValidationSchema(defaultSegmentName),
|
|
5123
3496
|
onSubmit: handleRename,
|
|
5124
3497
|
enableReinitialize: true
|
|
5125
3498
|
}
|
|
@@ -5137,6 +3510,7 @@ var Card = function Card(_ref) {
|
|
|
5137
3510
|
style: "body2"
|
|
5138
3511
|
}, segment.name), /*#__PURE__*/React__default["default"].createElement(neetoui.Dropdown, {
|
|
5139
3512
|
buttonStyle: "text",
|
|
3513
|
+
disabled: neetoCist.isNotPresent(segment.id),
|
|
5140
3514
|
icon: neetoIcons.MenuHorizontal,
|
|
5141
3515
|
size: "small"
|
|
5142
3516
|
}, /*#__PURE__*/React__default["default"].createElement(Menu, null, /*#__PURE__*/React__default["default"].createElement(MenuItem.Button, {
|
|
@@ -5164,7 +3538,8 @@ var ManagePane = function ManagePane(_ref) {
|
|
|
5164
3538
|
var isOpen = _ref.isOpen,
|
|
5165
3539
|
onClose = _ref.onClose,
|
|
5166
3540
|
entity = _ref.entity,
|
|
5167
|
-
columns = _ref.columns
|
|
3541
|
+
columns = _ref.columns,
|
|
3542
|
+
defaultSegmentName = _ref.defaultSegmentName;
|
|
5168
3543
|
var _useState = React.useState(""),
|
|
5169
3544
|
_useState2 = _slicedToArray(_useState, 2),
|
|
5170
3545
|
searchTerm = _useState2[0],
|
|
@@ -5197,12 +3572,17 @@ var ManagePane = function ManagePane(_ref) {
|
|
|
5197
3572
|
}
|
|
5198
3573
|
}), isLoading ? /*#__PURE__*/React__default["default"].createElement(neetoui.Spinner, {
|
|
5199
3574
|
className: "mx-auto mt-4"
|
|
5200
|
-
}) : /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null,
|
|
3575
|
+
}) : /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, /*#__PURE__*/React__default["default"].createElement(Card$1, {
|
|
3576
|
+
segment: {
|
|
3577
|
+
name: defaultSegmentName
|
|
3578
|
+
}
|
|
3579
|
+
}), ramda.isEmpty(segments) ? /*#__PURE__*/React__default["default"].createElement(neetoui.Typography, {
|
|
5201
3580
|
className: "mx-auto",
|
|
5202
3581
|
style: "body2"
|
|
5203
3582
|
}, t("neetoFilters.segments.noSegmentsFound")) : segments.map(function (segment) {
|
|
5204
3583
|
return /*#__PURE__*/React__default["default"].createElement(Card$1, {
|
|
5205
3584
|
columns: columns,
|
|
3585
|
+
defaultSegmentName: defaultSegmentName,
|
|
5206
3586
|
segment: segment,
|
|
5207
3587
|
key: segment.id
|
|
5208
3588
|
});
|
|
@@ -5214,7 +3594,8 @@ var ITEMS_MAX_COUNT = 20;
|
|
|
5214
3594
|
var MenuBlocks = function MenuBlocks(_ref) {
|
|
5215
3595
|
var entity = _ref.entity,
|
|
5216
3596
|
searchTerm = _ref.searchTerm,
|
|
5217
|
-
columns = _ref.columns
|
|
3597
|
+
columns = _ref.columns,
|
|
3598
|
+
defaultSegmentName = _ref.defaultSegmentName;
|
|
5218
3599
|
var _useState = React.useState(false),
|
|
5219
3600
|
_useState2 = _slicedToArray(_useState, 2),
|
|
5220
3601
|
showAll = _useState2[0],
|
|
@@ -5225,6 +3606,7 @@ var MenuBlocks = function MenuBlocks(_ref) {
|
|
|
5225
3606
|
t = _useTranslation.t;
|
|
5226
3607
|
var _Object$fromEntries = Object.fromEntries(new URLSearchParams(location.search)),
|
|
5227
3608
|
segmentId = _Object$fromEntries.segmentId;
|
|
3609
|
+
var appliedFilters = buildFiltersFromURL(columns);
|
|
5228
3610
|
var _useFetchSegments = useFetchSegments({
|
|
5229
3611
|
entity: entity,
|
|
5230
3612
|
searchTerm: searchTerm
|
|
@@ -5232,27 +3614,40 @@ var MenuBlocks = function MenuBlocks(_ref) {
|
|
|
5232
3614
|
_useFetchSegments$dat = _useFetchSegments.data,
|
|
5233
3615
|
segments = _useFetchSegments$dat === void 0 ? [] : _useFetchSegments$dat,
|
|
5234
3616
|
isLoading = _useFetchSegments.isLoading;
|
|
5235
|
-
var
|
|
3617
|
+
var clearAppliedFilters = function clearAppliedFilters() {
|
|
5236
3618
|
var _filters$, _filters$2;
|
|
5237
|
-
var
|
|
5238
|
-
|
|
5239
|
-
return ramda.equals(id, segmentId) ? history.push({
|
|
3619
|
+
var filters = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : appliedFilters;
|
|
3620
|
+
history.push({
|
|
5240
3621
|
search: buildUrlFromFilters({
|
|
5241
3622
|
columns: columns,
|
|
5242
3623
|
filters: [],
|
|
5243
3624
|
isClearAll: true,
|
|
5244
|
-
childrenKeys: ramda.pluck("key", filterBy({
|
|
3625
|
+
childrenKeys: ((_filters$ = filters[0]) === null || _filters$ === void 0 ? void 0 : _filters$.conditions) && ramda.pluck("key", neetoCist.filterBy({
|
|
5245
3626
|
node: "children"
|
|
5246
|
-
}, (_filters$ = filters[0]) === null || _filters$ === void 0 ? void 0 : _filters
|
|
3627
|
+
}, (_filters$2 = filters[0]) === null || _filters$2 === void 0 ? void 0 : _filters$2.conditions))
|
|
5247
3628
|
})
|
|
5248
|
-
})
|
|
3629
|
+
});
|
|
3630
|
+
};
|
|
3631
|
+
var applySelectedSegment = function applySelectedSegment(_ref2) {
|
|
3632
|
+
var _filters$3;
|
|
3633
|
+
var id = _ref2.id,
|
|
3634
|
+
filters = _ref2.filters;
|
|
3635
|
+
history.push({
|
|
5249
3636
|
search: buildUrlFromSegment({
|
|
5250
3637
|
columns: columns,
|
|
5251
|
-
filters: (_filters$
|
|
3638
|
+
filters: (_filters$3 = filters[0]) === null || _filters$3 === void 0 ? void 0 : _filters$3.conditions,
|
|
5252
3639
|
id: id
|
|
5253
3640
|
})
|
|
5254
3641
|
});
|
|
5255
3642
|
};
|
|
3643
|
+
var handleSelectSegment = function handleSelectSegment(_ref3) {
|
|
3644
|
+
var id = _ref3.id,
|
|
3645
|
+
filters = _ref3.filters;
|
|
3646
|
+
return ramda.equals(id, segmentId) ? clearAppliedFilters(filters) : applySelectedSegment({
|
|
3647
|
+
id: id,
|
|
3648
|
+
filters: filters
|
|
3649
|
+
});
|
|
3650
|
+
};
|
|
5256
3651
|
if (isLoading) {
|
|
5257
3652
|
return /*#__PURE__*/React__default["default"].createElement(neetoui.Spinner, null);
|
|
5258
3653
|
}
|
|
@@ -5272,6 +3667,10 @@ var MenuBlocks = function MenuBlocks(_ref) {
|
|
|
5272
3667
|
return !open;
|
|
5273
3668
|
});
|
|
5274
3669
|
}
|
|
3670
|
+
}), /*#__PURE__*/React__default["default"].createElement(MenuBar__default["default"].Block, {
|
|
3671
|
+
active: ramda.isEmpty(appliedFilters),
|
|
3672
|
+
label: defaultSegmentName,
|
|
3673
|
+
onClick: clearAppliedFilters
|
|
5275
3674
|
}), segments.slice(0, showAll ? segments.length : ITEMS_MAX_COUNT).map(function (segment) {
|
|
5276
3675
|
return /*#__PURE__*/React__default["default"].createElement(MenuBar__default["default"].Block, {
|
|
5277
3676
|
active: segment.id === segmentId,
|
|
@@ -5290,77 +3689,83 @@ var Segments = function Segments(_ref) {
|
|
|
5290
3689
|
var entity = _ref.entity,
|
|
5291
3690
|
columns = _ref.columns,
|
|
5292
3691
|
_ref$setIsFilterPaneO = _ref.setIsFilterPaneOpen,
|
|
5293
|
-
setIsFilterPaneOpen = _ref$setIsFilterPaneO === void 0 ? noop
|
|
5294
|
-
|
|
5295
|
-
|
|
5296
|
-
|
|
5297
|
-
|
|
5298
|
-
|
|
5299
|
-
|
|
5300
|
-
|
|
5301
|
-
|
|
5302
|
-
|
|
5303
|
-
|
|
5304
|
-
|
|
5305
|
-
|
|
5306
|
-
|
|
5307
|
-
|
|
5308
|
-
|
|
5309
|
-
|
|
5310
|
-
|
|
5311
|
-
|
|
5312
|
-
|
|
5313
|
-
|
|
5314
|
-
|
|
5315
|
-
|
|
5316
|
-
|
|
5317
|
-
|
|
5318
|
-
|
|
5319
|
-
|
|
5320
|
-
|
|
5321
|
-
|
|
5322
|
-
|
|
5323
|
-
|
|
5324
|
-
|
|
5325
|
-
|
|
5326
|
-
|
|
5327
|
-
|
|
5328
|
-
|
|
5329
|
-
|
|
5330
|
-
|
|
5331
|
-
|
|
5332
|
-
|
|
5333
|
-
|
|
5334
|
-
|
|
5335
|
-
|
|
5336
|
-
|
|
5337
|
-
|
|
5338
|
-
|
|
5339
|
-
|
|
5340
|
-
|
|
5341
|
-
|
|
5342
|
-
|
|
5343
|
-
|
|
5344
|
-
|
|
5345
|
-
|
|
5346
|
-
|
|
5347
|
-
|
|
5348
|
-
|
|
5349
|
-
|
|
5350
|
-
|
|
5351
|
-
|
|
5352
|
-
|
|
5353
|
-
|
|
5354
|
-
|
|
5355
|
-
|
|
5356
|
-
|
|
5357
|
-
|
|
5358
|
-
|
|
5359
|
-
|
|
5360
|
-
|
|
5361
|
-
|
|
5362
|
-
|
|
5363
|
-
|
|
3692
|
+
setIsFilterPaneOpen = _ref$setIsFilterPaneO === void 0 ? neetoCist.noop : _ref$setIsFilterPaneO,
|
|
3693
|
+
_ref$defaultSegmentNa = _ref.defaultSegmentName,
|
|
3694
|
+
defaultSegmentName = _ref$defaultSegmentNa === void 0 ? i18next.t("neetoFilters.common.allResults") : _ref$defaultSegmentNa;
|
|
3695
|
+
return function () {
|
|
3696
|
+
var _useState = React.useState(""),
|
|
3697
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
3698
|
+
searchTerm = _useState2[0],
|
|
3699
|
+
setSearchTerm = _useState2[1];
|
|
3700
|
+
var _useState3 = React.useState(true),
|
|
3701
|
+
_useState4 = _slicedToArray(_useState3, 2),
|
|
3702
|
+
isSearchCollapsed = _useState4[0],
|
|
3703
|
+
setIsSearchCollapsed = _useState4[1];
|
|
3704
|
+
var _useState5 = React.useState(false),
|
|
3705
|
+
_useState6 = _slicedToArray(_useState5, 2),
|
|
3706
|
+
isSegmentsPaneOpen = _useState6[0],
|
|
3707
|
+
setIsSegmentsPaneOpen = _useState6[1];
|
|
3708
|
+
var _useTranslation = reactI18next.useTranslation(),
|
|
3709
|
+
t = _useTranslation.t;
|
|
3710
|
+
var debouncedSearchTerm = reactUtils.useDebounce(searchTerm);
|
|
3711
|
+
var iconProps = [{
|
|
3712
|
+
icon: neetoIcons.Search,
|
|
3713
|
+
onClick: function onClick() {
|
|
3714
|
+
setSearchTerm("");
|
|
3715
|
+
setIsSearchCollapsed(function (collapsed) {
|
|
3716
|
+
return !collapsed;
|
|
3717
|
+
});
|
|
3718
|
+
},
|
|
3719
|
+
tooltipProps: {
|
|
3720
|
+
content: t("neetoFilters.segments.searchSegments"),
|
|
3721
|
+
position: "top"
|
|
3722
|
+
}
|
|
3723
|
+
}, {
|
|
3724
|
+
icon: neetoIcons.Settings,
|
|
3725
|
+
onClick: function onClick() {
|
|
3726
|
+
setIsFilterPaneOpen(false);
|
|
3727
|
+
setIsSegmentsPaneOpen(true);
|
|
3728
|
+
},
|
|
3729
|
+
tooltipProps: {
|
|
3730
|
+
content: t("neetoFilters.segments.manageSegments"),
|
|
3731
|
+
position: "top"
|
|
3732
|
+
}
|
|
3733
|
+
}];
|
|
3734
|
+
return /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, /*#__PURE__*/React__default["default"].createElement(MenuBar__default["default"].SubTitle, {
|
|
3735
|
+
iconProps: iconProps
|
|
3736
|
+
}, /*#__PURE__*/React__default["default"].createElement(neetoui.Typography, {
|
|
3737
|
+
component: "h4",
|
|
3738
|
+
style: "h5",
|
|
3739
|
+
textTransform: "uppercase",
|
|
3740
|
+
weight: "bold"
|
|
3741
|
+
}, t("neetoFilters.common.segments"))), /*#__PURE__*/React__default["default"].createElement(MenuBar__default["default"].Search, {
|
|
3742
|
+
autoFocus: true,
|
|
3743
|
+
isCollapsed: isSearchCollapsed,
|
|
3744
|
+
placeholder: t("neetoFilters.segments.searchSegments"),
|
|
3745
|
+
value: searchTerm,
|
|
3746
|
+
onChange: function onChange(_ref2) {
|
|
3747
|
+
var value = _ref2.target.value;
|
|
3748
|
+
return setSearchTerm(value);
|
|
3749
|
+
},
|
|
3750
|
+
onCollapse: function onCollapse() {
|
|
3751
|
+
setSearchTerm("");
|
|
3752
|
+
setIsSearchCollapsed(true);
|
|
3753
|
+
}
|
|
3754
|
+
}), /*#__PURE__*/React__default["default"].createElement(MenuBlocks$1, {
|
|
3755
|
+
columns: columns,
|
|
3756
|
+
defaultSegmentName: defaultSegmentName,
|
|
3757
|
+
entity: entity,
|
|
3758
|
+
searchTerm: debouncedSearchTerm
|
|
3759
|
+
}), /*#__PURE__*/React__default["default"].createElement(ManagePane, {
|
|
3760
|
+
columns: columns,
|
|
3761
|
+
defaultSegmentName: defaultSegmentName,
|
|
3762
|
+
entity: entity,
|
|
3763
|
+
isOpen: isSegmentsPaneOpen,
|
|
3764
|
+
onClose: function onClose() {
|
|
3765
|
+
return setIsSegmentsPaneOpen(false);
|
|
3766
|
+
}
|
|
3767
|
+
}));
|
|
3768
|
+
}();
|
|
5364
3769
|
};
|
|
5365
3770
|
var index = /*#__PURE__*/React__default["default"].memo(Segments);
|
|
5366
3771
|
|