@appbaseio/reactivesearch-vue 1.33.1 → 1.33.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/@appbaseio/reactivesearch-vue.umd.js +2888 -6530
- package/dist/@appbaseio/reactivesearch-vue.umd.js.map +1 -1
- package/dist/@appbaseio/reactivesearch-vue.umd.min.js +7 -9
- package/dist/@appbaseio/reactivesearch-vue.umd.min.js.map +1 -1
- package/dist/cjs/{Button-0673191e.js → Button-841fd06d.js} +1 -7
- package/dist/cjs/{CancelSvg-9f258f4f.js → CancelSvg-220a7cc3.js} +24 -58
- package/dist/cjs/{Card-642547a8.js → Card-240f283d.js} +2 -2
- package/dist/cjs/{ComponentWrapper-981ab977.js → ComponentWrapper-9318cece.js} +21 -41
- package/dist/cjs/{Container-daf30918.js → Container-e699ea95.js} +1 -1
- package/dist/cjs/{DataSearch-c42d8681.js → DataSearch-e4822dbf.js} +131 -299
- package/dist/cjs/DataSearch.js +11 -11
- package/dist/cjs/{DropDown-c479bbb0.js → DropDown-8984b544.js} +27 -48
- package/dist/cjs/DynamicRangeSlider.js +44 -93
- package/dist/cjs/{Flex-aa517a13.js → Flex-ddd7cb6b.js} +1 -3
- package/dist/cjs/{FormControlList-c195a592.js → FormControlList-bbb5cd24.js} +1 -3
- package/dist/cjs/{Input-e6603a7e.js → Input-ead4cd84.js} +14 -16
- package/dist/cjs/{ListItem-8c9e0d68.js → ListItem-5088bd6a.js} +2 -3
- package/dist/cjs/MultiDropdownList.js +41 -102
- package/dist/cjs/MultiList.js +35 -98
- package/dist/cjs/MultiRange.js +27 -53
- package/dist/cjs/{Pagination-3d73e1b3.js → Pagination-07f4dbad.js} +10 -30
- package/dist/cjs/{PreferencesConsumer-4707bd94.js → PreferencesConsumer-5d67b486.js} +8 -18
- package/dist/cjs/RangeInput.js +36 -52
- package/dist/cjs/RangeSlider.js +24 -48
- package/dist/cjs/ReactiveBase.js +66 -81
- package/dist/cjs/{ReactiveComponent-63ef70c2.js → ReactiveComponent-b8efb0cf.js} +118 -301
- package/dist/cjs/ReactiveComponent.js +20 -20
- package/dist/cjs/ReactiveGoogleMap.js +167 -353
- package/dist/cjs/ReactiveList.js +88 -176
- package/dist/cjs/ResultCard.js +10 -18
- package/dist/cjs/ResultList.js +13 -24
- package/dist/cjs/SelectedFilters.js +16 -34
- package/dist/cjs/SingleDropdownList.js +35 -75
- package/dist/cjs/SingleList.js +29 -75
- package/dist/cjs/SingleRange.js +17 -40
- package/dist/cjs/StateProvider.js +28 -32
- package/dist/cjs/{Title-1de7d0f4.js → Title-16042ea0.js} +1 -1
- package/dist/cjs/ToggleButton.js +20 -58
- package/dist/cjs/{_rollupPluginBabelHelpers-c705cbe6.js → _rollupPluginBabelHelpers-f8b843f8.js} +0 -15
- package/dist/cjs/{index-08f8dfa3.js → index-30126fd0.js} +39 -75
- package/dist/cjs/index.js +21 -22
- package/dist/cjs/initReactivesearch.js +49 -120
- package/dist/cjs/install.js +21 -21
- package/dist/cjs/{ssr-3027b848.js → ssr-f2fc1bf6.js} +1 -4
- package/dist/cjs/{utils-d6a52588.js → utils-83fd01e9.js} +7 -16
- package/dist/cjs/version.js +1 -1
- package/dist/cjs/{vueTypes-727b7c63.js → vueTypes-7cfc2f98.js} +6 -11
- package/dist/es/{Button-35aa984e.js → Button-153cd885.js} +1 -7
- package/dist/es/{CancelSvg-4cfae5fd.js → CancelSvg-e40552a5.js} +24 -58
- package/dist/es/{Card-450683f1.js → Card-19ad6d90.js} +2 -2
- package/dist/es/{ComponentWrapper-d5e814a4.js → ComponentWrapper-240450cc.js} +21 -41
- package/dist/es/{Container-ba826e96.js → Container-d00219f7.js} +1 -1
- package/dist/es/{DataSearch-d56bf07a.js → DataSearch-5ddfba23.js} +131 -299
- package/dist/es/DataSearch.js +11 -11
- package/dist/es/{DropDown-05a644a5.js → DropDown-28ddce07.js} +27 -48
- package/dist/es/DynamicRangeSlider.js +44 -93
- package/dist/es/{Flex-1f0795c3.js → Flex-7c177a10.js} +1 -3
- package/dist/es/{FormControlList-c22d64f6.js → FormControlList-99797d0a.js} +1 -3
- package/dist/es/{Input-7a2a9fac.js → Input-c09c0b56.js} +14 -16
- package/dist/es/{ListItem-cad14c5e.js → ListItem-07888a65.js} +2 -3
- package/dist/es/MultiDropdownList.js +41 -102
- package/dist/es/MultiList.js +35 -98
- package/dist/es/MultiRange.js +27 -53
- package/dist/es/{Pagination-af9de08f.js → Pagination-28e56c5c.js} +10 -30
- package/dist/es/{PreferencesConsumer-4169deb1.js → PreferencesConsumer-bc097ebb.js} +8 -18
- package/dist/es/RangeInput.js +36 -52
- package/dist/es/RangeSlider.js +24 -48
- package/dist/es/ReactiveBase.js +66 -81
- package/dist/es/{ReactiveComponent-9e4721e1.js → ReactiveComponent-59107264.js} +118 -301
- package/dist/es/ReactiveComponent.js +20 -20
- package/dist/es/ReactiveGoogleMap.js +167 -353
- package/dist/es/ReactiveList.js +88 -176
- package/dist/es/ResultCard.js +10 -18
- package/dist/es/ResultList.js +13 -24
- package/dist/es/SelectedFilters.js +16 -34
- package/dist/es/SingleDropdownList.js +35 -75
- package/dist/es/SingleList.js +29 -75
- package/dist/es/SingleRange.js +17 -40
- package/dist/es/StateProvider.js +29 -33
- package/dist/es/{Title-3342664a.js → Title-863dfa42.js} +1 -1
- package/dist/es/ToggleButton.js +20 -58
- package/dist/es/{_rollupPluginBabelHelpers-76660dab.js → _rollupPluginBabelHelpers-ded08042.js} +0 -15
- package/dist/es/{index-99c5f9c9.js → index-0444a498.js} +39 -75
- package/dist/es/index.js +21 -22
- package/dist/es/initReactivesearch.js +49 -120
- package/dist/es/install.js +21 -21
- package/dist/es/{ssr-b2c0b401.js → ssr-03607d84.js} +1 -4
- package/dist/es/{utils-9e68acee.js → utils-9e5a16a1.js} +7 -16
- package/dist/es/version.js +1 -1
- package/dist/es/{vueTypes-b8146772.js → vueTypes-8986b709.js} +6 -11
- package/package.json +3 -2
|
@@ -1,75 +1,62 @@
|
|
|
1
1
|
import { helper } from '@appbaseio/reactivecore';
|
|
2
2
|
import { validProps } from '@appbaseio/reactivecore/lib/utils/constants';
|
|
3
|
-
import { a as _extends } from './_rollupPluginBabelHelpers-
|
|
3
|
+
import { a as _extends } from './_rollupPluginBabelHelpers-ded08042.js';
|
|
4
4
|
import { bindActionCreators } from 'redux';
|
|
5
5
|
|
|
6
6
|
// Credit to React-Redux for this util function
|
|
7
7
|
// https://github.com/reactjs/react-redux/blob/573db0bfc8d1d50fdb6e2a98bd8a7d4675fecf11/src/utils/shallowEqual.js
|
|
8
|
-
var hasOwn = Object.prototype.hasOwnProperty;
|
|
9
8
|
|
|
9
|
+
var hasOwn = Object.prototype.hasOwnProperty;
|
|
10
10
|
function is(x, y) {
|
|
11
11
|
if (x === y) {
|
|
12
12
|
return x !== 0 || y !== 0 || 1 / x === 1 / y;
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
|
|
13
|
+
}
|
|
14
|
+
// eslint-disable-next-line
|
|
16
15
|
return x !== x && y !== y;
|
|
17
16
|
}
|
|
18
|
-
|
|
19
17
|
function shallowEqual(objA, objB) {
|
|
20
18
|
if (is(objA, objB)) return true;
|
|
21
|
-
|
|
22
19
|
if (typeof objA !== 'object' || objA === null || typeof objB !== 'object' || objB === null) {
|
|
23
20
|
return false;
|
|
24
21
|
}
|
|
25
|
-
|
|
26
22
|
var keysA = Object.keys(objA);
|
|
27
23
|
var keysB = Object.keys(objB);
|
|
28
24
|
if (keysA.length !== keysB.length) return false;
|
|
29
|
-
|
|
30
25
|
for (var i = 0; i < keysA.length; i += 1) {
|
|
31
26
|
if (!hasOwn.call(objB, keysA[i]) || !is(objA[keysA[i]], objB[keysA[i]])) {
|
|
32
27
|
return false;
|
|
33
28
|
}
|
|
34
29
|
}
|
|
35
|
-
|
|
36
30
|
return true;
|
|
37
31
|
}
|
|
38
32
|
|
|
39
33
|
var defaultMapState = function defaultMapState() {
|
|
40
34
|
return {};
|
|
41
35
|
};
|
|
42
|
-
|
|
43
36
|
var defaultMapDispatch = {};
|
|
44
|
-
|
|
45
37
|
var normalizeMapState = function normalizeMapState(mapState) {
|
|
46
38
|
if (typeof mapState === 'function') return mapState;
|
|
47
|
-
|
|
48
39
|
if (mapState === Object(mapState)) {
|
|
49
40
|
return function (state, ownProps) {
|
|
50
41
|
return Object.keys(mapState).filter(function (key) {
|
|
51
42
|
return typeof mapState[key] === 'function';
|
|
52
43
|
}).reduce(function (map, key) {
|
|
53
44
|
var _extends2;
|
|
54
|
-
|
|
55
45
|
return _extends({}, map, (_extends2 = {}, _extends2[key] = mapState[key](state, ownProps), _extends2));
|
|
56
46
|
}, {});
|
|
57
47
|
};
|
|
58
48
|
}
|
|
59
|
-
|
|
60
49
|
throw new Error('[revux] - mapState provided to connect is invalid');
|
|
61
|
-
};
|
|
62
|
-
|
|
50
|
+
};
|
|
63
51
|
|
|
52
|
+
// eslint-disable-next-line
|
|
64
53
|
var connector = function connector(_mapState, mapDispatch) {
|
|
65
54
|
if (_mapState === void 0) {
|
|
66
55
|
_mapState = defaultMapState;
|
|
67
56
|
}
|
|
68
|
-
|
|
69
57
|
if (mapDispatch === void 0) {
|
|
70
58
|
mapDispatch = defaultMapDispatch;
|
|
71
59
|
}
|
|
72
|
-
|
|
73
60
|
return function (component) {
|
|
74
61
|
var mapState = normalizeMapState(_mapState);
|
|
75
62
|
return {
|
|
@@ -78,25 +65,20 @@ var connector = function connector(_mapState, mapDispatch) {
|
|
|
78
65
|
inject: ['$$store'],
|
|
79
66
|
data: function data() {
|
|
80
67
|
var merged = _extends({}, mapState(this.$$store.getState(), this.$props || {}), bindActionCreators(mapDispatch, this.$$store.dispatch));
|
|
81
|
-
|
|
82
68
|
return Object.keys(merged).reduce(function (data, key) {
|
|
83
69
|
var _extends3;
|
|
84
|
-
|
|
85
70
|
return _extends({}, data, (_extends3 = {}, _extends3[key] = merged[key], _extends3));
|
|
86
71
|
}, {});
|
|
87
72
|
},
|
|
88
73
|
created: function created() {
|
|
89
74
|
var _this = this;
|
|
90
|
-
|
|
91
75
|
var getMappedState = function getMappedState(state) {
|
|
92
76
|
return mapState(state, _this.$props || {});
|
|
93
77
|
};
|
|
94
|
-
|
|
95
78
|
var observeStore = function observeStore(store, select, onChange) {
|
|
96
79
|
var currentState = select(store.getState());
|
|
97
80
|
return store.subscribe(function () {
|
|
98
81
|
var nextState = select(store.getState());
|
|
99
|
-
|
|
100
82
|
if (!shallowEqual(currentState, nextState)) {
|
|
101
83
|
var previousState = currentState;
|
|
102
84
|
currentState = nextState;
|
|
@@ -104,7 +86,6 @@ var connector = function connector(_mapState, mapDispatch) {
|
|
|
104
86
|
}
|
|
105
87
|
});
|
|
106
88
|
};
|
|
107
|
-
|
|
108
89
|
this._unsubscribe = observeStore(this.$$store, getMappedState, function (newState) {
|
|
109
90
|
Object.keys(newState).forEach(function (key) {
|
|
110
91
|
_this.$set(_this, key, newState[key]);
|
|
@@ -119,13 +100,16 @@ var connector = function connector(_mapState, mapDispatch) {
|
|
|
119
100
|
};
|
|
120
101
|
|
|
121
102
|
var defaultQueryUtil = helper.updateDefaultQuery,
|
|
122
|
-
|
|
123
|
-
|
|
103
|
+
customQueryUtil = helper.updateCustomQuery,
|
|
104
|
+
isEqual = helper.isEqual;
|
|
105
|
+
|
|
106
|
+
// TODO
|
|
124
107
|
// import { storeKey } from '@appbaseio/reactivecore';
|
|
125
108
|
|
|
126
109
|
var connect = function connect() {
|
|
127
110
|
return connector.apply(void 0, arguments);
|
|
128
|
-
};
|
|
111
|
+
};
|
|
112
|
+
// connectToStore(...args, null, {
|
|
129
113
|
// storeKey,
|
|
130
114
|
// });
|
|
131
115
|
|
|
@@ -134,11 +118,9 @@ var composeThemeObject = function composeThemeObject(ownTheme, userTheme) {
|
|
|
134
118
|
if (ownTheme === void 0) {
|
|
135
119
|
ownTheme = {};
|
|
136
120
|
}
|
|
137
|
-
|
|
138
121
|
if (userTheme === void 0) {
|
|
139
122
|
userTheme = {};
|
|
140
123
|
}
|
|
141
|
-
|
|
142
124
|
return {
|
|
143
125
|
typography: _extends({}, ownTheme.typography, userTheme.typography),
|
|
144
126
|
colors: _extends({}, ownTheme.colors, userTheme.colors),
|
|
@@ -149,14 +131,13 @@ var composeThemeObject = function composeThemeObject(ownTheme, userTheme) {
|
|
|
149
131
|
* To determine wether an element is a function
|
|
150
132
|
* @param {any} element
|
|
151
133
|
*/
|
|
152
|
-
|
|
153
134
|
var isFunction = function isFunction(element) {
|
|
154
135
|
return typeof element === 'function';
|
|
155
|
-
};
|
|
136
|
+
};
|
|
156
137
|
|
|
138
|
+
// parses current array (i.e. this.$props.value) for `onChange` callback for multi-* components
|
|
157
139
|
function parseValueArray(objectValues, currentValue) {
|
|
158
140
|
var selectedValues;
|
|
159
|
-
|
|
160
141
|
if (Array.isArray(objectValues)) {
|
|
161
142
|
selectedValues = [].concat(objectValues);
|
|
162
143
|
} else {
|
|
@@ -165,33 +146,28 @@ function parseValueArray(objectValues, currentValue) {
|
|
|
165
146
|
return objectValues[key] ? key : null;
|
|
166
147
|
});
|
|
167
148
|
}
|
|
168
|
-
|
|
169
149
|
if (selectedValues.includes(currentValue)) {
|
|
170
150
|
return selectedValues.filter(function (item) {
|
|
171
151
|
return item !== currentValue;
|
|
172
152
|
});
|
|
173
153
|
}
|
|
174
|
-
|
|
175
154
|
return [].concat(selectedValues, [currentValue]);
|
|
176
155
|
}
|
|
156
|
+
|
|
177
157
|
/**
|
|
178
158
|
* Extracts the render prop from props or slot and returns a valid JSX element
|
|
179
159
|
* @param {Object} data
|
|
180
160
|
* @param _ref
|
|
181
161
|
*/
|
|
182
|
-
|
|
183
162
|
var getComponent = function getComponent(data, _ref) {
|
|
184
163
|
if (data === void 0) {
|
|
185
164
|
data = {};
|
|
186
165
|
}
|
|
187
|
-
|
|
188
166
|
if (_ref === void 0) {
|
|
189
167
|
_ref = {};
|
|
190
168
|
}
|
|
191
|
-
|
|
192
169
|
var _ref2 = _ref.$scopedSlots || _ref.$props,
|
|
193
|
-
|
|
194
|
-
|
|
170
|
+
render = _ref2.render;
|
|
195
171
|
if (render) return render(data);
|
|
196
172
|
return null;
|
|
197
173
|
};
|
|
@@ -199,22 +175,18 @@ var getComponent = function getComponent(data, _ref) {
|
|
|
199
175
|
* To determine whether a component has render prop or slot defined or not
|
|
200
176
|
* @returns {Boolean}
|
|
201
177
|
*/
|
|
202
|
-
|
|
203
178
|
var hasCustomRenderer = function hasCustomRenderer(_ref) {
|
|
204
179
|
if (_ref === void 0) {
|
|
205
180
|
_ref = {};
|
|
206
181
|
}
|
|
207
|
-
|
|
208
182
|
var _ref3 = _ref.$scopedSlots || _ref.$props,
|
|
209
|
-
|
|
210
|
-
|
|
183
|
+
render = _ref3.render;
|
|
211
184
|
return Boolean(render);
|
|
212
185
|
};
|
|
213
186
|
var getValidPropsKeys = function getValidPropsKeys(props) {
|
|
214
187
|
if (props === void 0) {
|
|
215
188
|
props = {};
|
|
216
189
|
}
|
|
217
|
-
|
|
218
190
|
return Object.keys(props).filter(function (i) {
|
|
219
191
|
return validProps.includes(i);
|
|
220
192
|
});
|
|
@@ -232,16 +204,16 @@ var updateCustomQuery = function updateCustomQuery(componentId, setCustomQuery,
|
|
|
232
204
|
setCustomQuery: setCustomQuery
|
|
233
205
|
}), value);
|
|
234
206
|
};
|
|
207
|
+
|
|
235
208
|
/**
|
|
236
209
|
* @param {Function} newVal
|
|
237
210
|
* @param {Function} oldVal
|
|
238
211
|
* @param {any} value
|
|
239
212
|
* @param {Object} props
|
|
240
213
|
*/
|
|
241
|
-
|
|
242
214
|
var isQueryIdentical = function isQueryIdentical(newVal, oldVal, value, props) {
|
|
243
|
-
if (typeof newVal !== 'function' || typeof oldVal !== 'function') return true;
|
|
244
|
-
|
|
215
|
+
if (typeof newVal !== 'function' || typeof oldVal !== 'function') return true;
|
|
216
|
+
// to not call original defaultQuery and customQuery, as here we are only comparing
|
|
245
217
|
return isEqual(oldVal(value, props), newVal(value, props));
|
|
246
218
|
};
|
|
247
219
|
/**
|
|
@@ -249,20 +221,16 @@ var isQueryIdentical = function isQueryIdentical(newVal, oldVal, value, props) {
|
|
|
249
221
|
* @param {Object} data
|
|
250
222
|
* @param _ref
|
|
251
223
|
*/
|
|
252
|
-
|
|
253
224
|
var getQuerySuggestionsComponent = function getQuerySuggestionsComponent(data, _ref) {
|
|
254
225
|
if (data === void 0) {
|
|
255
226
|
data = {};
|
|
256
227
|
}
|
|
257
|
-
|
|
258
228
|
if (_ref === void 0) {
|
|
259
229
|
_ref = {};
|
|
260
230
|
}
|
|
261
|
-
|
|
262
231
|
var _ref4 = _ref.$scopedSlots || _ref.$props,
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
232
|
+
renderQuerySuggestions = _ref4.renderQuerySuggestions,
|
|
233
|
+
renderPopularSuggestions = _ref4.renderPopularSuggestions;
|
|
266
234
|
var render = renderPopularSuggestions || renderQuerySuggestions;
|
|
267
235
|
if (render) return render(data);
|
|
268
236
|
return null;
|
|
@@ -271,33 +239,29 @@ var getQuerySuggestionsComponent = function getQuerySuggestionsComponent(data, _
|
|
|
271
239
|
* To determine whether a component has renderQuerySuggestions prop or slot defined or not
|
|
272
240
|
* @returns {Boolean}
|
|
273
241
|
*/
|
|
274
|
-
|
|
275
242
|
var hasQuerySuggestionsRenderer = function hasQuerySuggestionsRenderer(_ref) {
|
|
276
243
|
if (_ref === void 0) {
|
|
277
244
|
_ref = {};
|
|
278
245
|
}
|
|
279
|
-
|
|
280
246
|
var _ref5 = _ref.$scopedSlots || _ref.$props,
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
247
|
+
renderQuerySuggestions = _ref5.renderQuerySuggestions,
|
|
248
|
+
renderPopularSuggestions = _ref5.renderPopularSuggestions;
|
|
284
249
|
return Boolean(renderPopularSuggestions) || Boolean(renderQuerySuggestions);
|
|
285
250
|
};
|
|
251
|
+
|
|
286
252
|
/**
|
|
287
253
|
* To get the camel case string from kebab case
|
|
288
254
|
* @returns {string}
|
|
289
255
|
*/
|
|
290
|
-
|
|
291
256
|
var getCamelCase = function getCamelCase(str) {
|
|
292
257
|
if (str === void 0) {
|
|
293
258
|
str = '';
|
|
294
259
|
}
|
|
295
|
-
|
|
296
260
|
var arr = str.split('-');
|
|
297
261
|
var capital = arr.map(function (item, index) {
|
|
298
262
|
return index ? item.charAt(0).toUpperCase() + item.slice(1).toLowerCase() : item;
|
|
299
|
-
});
|
|
300
|
-
|
|
263
|
+
});
|
|
264
|
+
// ^-- change here.
|
|
301
265
|
var capitalString = capital.join('');
|
|
302
266
|
return capitalString || '';
|
|
303
267
|
};
|
|
@@ -306,22 +270,25 @@ var isEmpty = function isEmpty(val) {
|
|
|
306
270
|
};
|
|
307
271
|
function isNumeric(value) {
|
|
308
272
|
return /^-?\d+$/.test(value);
|
|
309
|
-
}
|
|
273
|
+
}
|
|
310
274
|
|
|
275
|
+
// check if passed shortcut a key combination
|
|
311
276
|
function isHotkeyCombination(hotkey) {
|
|
312
277
|
return typeof hotkey === 'string' && hotkey.indexOf('+') !== -1;
|
|
313
|
-
}
|
|
278
|
+
}
|
|
279
|
+
|
|
280
|
+
// used for getting correct string char from keycode passed
|
|
314
281
|
// the below algebraic expression is used to get the correct ascii code out of the e.which || e.keycode returned value
|
|
315
282
|
// since the keyboards doesn't understand ascii but scan codes and they differ for certain keys such as '/'
|
|
316
283
|
// stackoverflow ref: https://stackoverflow.com/a/29811987/10822996
|
|
317
|
-
|
|
318
284
|
function getCharFromCharCode(passedCharCode) {
|
|
319
285
|
var which = passedCharCode;
|
|
320
286
|
var chrCode = which - 48 * Math.floor(which / 48);
|
|
321
287
|
return String.fromCharCode(which >= 96 ? chrCode : which);
|
|
322
|
-
}
|
|
323
|
-
// returns focusShortcuts containing appropriate key charsas depicted on keyboards
|
|
288
|
+
}
|
|
324
289
|
|
|
290
|
+
// used for parsing focusshortcuts for keycodes passed as string, eg: 'ctrl+/' is same as 'ctrl+47'
|
|
291
|
+
// returns focusShortcuts containing appropriate key charsas depicted on keyboards
|
|
325
292
|
function parseFocusShortcuts(focusShortcutsArray) {
|
|
326
293
|
if (isEmpty(focusShortcutsArray)) return [];
|
|
327
294
|
var parsedFocusShortcutsArray = [];
|
|
@@ -330,10 +297,9 @@ function parseFocusShortcuts(focusShortcutsArray) {
|
|
|
330
297
|
if (isHotkeyCombination(element)) {
|
|
331
298
|
// splitting the combination into pieces
|
|
332
299
|
var splitCombination = element.split('+');
|
|
333
|
-
var parsedSplitCombination = [];
|
|
334
|
-
|
|
300
|
+
var parsedSplitCombination = [];
|
|
301
|
+
// parsedCombination would have all the keycodes converted into chars
|
|
335
302
|
var parsedCombination = '';
|
|
336
|
-
|
|
337
303
|
for (var i = 0; i < splitCombination.length; i += 1) {
|
|
338
304
|
if (isNumeric(splitCombination[i])) {
|
|
339
305
|
parsedSplitCombination.push(getCharFromCharCode(+splitCombination[i]));
|
|
@@ -341,7 +307,6 @@ function parseFocusShortcuts(focusShortcutsArray) {
|
|
|
341
307
|
parsedSplitCombination.push(splitCombination[i]);
|
|
342
308
|
}
|
|
343
309
|
}
|
|
344
|
-
|
|
345
310
|
parsedCombination = parsedSplitCombination.join('+');
|
|
346
311
|
parsedFocusShortcutsArray.push(parsedCombination);
|
|
347
312
|
} else if (isNumeric(element)) {
|
|
@@ -357,8 +322,9 @@ function parseFocusShortcuts(focusShortcutsArray) {
|
|
|
357
322
|
});
|
|
358
323
|
return parsedFocusShortcutsArray;
|
|
359
324
|
}
|
|
360
|
-
var MODIFIER_KEYS = ['shift', 'ctrl', 'alt', 'control', 'option', 'cmd', 'command'];
|
|
325
|
+
var MODIFIER_KEYS = ['shift', 'ctrl', 'alt', 'control', 'option', 'cmd', 'command'];
|
|
361
326
|
|
|
327
|
+
// filter out modifierkeys such as ctrl, alt, command, shift from focusShortcuts prop
|
|
362
328
|
function extractModifierKeysFromFocusShortcuts(focusShortcutsArray) {
|
|
363
329
|
return focusShortcutsArray.filter(function (shortcutKey) {
|
|
364
330
|
return MODIFIER_KEYS.includes(shortcutKey);
|
|
@@ -368,10 +334,8 @@ function decodeHtml(str) {
|
|
|
368
334
|
if (typeof str !== 'string') {
|
|
369
335
|
return str;
|
|
370
336
|
}
|
|
371
|
-
|
|
372
337
|
return str.replace(/&#([0-9]{1,3});/gi, function (match, numStr) {
|
|
373
338
|
var num = parseInt(numStr, 10); // read num as normal number
|
|
374
|
-
|
|
375
339
|
return String.fromCharCode(num);
|
|
376
340
|
});
|
|
377
341
|
}
|
package/dist/es/index.js
CHANGED
|
@@ -1,48 +1,49 @@
|
|
|
1
1
|
import '@appbaseio/reactivecore';
|
|
2
2
|
export { componentTypes } from '@appbaseio/reactivecore/lib/utils/constants';
|
|
3
|
-
import './_rollupPluginBabelHelpers-
|
|
3
|
+
import './_rollupPluginBabelHelpers-ded08042.js';
|
|
4
4
|
import 'vue-types';
|
|
5
5
|
import '@appbaseio/reactivecore/lib/utils/helper';
|
|
6
6
|
import 'emotion';
|
|
7
7
|
import '@appbaseio/vue-emotion';
|
|
8
8
|
import 'polished';
|
|
9
|
-
import './Button-
|
|
10
|
-
import './vueTypes-
|
|
11
|
-
import './Pagination-
|
|
9
|
+
import './Button-153cd885.js';
|
|
10
|
+
import './vueTypes-8986b709.js';
|
|
11
|
+
import './Pagination-28e56c5c.js';
|
|
12
12
|
export { default as ReactiveList } from './ReactiveList.js';
|
|
13
13
|
import '@appbaseio/reactivecore/lib/utils/transform';
|
|
14
14
|
import 'redux';
|
|
15
|
-
import './index-
|
|
16
|
-
import './ComponentWrapper-
|
|
17
|
-
import './PreferencesConsumer-
|
|
15
|
+
import './index-0444a498.js';
|
|
16
|
+
import './ComponentWrapper-240450cc.js';
|
|
17
|
+
import './PreferencesConsumer-bc097ebb.js';
|
|
18
18
|
import '@vue/babel-helper-vue-jsx-merge-props';
|
|
19
|
-
import './Title-
|
|
20
|
-
import './ListItem-
|
|
21
|
-
import './Card-
|
|
22
|
-
import './Flex-
|
|
19
|
+
import './Title-863dfa42.js';
|
|
20
|
+
import './ListItem-07888a65.js';
|
|
21
|
+
import './Card-19ad6d90.js';
|
|
22
|
+
import './Flex-7c177a10.js';
|
|
23
23
|
import '@appbaseio/reactivecore/lib/actions/analytics';
|
|
24
24
|
import 'appbase-js';
|
|
25
|
+
import '@appbaseio/analytics';
|
|
25
26
|
import 'url-search-params-polyfill';
|
|
26
27
|
export { default as ReactiveBase } from './ReactiveBase.js';
|
|
27
28
|
import 'hotkeys-js';
|
|
28
|
-
export { a as DataSearch } from './DataSearch-
|
|
29
|
-
import './CancelSvg-
|
|
30
|
-
import './Input-
|
|
29
|
+
export { a as DataSearch } from './DataSearch-5ddfba23.js';
|
|
30
|
+
import './CancelSvg-e40552a5.js';
|
|
31
|
+
import './Input-c09c0b56.js';
|
|
31
32
|
import 'compute-scroll-into-view';
|
|
32
|
-
import './Container-
|
|
33
|
+
import './Container-d00219f7.js';
|
|
33
34
|
import 'vue-highlight-words';
|
|
34
|
-
export { R as ReactiveComponent, S as SearchBox } from './ReactiveComponent-
|
|
35
|
+
export { R as ReactiveComponent, S as SearchBox } from './ReactiveComponent-59107264.js';
|
|
35
36
|
import '@appbaseio/reactivecore/lib/utils/suggestions';
|
|
36
|
-
import './FormControlList-
|
|
37
|
-
import './utils-
|
|
37
|
+
import './FormControlList-99797d0a.js';
|
|
38
|
+
import './utils-9e5a16a1.js';
|
|
38
39
|
export { default as SingleList } from './SingleList.js';
|
|
39
40
|
export { default as MultiList } from './MultiList.js';
|
|
40
|
-
import './DropDown-
|
|
41
|
+
import './DropDown-28ddce07.js';
|
|
41
42
|
export { default as SingleDropdownList } from './SingleDropdownList.js';
|
|
42
43
|
export { default as MultiDropdownList } from './MultiDropdownList.js';
|
|
43
44
|
export { default as ToggleButton } from './ToggleButton.js';
|
|
44
45
|
import 'vue-no-ssr';
|
|
45
|
-
import './ssr-
|
|
46
|
+
import './ssr-03607d84.js';
|
|
46
47
|
export { default as DynamicRangeSlider } from './DynamicRangeSlider.js';
|
|
47
48
|
export { default as SingleRange } from './SingleRange.js';
|
|
48
49
|
export { default as MultiRange } from './MultiRange.js';
|
|
@@ -51,7 +52,6 @@ export { default as RangeInput } from './RangeInput.js';
|
|
|
51
52
|
export { default as SelectedFilters } from './SelectedFilters.js';
|
|
52
53
|
export { default as ResultCard } from './ResultCard.js';
|
|
53
54
|
export { default as ResultList } from './ResultList.js';
|
|
54
|
-
import '@appbaseio/reactivecore/lib/actions/value';
|
|
55
55
|
export { default as StateProvider } from './StateProvider.js';
|
|
56
56
|
import 'gmap-vue';
|
|
57
57
|
import 'ngeohash';
|
|
@@ -71,7 +71,6 @@ import install from './install.js';
|
|
|
71
71
|
export { default as install } from './install.js';
|
|
72
72
|
|
|
73
73
|
// Add polyfills to support in IE
|
|
74
|
-
|
|
75
74
|
if (typeof window !== 'undefined' && window.Vue) {
|
|
76
75
|
install(window.Vue);
|
|
77
76
|
}
|