@appbaseio/reactivesearch-vue 1.24.2 → 1.26.0
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 +481 -279
- package/dist/@appbaseio/reactivesearch-vue.umd.js.map +1 -1
- package/dist/@appbaseio/reactivesearch-vue.umd.min.js +5 -5
- package/dist/@appbaseio/reactivesearch-vue.umd.min.js.map +1 -1
- package/dist/cjs/{DownShift-62e82255.js → CancelSvg-4aa35935.js} +58 -14
- package/dist/cjs/DataSearch.js +31 -82
- package/dist/cjs/{DropDown-6815b9b6.js → DropDown-cf9bfffc.js} +60 -23
- package/dist/cjs/DynamicRangeSlider.js +9 -6
- package/dist/cjs/MultiDropdownList.js +14 -7
- package/dist/cjs/MultiList.js +6 -5
- package/dist/cjs/MultiRange.js +2 -2
- package/dist/cjs/RangeInput.js +3 -3
- package/dist/cjs/RangeSlider.js +17 -20
- package/dist/cjs/ReactiveBase.js +5 -3
- package/dist/cjs/ReactiveComponent.js +12 -12
- package/dist/cjs/ReactiveList.js +54 -42
- package/dist/cjs/ResultCard.js +1 -1
- package/dist/cjs/ResultList.js +1 -1
- package/dist/cjs/SelectedFilters.js +7 -5
- package/dist/cjs/SingleDropdownList.js +14 -7
- package/dist/cjs/SingleList.js +7 -6
- package/dist/cjs/SingleRange.js +2 -2
- package/dist/cjs/StateProvider.js +6 -2
- package/dist/cjs/ToggleButton.js +3 -3
- package/dist/cjs/index.js +7 -4
- package/dist/cjs/initReactivesearch.js +31 -12
- package/dist/cjs/install.js +5 -4
- package/dist/cjs/ssr-0ee35a09.js +39 -0
- package/dist/cjs/version.js +1 -1
- package/dist/cjs/{vueTypes-4c19b4c8.js → vueTypes-57d01f18.js} +3 -3
- package/dist/es/{DownShift-3558d402.js → CancelSvg-c2c03a35.js} +55 -16
- package/dist/es/DataSearch.js +21 -72
- package/dist/es/{DropDown-035c804f.js → DropDown-c8da0a2c.js} +59 -22
- package/dist/es/DynamicRangeSlider.js +9 -6
- package/dist/es/MultiDropdownList.js +14 -7
- package/dist/es/MultiList.js +6 -5
- package/dist/es/MultiRange.js +2 -2
- package/dist/es/RangeInput.js +3 -3
- package/dist/es/RangeSlider.js +17 -20
- package/dist/es/ReactiveBase.js +5 -3
- package/dist/es/ReactiveComponent.js +12 -12
- package/dist/es/ReactiveList.js +54 -42
- package/dist/es/ResultCard.js +1 -1
- package/dist/es/ResultList.js +1 -1
- package/dist/es/SelectedFilters.js +7 -5
- package/dist/es/SingleDropdownList.js +14 -7
- package/dist/es/SingleList.js +7 -6
- package/dist/es/SingleRange.js +2 -2
- package/dist/es/StateProvider.js +6 -2
- package/dist/es/ToggleButton.js +3 -3
- package/dist/es/index.js +7 -4
- package/dist/es/initReactivesearch.js +31 -12
- package/dist/es/install.js +5 -4
- package/dist/es/ssr-a41dfea9.js +33 -0
- package/dist/es/version.js +1 -1
- package/dist/es/{vueTypes-fb61bb7b.js → vueTypes-687b2304.js} +3 -3
- package/package.json +3 -3
- package/dist/cjs/ssr-08e95ede.js +0 -39
- package/dist/es/ssr-5d255b08.js +0 -33
|
@@ -3,8 +3,36 @@
|
|
|
3
3
|
function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; }
|
|
4
4
|
|
|
5
5
|
var _rollupPluginBabelHelpers = require('./_rollupPluginBabelHelpers-f127c8b7.js');
|
|
6
|
+
var styled = require('@appbaseio/vue-emotion');
|
|
7
|
+
var styled__default = _interopDefault(styled);
|
|
6
8
|
var computeScrollIntoView = _interopDefault(require('compute-scroll-into-view'));
|
|
7
9
|
|
|
10
|
+
var _templateObject;
|
|
11
|
+
var InputWrapper = styled__default('span')(_templateObject || (_templateObject = _rollupPluginBabelHelpers._taggedTemplateLiteralLoose(["\n flex: 1;\n position: relative;\n"])));
|
|
12
|
+
|
|
13
|
+
var _templateObject$1, _templateObject2, _templateObject3, _templateObject4;
|
|
14
|
+
var IconGroup = styled__default('div')(_templateObject$1 || (_templateObject$1 = _rollupPluginBabelHelpers._taggedTemplateLiteralLoose(["\n\tdisplay: flex;\n\talign-items: center;\n\tjustify-content: center;\n\tgrid-gap: 6px;\n\tmargin: 0 10px;\n\theight: 100%;\n\n\t", ";\n\n\t", ";\n"])), function (_ref) {
|
|
15
|
+
var positionType = _ref.positionType;
|
|
16
|
+
|
|
17
|
+
if (positionType === 'absolute') {
|
|
18
|
+
return styled.css(_templateObject2 || (_templateObject2 = _rollupPluginBabelHelpers._taggedTemplateLiteralLoose(["\n\t\t\t\tposition: absolute;\n\t\t\t\ttop: 50%;\n\t\t\t\ttransform: translateY(-50%);\n\t\t\t"])));
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
return null;
|
|
22
|
+
}, function (_ref2) {
|
|
23
|
+
var groupPosition = _ref2.groupPosition;
|
|
24
|
+
return groupPosition === 'right' ? styled.css(_templateObject3 || (_templateObject3 = _rollupPluginBabelHelpers._taggedTemplateLiteralLoose(["\n\t\t\t\t\tright: 0;\n\t\t\t "]))) : styled.css(_templateObject4 || (_templateObject4 = _rollupPluginBabelHelpers._taggedTemplateLiteralLoose(["\n\t\t\t\t\tleft: 0;\n\t\t\t "])));
|
|
25
|
+
});
|
|
26
|
+
|
|
27
|
+
var _templateObject$2;
|
|
28
|
+
var IconWrapper = styled__default('div')(_templateObject$2 || (_templateObject$2 = _rollupPluginBabelHelpers._taggedTemplateLiteralLoose(["\n\tdisplay: flex;\n\talign-items: center;\n\tjustify-content: center;\n\tmax-width: 23px;\n\twidth: max-content;\n\tcursor: pointer;\n\theight: 100%;min-width:20px;\n\n\tsvg.search-icon {\n\t\tfill: ", ";\n\t\ttransform:scale(1.5);\n\t}\n\n\tsvg.cancel-icon {\n\t\tfill: ", ";\n\t}\n"])), function (_ref) {
|
|
29
|
+
var theme = _ref.theme;
|
|
30
|
+
return theme.colors.primaryColor;
|
|
31
|
+
}, function (_ref2) {
|
|
32
|
+
var theme = _ref2.theme;
|
|
33
|
+
return theme.colors.borderColor || '#000';
|
|
34
|
+
});
|
|
35
|
+
|
|
8
36
|
/**
|
|
9
37
|
* Scroll node into view if necessary
|
|
10
38
|
* @param {HTMLElement} node the element that should scroll into view
|
|
@@ -40,8 +68,7 @@ var Downshift = {
|
|
|
40
68
|
internal_isOpen: false,
|
|
41
69
|
internal_inputValue: '',
|
|
42
70
|
internal_selectedItem: null,
|
|
43
|
-
internal_highlightedIndex: null
|
|
44
|
-
internal_eventsCalled: {}
|
|
71
|
+
internal_highlightedIndex: null
|
|
45
72
|
};
|
|
46
73
|
},
|
|
47
74
|
computed: {
|
|
@@ -226,23 +253,11 @@ var Downshift = {
|
|
|
226
253
|
}
|
|
227
254
|
|
|
228
255
|
var vm = this;
|
|
229
|
-
setTimeout(function () {
|
|
230
|
-
vm.internal_eventsCalled[index] = false;
|
|
231
|
-
}, 0);
|
|
232
256
|
return {
|
|
233
257
|
mouseenter: function mouseenter() {
|
|
234
258
|
vm.setHighlightedIndex(newIndex);
|
|
235
259
|
},
|
|
236
|
-
// for browsers not supporting click event (e.g. firefox android)
|
|
237
|
-
mousedown: function mousedown(event) {
|
|
238
|
-
if (vm.internal_eventsCalled[index]) return;
|
|
239
|
-
vm.internal_eventsCalled[index] = true;
|
|
240
|
-
event.stopPropagation();
|
|
241
|
-
vm.selectItemAtIndex(newIndex);
|
|
242
|
-
},
|
|
243
260
|
click: function click(event) {
|
|
244
|
-
if (vm.internal_eventsCalled[index]) return;
|
|
245
|
-
vm.internal_eventsCalled[index] = true;
|
|
246
261
|
event.stopPropagation();
|
|
247
262
|
vm.selectItemAtIndex(newIndex);
|
|
248
263
|
}
|
|
@@ -402,4 +417,33 @@ var Downshift = {
|
|
|
402
417
|
}
|
|
403
418
|
};
|
|
404
419
|
|
|
420
|
+
var CancelSvg = {
|
|
421
|
+
functional: true,
|
|
422
|
+
render: function render(h) {
|
|
423
|
+
return h("svg", {
|
|
424
|
+
"attrs": {
|
|
425
|
+
"alt": "Clear",
|
|
426
|
+
"xmlns": "http://www.w3.org/2000/svg",
|
|
427
|
+
"height": "20px",
|
|
428
|
+
"viewBox": "0 0 24 24",
|
|
429
|
+
"width": "20px"
|
|
430
|
+
},
|
|
431
|
+
"class": "cancel-icon"
|
|
432
|
+
}, [h("title", ["Clear"]), h("path", {
|
|
433
|
+
"attrs": {
|
|
434
|
+
"d": "M0 0h24v24H0V0z",
|
|
435
|
+
"fill": "none"
|
|
436
|
+
}
|
|
437
|
+
}), h("path", {
|
|
438
|
+
"attrs": {
|
|
439
|
+
"d": "M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12 19 6.41z"
|
|
440
|
+
}
|
|
441
|
+
})]);
|
|
442
|
+
}
|
|
443
|
+
};
|
|
444
|
+
|
|
445
|
+
exports.CancelSvg = CancelSvg;
|
|
405
446
|
exports.Downshift = Downshift;
|
|
447
|
+
exports.IconGroup = IconGroup;
|
|
448
|
+
exports.IconWrapper = IconWrapper;
|
|
449
|
+
exports.InputWrapper = InputWrapper;
|
package/dist/cjs/DataSearch.js
CHANGED
|
@@ -14,7 +14,7 @@ require('emotion');
|
|
|
14
14
|
var styled = require('@appbaseio/vue-emotion');
|
|
15
15
|
var styled__default = _interopDefault(styled);
|
|
16
16
|
require('polished');
|
|
17
|
-
var vueTypes = require('./vueTypes-
|
|
17
|
+
var vueTypes = require('./vueTypes-57d01f18.js');
|
|
18
18
|
require('@appbaseio/reactivecore/lib/utils/transform');
|
|
19
19
|
require('redux');
|
|
20
20
|
var index = require('./index-89c39a9e.js');
|
|
@@ -22,9 +22,9 @@ var ComponentWrapper = require('./ComponentWrapper-32481890.js');
|
|
|
22
22
|
var Title = require('./Title-584a8cc8.js');
|
|
23
23
|
var Flex = require('./Flex-f146cdad.js');
|
|
24
24
|
var hotkeys = _interopDefault(require('hotkeys-js'));
|
|
25
|
+
var CancelSvg = require('./CancelSvg-4aa35935.js');
|
|
25
26
|
var Input = require('./Input-3cc3fa59.js');
|
|
26
27
|
require('compute-scroll-into-view');
|
|
27
|
-
var DownShift = require('./DownShift-62e82255.js');
|
|
28
28
|
var Container = require('./Container-526efa6a.js');
|
|
29
29
|
var Highlight = _interopDefault(require('vue-highlight-words'));
|
|
30
30
|
|
|
@@ -35,37 +35,11 @@ InputGroup.defaultProps = {
|
|
|
35
35
|
};
|
|
36
36
|
|
|
37
37
|
var _templateObject$1;
|
|
38
|
-
var
|
|
39
|
-
|
|
40
|
-
var _templateObject$2;
|
|
41
|
-
var InputAddon = styled__default('span')(_templateObject$2 || (_templateObject$2 = _rollupPluginBabelHelpers._taggedTemplateLiteralLoose(["\n display: flex;\n align-items: center;\n justify-content: center;\n background-color: #fafafa;\n border: 1px solid #ccc;\n border-radius: 2px;\n color: rgba(0, 0, 0, 0.85);\n font-size: 14px;\n font-weight: 400;\n padding: 0 11px;\n position: relative;\n transition: all 0.3s;\n box-sizing: border-box;\n overflow: hidden;\n\n &:first-of-type {\n border-right: none;\n }\n &:last-of-type {\n border-left: none;\n }\n"])));
|
|
38
|
+
var InputAddon = styled__default('span')(_templateObject$1 || (_templateObject$1 = _rollupPluginBabelHelpers._taggedTemplateLiteralLoose(["\n display: flex;\n align-items: center;\n justify-content: center;\n background-color: #fafafa;\n border: 1px solid #ccc;\n border-radius: 2px;\n color: rgba(0, 0, 0, 0.85);\n font-size: 14px;\n font-weight: 400;\n padding: 0 11px;\n position: relative;\n transition: all 0.3s;\n box-sizing: border-box;\n overflow: hidden;\n\n &:first-of-type {\n border-right: none;\n }\n &:last-of-type {\n border-left: none;\n }\n"])));
|
|
42
39
|
InputAddon.defaultProps = {
|
|
43
40
|
className: 'input-addon'
|
|
44
41
|
};
|
|
45
42
|
|
|
46
|
-
var _templateObject$3, _templateObject2, _templateObject3, _templateObject4;
|
|
47
|
-
var IconGroup = styled__default('div')(_templateObject$3 || (_templateObject$3 = _rollupPluginBabelHelpers._taggedTemplateLiteralLoose(["\n\tdisplay: flex;\n\talign-items: center;\n\tjustify-content: center;\n\tgrid-gap: 6px;\n\tmargin: 0 10px;\n\theight: 100%;\n\n\t", ";\n\n\t", ";\n"])), function (_ref) {
|
|
48
|
-
var positionType = _ref.positionType;
|
|
49
|
-
|
|
50
|
-
if (positionType === 'absolute') {
|
|
51
|
-
return styled.css(_templateObject2 || (_templateObject2 = _rollupPluginBabelHelpers._taggedTemplateLiteralLoose(["\n\t\t\t\tposition: absolute;\n\t\t\t\ttop: 50%;\n\t\t\t\ttransform: translateY(-50%);\n\t\t\t"])));
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
return null;
|
|
55
|
-
}, function (_ref2) {
|
|
56
|
-
var groupPosition = _ref2.groupPosition;
|
|
57
|
-
return groupPosition === 'right' ? styled.css(_templateObject3 || (_templateObject3 = _rollupPluginBabelHelpers._taggedTemplateLiteralLoose(["\n\t\t\t\t\tright: 0;\n\t\t\t "]))) : styled.css(_templateObject4 || (_templateObject4 = _rollupPluginBabelHelpers._taggedTemplateLiteralLoose(["\n\t\t\t\t\tleft: 0;\n\t\t\t "])));
|
|
58
|
-
});
|
|
59
|
-
|
|
60
|
-
var _templateObject$4;
|
|
61
|
-
var IconWrapper = styled__default('div')(_templateObject$4 || (_templateObject$4 = _rollupPluginBabelHelpers._taggedTemplateLiteralLoose(["\n\tdisplay: flex;\n\talign-items: center;\n\tjustify-content: center;\n\tmax-width: 23px;\n\twidth: max-content;\n\tcursor: pointer;\n\theight: 100%;min-width:20px;\n\n\tsvg.search-icon {\n\t\tfill: ", ";\n\t\ttransform:scale(1.5);\n\t}\n\n\tsvg.cancel-icon {\n\t\tfill: ", ";\n\t}\n"])), function (_ref) {
|
|
62
|
-
var theme = _ref.theme;
|
|
63
|
-
return theme.colors.primaryColor;
|
|
64
|
-
}, function (_ref2) {
|
|
65
|
-
var theme = _ref2.theme;
|
|
66
|
-
return theme.colors.borderColor || '#000';
|
|
67
|
-
});
|
|
68
|
-
|
|
69
43
|
var getClassName = configureStore.helper.getClassName;
|
|
70
44
|
var SuggestionWrapper = {
|
|
71
45
|
name: 'SuggestionWrapper',
|
|
@@ -86,14 +60,14 @@ var SuggestionWrapper = {
|
|
|
86
60
|
}
|
|
87
61
|
};
|
|
88
62
|
|
|
89
|
-
var _templateObject$
|
|
63
|
+
var _templateObject$2;
|
|
90
64
|
var highlightStyle = {
|
|
91
65
|
fontWeight: 600,
|
|
92
66
|
padding: 0,
|
|
93
67
|
backgroundColor: 'transparent',
|
|
94
68
|
color: 'inherit'
|
|
95
69
|
};
|
|
96
|
-
var PredictiveSuggestion = styled__default('span')(_templateObject$
|
|
70
|
+
var PredictiveSuggestion = styled__default('span')(_templateObject$2 || (_templateObject$2 = _rollupPluginBabelHelpers._taggedTemplateLiteralLoose(["\n\t.highlight {\n\t\tbackground: transparent;\n\t\tcolor: inherit;\n\t\tfont-weight: 600;\n\t\tpadding: 0;\n\t}\n"])));
|
|
97
71
|
var SuggestionItem = {
|
|
98
72
|
name: 'SuggestionItem',
|
|
99
73
|
props: {
|
|
@@ -208,34 +182,9 @@ var SearchSvg = {
|
|
|
208
182
|
}
|
|
209
183
|
};
|
|
210
184
|
|
|
211
|
-
var
|
|
212
|
-
functional: true,
|
|
213
|
-
render: function render(h) {
|
|
214
|
-
return h("svg", {
|
|
215
|
-
"attrs": {
|
|
216
|
-
"alt": "Clear",
|
|
217
|
-
"xmlns": "http://www.w3.org/2000/svg",
|
|
218
|
-
"height": "20px",
|
|
219
|
-
"viewBox": "0 0 24 24",
|
|
220
|
-
"width": "20px"
|
|
221
|
-
},
|
|
222
|
-
"class": "cancel-icon"
|
|
223
|
-
}, [h("title", ["Clear"]), h("path", {
|
|
224
|
-
"attrs": {
|
|
225
|
-
"d": "M0 0h24v24H0V0z",
|
|
226
|
-
"fill": "none"
|
|
227
|
-
}
|
|
228
|
-
}), h("path", {
|
|
229
|
-
"attrs": {
|
|
230
|
-
"d": "M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12 19 6.41z"
|
|
231
|
-
}
|
|
232
|
-
})]);
|
|
233
|
-
}
|
|
234
|
-
};
|
|
185
|
+
var _templateObject$3;
|
|
235
186
|
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
styled.injectGlobal(_templateObject$6 || (_templateObject$6 = _rollupPluginBabelHelpers._taggedTemplateLiteralLoose(["\n\t#el_TvxDfTAtKp {\n\t\tstroke: none;\n\t\tstroke-width: 1;\n\t\tfill: none;\n\t}\n\t#el_D93PK3GbmJ {\n\t\t-webkit-transform: translate(163px, 131px);\n\t\ttransform: translate(163px, 131px);\n\t\tfill: #d8d8d8;\n\t}\n"])));
|
|
187
|
+
styled.injectGlobal(_templateObject$3 || (_templateObject$3 = _rollupPluginBabelHelpers._taggedTemplateLiteralLoose(["\n\t#el_TvxDfTAtKp {\n\t\tstroke: none;\n\t\tstroke-width: 1;\n\t\tfill: none;\n\t}\n\t#el_D93PK3GbmJ {\n\t\t-webkit-transform: translate(163px, 131px);\n\t\ttransform: translate(163px, 131px);\n\t\tfill: #d8d8d8;\n\t}\n"])));
|
|
239
188
|
var MicSvg = {
|
|
240
189
|
name: 'MicSvg',
|
|
241
190
|
props: ['className'],
|
|
@@ -280,9 +229,9 @@ var MicSvg = {
|
|
|
280
229
|
}
|
|
281
230
|
};
|
|
282
231
|
|
|
283
|
-
var _templateObject$
|
|
232
|
+
var _templateObject$4;
|
|
284
233
|
|
|
285
|
-
styled.injectGlobal(_templateObject$
|
|
234
|
+
styled.injectGlobal(_templateObject$4 || (_templateObject$4 = _rollupPluginBabelHelpers._taggedTemplateLiteralLoose(["\n\t#el_X81iT9kZYo {\n\t\tstroke: none;\n\t\tstroke-width: 1;\n\t\tfill: none;\n\t}\n\t#el_gMpyalCphp {\n\t\t-webkit-transform: translate(163px, 131px);\n\t\ttransform: translate(163px, 131px);\n\t}\n\t#el_c7H-3u-D4l {\n\t\tfill: #d8d8d8;\n\t}\n\t#el_qhFcdAAFwo {\n\t\tfill: #d8d8d8;\n\t}\n\t#el_M8X8g37WOI {\n\t\tstroke: #e83137;\n\t\tstroke-width: 21;\n\t}\n"])));
|
|
286
235
|
var MuteSvg = {
|
|
287
236
|
name: 'MuteSvg',
|
|
288
237
|
props: ['className'],
|
|
@@ -338,9 +287,9 @@ var MuteSvg = {
|
|
|
338
287
|
}
|
|
339
288
|
};
|
|
340
289
|
|
|
341
|
-
var _templateObject$
|
|
290
|
+
var _templateObject$5;
|
|
342
291
|
|
|
343
|
-
styled.injectGlobal(_templateObject$
|
|
292
|
+
styled.injectGlobal(_templateObject$5 || (_templateObject$5 = _rollupPluginBabelHelpers._taggedTemplateLiteralLoose(["\n\t@-webkit-keyframes kf_el_6WKby7wXqV_an_qqO-rxbNc {\n\t\t0% {\n\t\t\topacity: 0;\n\t\t}\n\t\t13.89% {\n\t\t\topacity: 1;\n\t\t}\n\t\t100% {\n\t\t\topacity: 1;\n\t\t}\n\t}\n\t@keyframes kf_el_6WKby7wXqV_an_qqO-rxbNc {\n\t\t0% {\n\t\t\topacity: 0;\n\t\t}\n\t\t13.89% {\n\t\t\topacity: 1;\n\t\t}\n\t\t100% {\n\t\t\topacity: 1;\n\t\t}\n\t}\n\t@-webkit-keyframes kf_el_Wi-my975tM_an_XhXP1epXB {\n\t\t0% {\n\t\t\topacity: 0;\n\t\t}\n\t\t27.78% {\n\t\t\topacity: 1;\n\t\t}\n\t\t100% {\n\t\t\topacity: 1;\n\t\t}\n\t}\n\t@keyframes kf_el_Wi-my975tM_an_XhXP1epXB {\n\t\t0% {\n\t\t\topacity: 0;\n\t\t}\n\t\t27.78% {\n\t\t\topacity: 1;\n\t\t}\n\t\t100% {\n\t\t\topacity: 1;\n\t\t}\n\t}\n\t@-webkit-keyframes kf_el_DkfFFTaFxy8_an_T2XxzvIaA {\n\t\t0% {\n\t\t\topacity: 0;\n\t\t}\n\t\t41.67% {\n\t\t\topacity: 1;\n\t\t}\n\t\t100% {\n\t\t\topacity: 1;\n\t\t}\n\t}\n\t@keyframes kf_el_DkfFFTaFxy8_an_T2XxzvIaA {\n\t\t0% {\n\t\t\topacity: 0;\n\t\t}\n\t\t41.67% {\n\t\t\topacity: 1;\n\t\t}\n\t\t100% {\n\t\t\topacity: 1;\n\t\t}\n\t}\n\t@-webkit-keyframes kf_el_34IgwiMB5rf_an_TPom3H2LI {\n\t\t0% {\n\t\t\topacity: 0;\n\t\t}\n\t\t55.56% {\n\t\t\topacity: 1;\n\t\t}\n\t\t100% {\n\t\t\topacity: 1;\n\t\t}\n\t}\n\t@keyframes kf_el_34IgwiMB5rf_an_TPom3H2LI {\n\t\t0% {\n\t\t\topacity: 0;\n\t\t}\n\t\t55.56% {\n\t\t\topacity: 1;\n\t\t}\n\t\t100% {\n\t\t\topacity: 1;\n\t\t}\n\t}\n\t@-webkit-keyframes kf_el_DeebuCsPTGA_an_aYTRBE7Na {\n\t\t0% {\n\t\t\topacity: 0;\n\t\t}\n\t\t69.44% {\n\t\t\topacity: 1;\n\t\t}\n\t\t100% {\n\t\t\topacity: 1;\n\t\t}\n\t}\n\t@keyframes kf_el_DeebuCsPTGA_an_aYTRBE7Na {\n\t\t0% {\n\t\t\topacity: 0;\n\t\t}\n\t\t69.44% {\n\t\t\topacity: 1;\n\t\t}\n\t\t100% {\n\t\t\topacity: 1;\n\t\t}\n\t}\n\t@-webkit-keyframes kf_el_ZOjjrPTvyrv_an_l_BjBNzXw {\n\t\t0% {\n\t\t\topacity: 0;\n\t\t}\n\t\t83.33% {\n\t\t\topacity: 1;\n\t\t}\n\t\t100% {\n\t\t\topacity: 1;\n\t\t}\n\t}\n\t@keyframes kf_el_ZOjjrPTvyrv_an_l_BjBNzXw {\n\t\t0% {\n\t\t\topacity: 0;\n\t\t}\n\t\t83.33% {\n\t\t\topacity: 1;\n\t\t}\n\t\t100% {\n\t\t\topacity: 1;\n\t\t}\n\t}\n\t@-webkit-keyframes kf_el_2FATegVmf0K_an_wLg4ofuFx {\n\t\t0% {\n\t\t\topacity: 0;\n\t\t}\n\t\t97.22% {\n\t\t\topacity: 1;\n\t\t}\n\t\t100% {\n\t\t\topacity: 1;\n\t\t}\n\t}\n\t@keyframes kf_el_2FATegVmf0K_an_wLg4ofuFx {\n\t\t0% {\n\t\t\topacity: 0;\n\t\t}\n\t\t97.22% {\n\t\t\topacity: 1;\n\t\t}\n\t\t100% {\n\t\t\topacity: 1;\n\t\t}\n\t}\n\t#el_hiibMG0x- * {\n\t\t-webkit-animation-duration: 1.2s;\n\t\tanimation-duration: 1.2s;\n\t\t-webkit-animation-iteration-count: infinite;\n\t\tanimation-iteration-count: infinite;\n\t\t-webkit-animation-timing-function: cubic-bezier(0, 0, 1, 1);\n\t\tanimation-timing-function: cubic-bezier(0, 0, 1, 1);\n\t}\n\t#el_QJeJ_2CDw5 {\n\t\tstroke: none;\n\t\tstroke-width: 1;\n\t\tfill: none;\n\t}\n\t#el_UYYCfubTRf {\n\t\t-webkit-transform: translate(163px, 123px);\n\t\ttransform: translate(163px, 123px);\n\t}\n\t#el_uzZNtK32Zi {\n\t\tfill: #d8d8d8;\n\t}\n\t#el_EYKQ2N9Kgy {\n\t\tfill: #d8d8d8;\n\t}\n\t#el_6SDP2LAgKC {\n\t\t-webkit-transform: translate(37.846924px, 0px);\n\t\ttransform: translate(37.846924px, 0px);\n\t}\n\t#el_-Vm65Ltfy7 {\n\t\tfill: #0B6AFF;\n\t}\n\t#el_q04iZcSim4 {\n\t\tfill: #d8d8d8;\n\t}\n\t#el_6WKby7wXqV {\n\t\t-webkit-transform: translate(37.846924px, 0px);\n\t\ttransform: translate(37.846924px, 0px);\n\t\t-webkit-animation-fill-mode: backwards;\n\t\tanimation-fill-mode: backwards;\n\t\topacity: 0;\n\t\t-webkit-animation-name: kf_el_6WKby7wXqV_an_qqO-rxbNc;\n\t\tanimation-name: kf_el_6WKby7wXqV_an_qqO-rxbNc;\n\t\t-webkit-animation-timing-function: cubic-bezier(0.42, 0, 1, 1);\n\t\tanimation-timing-function: cubic-bezier(0.42, 0, 1, 1);\n\t}\n\t#el_9bggsfQOtU {\n\t\tfill: #0B6AFF;\n\t}\n\t#el_NKxqi9eIym {\n\t\tfill: #d8d8d8;\n\t}\n\t#el_Wi-my975tM {\n\t\t-webkit-transform: translate(37.846924px, 0px);\n\t\ttransform: translate(37.846924px, 0px);\n\t\t-webkit-animation-fill-mode: backwards;\n\t\tanimation-fill-mode: backwards;\n\t\topacity: 0;\n\t\t-webkit-animation-name: kf_el_Wi-my975tM_an_XhXP1epXB;\n\t\tanimation-name: kf_el_Wi-my975tM_an_XhXP1epXB;\n\t\t-webkit-animation-timing-function: cubic-bezier(0.42, 0, 1, 1);\n\t\tanimation-timing-function: cubic-bezier(0.42, 0, 1, 1);\n\t}\n\t#el_zclQ34fvf7 {\n\t\tfill: #0B6AFF;\n\t}\n\t#el_1OsvRT8HkeZ {\n\t\tfill: #d8d8d8;\n\t}\n\t#el_DkfFFTaFxy8 {\n\t\t-webkit-transform: translate(37.846924px, 0px);\n\t\ttransform: translate(37.846924px, 0px);\n\t\t-webkit-animation-fill-mode: backwards;\n\t\tanimation-fill-mode: backwards;\n\t\topacity: 0;\n\t\t-webkit-animation-name: kf_el_DkfFFTaFxy8_an_T2XxzvIaA;\n\t\tanimation-name: kf_el_DkfFFTaFxy8_an_T2XxzvIaA;\n\t\t-webkit-animation-timing-function: cubic-bezier(0.42, 0, 1, 1);\n\t\tanimation-timing-function: cubic-bezier(0.42, 0, 1, 1);\n\t}\n\t#el_aa9sjx4H0vA {\n\t\tfill: #0B6AFF;\n\t}\n\t#el_tea114vWg0J {\n\t\tfill: #d8d8d8;\n\t}\n\t#el_34IgwiMB5rf {\n\t\t-webkit-transform: translate(37.846924px, 0px);\n\t\ttransform: translate(37.846924px, 0px);\n\t\t-webkit-animation-fill-mode: backwards;\n\t\tanimation-fill-mode: backwards;\n\t\topacity: 0;\n\t\t-webkit-animation-name: kf_el_34IgwiMB5rf_an_TPom3H2LI;\n\t\tanimation-name: kf_el_34IgwiMB5rf_an_TPom3H2LI;\n\t\t-webkit-animation-timing-function: cubic-bezier(0.42, 0, 1, 1);\n\t\tanimation-timing-function: cubic-bezier(0.42, 0, 1, 1);\n\t}\n\t#el_z5u6RAFhx7d {\n\t\tfill: #0B6AFF;\n\t}\n\t#el_7nfuWmA5Uhy {\n\t\tfill: #d8d8d8;\n\t}\n\t#el_DeebuCsPTGA {\n\t\t-webkit-transform: translate(37.846924px, 0px);\n\t\ttransform: translate(37.846924px, 0px);\n\t\t-webkit-animation-fill-mode: backwards;\n\t\tanimation-fill-mode: backwards;\n\t\topacity: 0;\n\t\t-webkit-animation-name: kf_el_DeebuCsPTGA_an_aYTRBE7Na;\n\t\tanimation-name: kf_el_DeebuCsPTGA_an_aYTRBE7Na;\n\t\t-webkit-animation-timing-function: cubic-bezier(0.42, 0, 1, 1);\n\t\tanimation-timing-function: cubic-bezier(0.42, 0, 1, 1);\n\t}\n\t#el__ZcqlS20zcw {\n\t\tfill: #0B6AFF;\n\t}\n\t#el_8DnEQnD7VWV {\n\t\tfill: #d8d8d8;\n\t}\n\t#el_ZOjjrPTvyrv {\n\t\t-webkit-transform: translate(37.846924px, 0px);\n\t\ttransform: translate(37.846924px, 0px);\n\t\t-webkit-animation-fill-mode: backwards;\n\t\tanimation-fill-mode: backwards;\n\t\topacity: 0;\n\t\t-webkit-animation-name: kf_el_ZOjjrPTvyrv_an_l_BjBNzXw;\n\t\tanimation-name: kf_el_ZOjjrPTvyrv_an_l_BjBNzXw;\n\t\t-webkit-animation-timing-function: cubic-bezier(0.42, 0, 1, 1);\n\t\tanimation-timing-function: cubic-bezier(0.42, 0, 1, 1);\n\t}\n\t#el_FYYKCI_u24e {\n\t\tfill: #0B6AFF;\n\t}\n\t#el_XZty4MnTp5Y {\n\t\tfill: #d8d8d8;\n\t}\n\t#el_2FATegVmf0K {\n\t\t-webkit-transform: translate(37.846924px, 0px);\n\t\ttransform: translate(37.846924px, 0px);\n\t\t-webkit-animation-fill-mode: backwards;\n\t\tanimation-fill-mode: backwards;\n\t\topacity: 0;\n\t\t-webkit-animation-name: kf_el_2FATegVmf0K_an_wLg4ofuFx;\n\t\tanimation-name: kf_el_2FATegVmf0K_an_wLg4ofuFx;\n\t\t-webkit-animation-timing-function: cubic-bezier(0.42, 0, 1, 1);\n\t\tanimation-timing-function: cubic-bezier(0.42, 0, 1, 1);\n\t}\n\t#el_RMT1KUfbdF8 {\n\t\tfill: #0B6AFF;\n\t}\n\t#el_RgLcovvFiO1 {\n\t\tfill: #d8d8d8;\n\t}\n"])));
|
|
344
293
|
var ListenSvg = {
|
|
345
294
|
name: 'ListenSvg',
|
|
346
295
|
props: ['className'],
|
|
@@ -661,8 +610,8 @@ var Mic = {
|
|
|
661
610
|
name: 'Mic',
|
|
662
611
|
props: {
|
|
663
612
|
children: vueTypes.types.title,
|
|
664
|
-
lang:
|
|
665
|
-
iconPosition:
|
|
613
|
+
lang: VueTypes.string.def('en-US'),
|
|
614
|
+
iconPosition: VueTypes.string.def('left'),
|
|
666
615
|
handleResult: vueTypes.types.func,
|
|
667
616
|
onNoMatch: vueTypes.types.func,
|
|
668
617
|
onError: vueTypes.types.func,
|
|
@@ -846,7 +795,7 @@ var Mic = {
|
|
|
846
795
|
return this.getComponent();
|
|
847
796
|
}
|
|
848
797
|
|
|
849
|
-
return h(IconWrapper, [this.Icon]);
|
|
798
|
+
return h(CancelSvg.IconWrapper, [this.Icon]);
|
|
850
799
|
}
|
|
851
800
|
};
|
|
852
801
|
|
|
@@ -1074,10 +1023,10 @@ var DataSearch = {
|
|
|
1074
1023
|
})]),
|
|
1075
1024
|
aggregationField: vueTypes.types.string,
|
|
1076
1025
|
aggregationSize: VueTypes.number,
|
|
1077
|
-
size: VueTypes.number
|
|
1026
|
+
size: VueTypes.number,
|
|
1078
1027
|
debounce: VueTypes.number.def(0),
|
|
1079
1028
|
defaultValue: vueTypes.types.string,
|
|
1080
|
-
excludeFields: vueTypes.types.excludeFields
|
|
1029
|
+
excludeFields: vueTypes.types.excludeFields,
|
|
1081
1030
|
value: vueTypes.types.value,
|
|
1082
1031
|
defaultSuggestions: vueTypes.types.suggestions,
|
|
1083
1032
|
enableSynonyms: VueTypes.bool.def(true),
|
|
@@ -1091,9 +1040,9 @@ var DataSearch = {
|
|
|
1091
1040
|
highlightField: vueTypes.types.stringOrArray,
|
|
1092
1041
|
icon: vueTypes.types.children,
|
|
1093
1042
|
iconPosition: VueTypes.oneOf(['left', 'right']).def('left'),
|
|
1094
|
-
includeFields: vueTypes.types.includeFields
|
|
1043
|
+
includeFields: vueTypes.types.includeFields,
|
|
1095
1044
|
innerClass: vueTypes.types.style,
|
|
1096
|
-
innerRef:
|
|
1045
|
+
innerRef: VueTypes.string.def('searchInputField'),
|
|
1097
1046
|
render: vueTypes.types.func,
|
|
1098
1047
|
renderQuerySuggestions: vueTypes.types.func,
|
|
1099
1048
|
renderPopularSuggestions: vueTypes.types.func,
|
|
@@ -1125,7 +1074,7 @@ var DataSearch = {
|
|
|
1125
1074
|
focusShortcuts: VueTypes.arrayOf(VueTypes.oneOfType([VueTypes.string, VueTypes.number])).def(['/']),
|
|
1126
1075
|
addonBefore: VueTypes.any,
|
|
1127
1076
|
addonAfter: VueTypes.any,
|
|
1128
|
-
expandSuggestionsContainer:
|
|
1077
|
+
expandSuggestionsContainer: VueTypes.bool.def(true),
|
|
1129
1078
|
index: VueTypes.string
|
|
1130
1079
|
},
|
|
1131
1080
|
beforeMount: function beforeMount() {
|
|
@@ -1400,7 +1349,7 @@ var DataSearch = {
|
|
|
1400
1349
|
index.updateDefaultQuery(props.componentId, this.setDefaultQuery, props, value);
|
|
1401
1350
|
}
|
|
1402
1351
|
|
|
1403
|
-
this.setQueryOptions(this.internalComponent, _rollupPluginBabelHelpers._extends({}, this.queryOptions, defaultQueryOptions));
|
|
1352
|
+
this.setQueryOptions(this.internalComponent, _rollupPluginBabelHelpers._extends({}, this.queryOptions, defaultQueryOptions), false);
|
|
1404
1353
|
this.updateQuery({
|
|
1405
1354
|
componentId: this.internalComponent,
|
|
1406
1355
|
query: query,
|
|
@@ -1427,7 +1376,7 @@ var DataSearch = {
|
|
|
1427
1376
|
|
|
1428
1377
|
customQueryOptions = getOptionsFromQuery(customQueryTobeSet);
|
|
1429
1378
|
index.updateCustomQuery(props.componentId, this.setCustomQuery, props, value);
|
|
1430
|
-
this.setQueryOptions(componentId, _rollupPluginBabelHelpers._extends({}, this.queryOptions, customQueryOptions));
|
|
1379
|
+
this.setQueryOptions(componentId, _rollupPluginBabelHelpers._extends({}, this.queryOptions, customQueryOptions), false);
|
|
1431
1380
|
}
|
|
1432
1381
|
|
|
1433
1382
|
if (!this.isPending) {
|
|
@@ -1590,7 +1539,7 @@ var DataSearch = {
|
|
|
1590
1539
|
var h = this.$createElement;
|
|
1591
1540
|
|
|
1592
1541
|
if (this.$props.showClear) {
|
|
1593
|
-
return this.$props.clearIcon || h(CancelSvg);
|
|
1542
|
+
return this.$props.clearIcon || h(CancelSvg.CancelSvg);
|
|
1594
1543
|
}
|
|
1595
1544
|
|
|
1596
1545
|
return null;
|
|
@@ -1659,12 +1608,12 @@ var DataSearch = {
|
|
|
1659
1608
|
showIcon = _this$$props3.showIcon;
|
|
1660
1609
|
var renderMic = this.$scopedSlots.renderMic || this.$props.renderMic;
|
|
1661
1610
|
var currentValue = this.$data.currentValue;
|
|
1662
|
-
return h("div", [h(IconGroup, {
|
|
1611
|
+
return h("div", [h(CancelSvg.IconGroup, {
|
|
1663
1612
|
"attrs": {
|
|
1664
1613
|
"groupPosition": "right",
|
|
1665
1614
|
"positionType": "absolute"
|
|
1666
1615
|
}
|
|
1667
|
-
}, [currentValue && showClear && h(IconWrapper, {
|
|
1616
|
+
}, [currentValue && showClear && h(CancelSvg.IconWrapper, {
|
|
1668
1617
|
"on": {
|
|
1669
1618
|
"click": this.clearValue
|
|
1670
1619
|
},
|
|
@@ -1679,16 +1628,16 @@ var DataSearch = {
|
|
|
1679
1628
|
"handleResult": this.handleVoiceResults,
|
|
1680
1629
|
"className": getClassName$1(innerClass, 'mic') || null
|
|
1681
1630
|
}
|
|
1682
|
-
}), iconPosition === 'right' && showIcon && h(IconWrapper, {
|
|
1631
|
+
}), iconPosition === 'right' && showIcon && h(CancelSvg.IconWrapper, {
|
|
1683
1632
|
"on": {
|
|
1684
1633
|
"click": this.handleSearchIconClick
|
|
1685
1634
|
}
|
|
1686
|
-
}, [this.renderIcon()])]), h(IconGroup, {
|
|
1635
|
+
}, [this.renderIcon()])]), h(CancelSvg.IconGroup, {
|
|
1687
1636
|
"attrs": {
|
|
1688
1637
|
"groupPosition": "left",
|
|
1689
1638
|
"positionType": "absolute"
|
|
1690
1639
|
}
|
|
1691
|
-
}, [iconPosition === 'left' && showIcon && h(IconWrapper, {
|
|
1640
|
+
}, [iconPosition === 'left' && showIcon && h(CancelSvg.IconWrapper, {
|
|
1692
1641
|
"on": {
|
|
1693
1642
|
"click": this.handleSearchIconClick
|
|
1694
1643
|
}
|
|
@@ -1761,7 +1710,7 @@ var DataSearch = {
|
|
|
1761
1710
|
"class": this.$props.className
|
|
1762
1711
|
}, [this.$props.title && h(Title.Title, {
|
|
1763
1712
|
"class": getClassName$1(this.$props.innerClass, 'title') || ''
|
|
1764
|
-
}, [this.$props.title]), this.$props.defaultSuggestions || this.$props.autosuggest ? h(
|
|
1713
|
+
}, [this.$props.title]), this.$props.defaultSuggestions || this.$props.autosuggest ? h(CancelSvg.Downshift, {
|
|
1765
1714
|
"attrs": {
|
|
1766
1715
|
"id": this.$props.componentId + "-downshift",
|
|
1767
1716
|
"handleChange": this.onSuggestionSelected,
|
|
@@ -1786,7 +1735,7 @@ var DataSearch = {
|
|
|
1786
1735
|
highlightedIndex: highlightedIndex
|
|
1787
1736
|
}), _this3.renderErrorComponent(), !_this3.hasCustomRenderer && isOpen && hasSuggestions ? h("ul", {
|
|
1788
1737
|
"class": Input.suggestions(_this3.themePreset, theme) + " " + getClassName$1(_this3.$props.innerClass, 'list')
|
|
1789
|
-
}, [_this3.suggestionsList.slice(0, size).map(function (item, index) {
|
|
1738
|
+
}, [_this3.suggestionsList.slice(0, size || 10).map(function (item, index) {
|
|
1790
1739
|
return h("li", {
|
|
1791
1740
|
"domProps": _rollupPluginBabelHelpers._extends({}, getItemProps({
|
|
1792
1741
|
item: item
|
|
@@ -1878,7 +1827,7 @@ var DataSearch = {
|
|
|
1878
1827
|
|
|
1879
1828
|
return h("div", {
|
|
1880
1829
|
"class": Input.suggestionsContainer
|
|
1881
|
-
}, [h(InputGroup, [_this3.renderInputAddonBefore(), h(InputWrapper, [h(Input.Input, {
|
|
1830
|
+
}, [h(InputGroup, [_this3.renderInputAddonBefore(), h(CancelSvg.InputWrapper, [h(Input.Input, {
|
|
1882
1831
|
"attrs": {
|
|
1883
1832
|
"id": _this3.$props.componentId + "-input",
|
|
1884
1833
|
"showIcon": _this3.$props.showIcon,
|
|
@@ -1922,7 +1871,7 @@ var DataSearch = {
|
|
|
1922
1871
|
}
|
|
1923
1872
|
}) : h("div", {
|
|
1924
1873
|
"class": Input.suggestionsContainer
|
|
1925
|
-
}, [h(InputGroup, [this.renderInputAddonBefore(), h(InputWrapper, [h(Input.Input, {
|
|
1874
|
+
}, [h(InputGroup, [this.renderInputAddonBefore(), h(CancelSvg.InputWrapper, [h(Input.Input, {
|
|
1926
1875
|
"class": getClassName$1(this.$props.innerClass, 'input') || '',
|
|
1927
1876
|
"attrs": {
|
|
1928
1877
|
"placeholder": this.$props.placeholder,
|
|
@@ -9,10 +9,11 @@ var VueTypes = _interopDefault(require('vue-types'));
|
|
|
9
9
|
var emotion = require('emotion');
|
|
10
10
|
var styled = require('@appbaseio/vue-emotion');
|
|
11
11
|
var styled__default = _interopDefault(styled);
|
|
12
|
-
var vueTypes = require('./vueTypes-
|
|
12
|
+
var vueTypes = require('./vueTypes-57d01f18.js');
|
|
13
13
|
var index = require('./index-89c39a9e.js');
|
|
14
|
+
var CancelSvg = require('./CancelSvg-4aa35935.js');
|
|
14
15
|
var Input = require('./Input-3cc3fa59.js');
|
|
15
|
-
var
|
|
16
|
+
var suggestions = require('@appbaseio/reactivecore/lib/utils/suggestions');
|
|
16
17
|
|
|
17
18
|
var _templateObject, _templateObject2, _templateObject3, _templateObject4;
|
|
18
19
|
var small = emotion.css(_templateObject || (_templateObject = _rollupPluginBabelHelpers._taggedTemplateLiteralLoose(["\n\tmin-height: 0;\n\theight: 30px;\n\tborder: 0;\n\tbox-shadow: rgba(0, 0, 0, 0.3) 0px 1px 4px -1px;\n\tborder-radius: 2px;\n"])));
|
|
@@ -74,7 +75,9 @@ var Dropdown = {
|
|
|
74
75
|
single: VueTypes.bool,
|
|
75
76
|
small: VueTypes.bool.def(false),
|
|
76
77
|
themePreset: vueTypes.types.themePreset,
|
|
77
|
-
showSearch: VueTypes.bool
|
|
78
|
+
showSearch: VueTypes.bool,
|
|
79
|
+
showClear: VueTypes.bool,
|
|
80
|
+
searchPlaceholder: VueTypes.string.def('Type here to search...')
|
|
78
81
|
},
|
|
79
82
|
render: function render() {
|
|
80
83
|
var _this = this;
|
|
@@ -102,7 +105,7 @@ var Dropdown = {
|
|
|
102
105
|
var filteredItemsToRender = itemsToRender.filter(function (item) {
|
|
103
106
|
if (String(item[labelField]).length) {
|
|
104
107
|
if (_this.$props.showSearch && _this.$data.searchTerm) {
|
|
105
|
-
return String(item[labelField]).toLowerCase().includes(_this.$data.searchTerm.toLowerCase());
|
|
108
|
+
return suggestions.replaceDiacritics(String(item[labelField])).toLowerCase().includes(suggestions.replaceDiacritics(_this.$data.searchTerm.toLowerCase()));
|
|
106
109
|
}
|
|
107
110
|
|
|
108
111
|
return true;
|
|
@@ -110,7 +113,7 @@ var Dropdown = {
|
|
|
110
113
|
|
|
111
114
|
return false;
|
|
112
115
|
});
|
|
113
|
-
return h(
|
|
116
|
+
return h(CancelSvg.Downshift, {
|
|
114
117
|
"attrs": {
|
|
115
118
|
"isOpen": this.$data.isOpen,
|
|
116
119
|
"selectedItem": selectedItem,
|
|
@@ -148,25 +151,10 @@ var Dropdown = {
|
|
|
148
151
|
getItemEvents: getItemEvents
|
|
149
152
|
}) : isOpen && itemsToRender.length ? h("ul", {
|
|
150
153
|
"class": Input.suggestions(themePreset, _this.theme) + " " + (_this.$props.small ? 'small' : '') + " " + getClassName(_this.$props.innerClass, 'list')
|
|
151
|
-
}, [_this.$props.showSearch ?
|
|
152
|
-
"attrs": {
|
|
153
|
-
"id": _this.$props.componentId + "-input",
|
|
154
|
-
"showIcon": false,
|
|
155
|
-
"placeholder": "Type here to search...",
|
|
156
|
-
"value": _this.$data.searchTerm,
|
|
157
|
-
"themePreset": themePreset
|
|
158
|
-
},
|
|
159
|
-
"style": {
|
|
160
|
-
border: 0,
|
|
161
|
-
borderBottom: '1px solid #ddd'
|
|
162
|
-
},
|
|
163
|
-
"class": getClassName(_this.$props.innerClass, 'input'),
|
|
164
|
-
"on": {
|
|
165
|
-
"change": _this.handleInputChange
|
|
166
|
-
}
|
|
167
|
-
}) : null, !hasCustomRenderer && filteredItemsToRender.length === 0 ? _this.renderNoResult() : filteredItemsToRender.map(function (item, index) {
|
|
154
|
+
}, [_this.$props.showSearch ? _this.renderSearchbox() : null, !hasCustomRenderer && filteredItemsToRender.length === 0 ? _this.renderNoResult() : filteredItemsToRender.map(function (item, index) {
|
|
168
155
|
var selected = _this.$props.multi // MultiDropdownList
|
|
169
|
-
&& (selectedItem && !!selectedItem[item[keyField]]
|
|
156
|
+
&& (selectedItem && !!selectedItem[item[keyField]] // MultiDropdownRange
|
|
157
|
+
|| Array.isArray(selectedItem) && selectedItem.find(function (value) {
|
|
170
158
|
return value[labelField] === item[labelField];
|
|
171
159
|
}));
|
|
172
160
|
if (!_this.$props.multi) selected = item.key === selectedItem;
|
|
@@ -216,6 +204,7 @@ var Dropdown = {
|
|
|
216
204
|
|
|
217
205
|
if (!this.$props.multi) {
|
|
218
206
|
this.isOpen = false;
|
|
207
|
+
this.searchTerm = '';
|
|
219
208
|
}
|
|
220
209
|
},
|
|
221
210
|
handleStateChange: function handleStateChange(_ref2) {
|
|
@@ -239,6 +228,9 @@ var Dropdown = {
|
|
|
239
228
|
var value = e.target.value;
|
|
240
229
|
this.searchTerm = value;
|
|
241
230
|
},
|
|
231
|
+
clearSearchTerm: function clearSearchTerm() {
|
|
232
|
+
this.searchTerm = '';
|
|
233
|
+
},
|
|
242
234
|
renderToString: function renderToString(value) {
|
|
243
235
|
var _this2 = this;
|
|
244
236
|
|
|
@@ -279,6 +271,51 @@ var Dropdown = {
|
|
|
279
271
|
return h("p", {
|
|
280
272
|
"class": getClassName(this.$props.innerClass, 'noResults') || null
|
|
281
273
|
}, [index.isFunction(renderNoResults) ? renderNoResults() : renderNoResults]);
|
|
274
|
+
},
|
|
275
|
+
renderSearchbox: function renderSearchbox() {
|
|
276
|
+
var h = this.$createElement;
|
|
277
|
+
var _this$$props2 = this.$props,
|
|
278
|
+
componentId = _this$$props2.componentId,
|
|
279
|
+
searchPlaceholder = _this$$props2.searchPlaceholder,
|
|
280
|
+
showClear = _this$$props2.showClear,
|
|
281
|
+
themePreset = _this$$props2.themePreset,
|
|
282
|
+
innerClass = _this$$props2.innerClass;
|
|
283
|
+
var InputComponent = h(Input.Input, {
|
|
284
|
+
"attrs": {
|
|
285
|
+
"id": componentId + "-input",
|
|
286
|
+
"showIcon": false,
|
|
287
|
+
"showClear": showClear,
|
|
288
|
+
"placeholder": searchPlaceholder,
|
|
289
|
+
"value": this.$data.searchTerm,
|
|
290
|
+
"themePreset": themePreset
|
|
291
|
+
},
|
|
292
|
+
"style": {
|
|
293
|
+
border: 0,
|
|
294
|
+
borderBottom: '1px solid #ddd'
|
|
295
|
+
},
|
|
296
|
+
"class": getClassName(innerClass, 'input'),
|
|
297
|
+
"on": {
|
|
298
|
+
"change": this.handleInputChange
|
|
299
|
+
}
|
|
300
|
+
});
|
|
301
|
+
|
|
302
|
+
if (showClear) {
|
|
303
|
+
return h(CancelSvg.InputWrapper, [InputComponent, this.searchTerm && h(CancelSvg.IconGroup, {
|
|
304
|
+
"attrs": {
|
|
305
|
+
"groupPosition": "right",
|
|
306
|
+
"positionType": "absolute"
|
|
307
|
+
}
|
|
308
|
+
}, [h(CancelSvg.IconWrapper, {
|
|
309
|
+
"on": {
|
|
310
|
+
"click": this.clearSearchTerm
|
|
311
|
+
},
|
|
312
|
+
"attrs": {
|
|
313
|
+
"isClearIcon": true
|
|
314
|
+
}
|
|
315
|
+
}, [h(CancelSvg.CancelSvg)])])]);
|
|
316
|
+
}
|
|
317
|
+
|
|
318
|
+
return InputComponent;
|
|
282
319
|
}
|
|
283
320
|
}
|
|
284
321
|
};
|
|
@@ -10,13 +10,13 @@ var _rollupPluginBabelHelpers = require('./_rollupPluginBabelHelpers-f127c8b7.js
|
|
|
10
10
|
var VueTypes = _interopDefault(require('vue-types'));
|
|
11
11
|
var constants = require('@appbaseio/reactivecore/lib/utils/constants');
|
|
12
12
|
require('@appbaseio/vue-emotion');
|
|
13
|
-
var vueTypes = require('./vueTypes-
|
|
13
|
+
var vueTypes = require('./vueTypes-57d01f18.js');
|
|
14
14
|
require('redux');
|
|
15
15
|
var index = require('./index-89c39a9e.js');
|
|
16
16
|
var Title = require('./Title-584a8cc8.js');
|
|
17
17
|
var Container = require('./Container-526efa6a.js');
|
|
18
18
|
var NoSSR = _interopDefault(require('vue-no-ssr'));
|
|
19
|
-
var ssr = require('./ssr-
|
|
19
|
+
var ssr = require('./ssr-0ee35a09.js');
|
|
20
20
|
|
|
21
21
|
var addComponent = configureStore.Actions.addComponent,
|
|
22
22
|
removeComponent = configureStore.Actions.removeComponent,
|
|
@@ -183,8 +183,9 @@ var DynamicRangeSlider = {
|
|
|
183
183
|
aggs: aggs
|
|
184
184
|
});
|
|
185
185
|
},
|
|
186
|
-
handleSlider: function handleSlider(
|
|
187
|
-
this.
|
|
186
|
+
handleSlider: function handleSlider() {
|
|
187
|
+
var sliderValues = this.$refs.slider.getValue();
|
|
188
|
+
this.handleChange(sliderValues);
|
|
188
189
|
},
|
|
189
190
|
handleChange: function handleChange(currentValue) {
|
|
190
191
|
var _this2 = this;
|
|
@@ -236,7 +237,7 @@ var DynamicRangeSlider = {
|
|
|
236
237
|
currentEnd = value[1]; // check if the slider is at its initial position
|
|
237
238
|
|
|
238
239
|
var isInitialValue = currentStart === start && currentEnd === end;
|
|
239
|
-
this.setQueryOptions(this.$props.componentId, customQueryOptions);
|
|
240
|
+
this.setQueryOptions(this.$props.componentId, customQueryOptions, false);
|
|
240
241
|
this.updateQuery({
|
|
241
242
|
componentId: this.$props.componentId,
|
|
242
243
|
query: query,
|
|
@@ -317,13 +318,15 @@ var DynamicRangeSlider = {
|
|
|
317
318
|
}, [this.$props.title]), h(NoSSR, [h(ssr.Slider, {
|
|
318
319
|
"class": getClassName(this.$props.innerClass, 'slider')
|
|
319
320
|
}, [h("vue-slider-component", {
|
|
321
|
+
"ref": "slider",
|
|
320
322
|
"attrs": {
|
|
321
323
|
"value": [Math.max(start, this.currentValue[0]), Math.min(end, this.currentValue[1])],
|
|
322
324
|
"min": Math.min(start, this.currentValue[0]),
|
|
323
325
|
"max": Math.max(end, this.currentValue[1]),
|
|
324
326
|
"dotSize": 20,
|
|
325
327
|
"height": 4,
|
|
326
|
-
"enable-cross": false
|
|
328
|
+
"enable-cross": false,
|
|
329
|
+
"tooltip": "always"
|
|
327
330
|
},
|
|
328
331
|
"on": {
|
|
329
332
|
"drag-end": this.handleSlider
|