@appbaseio/reactivesearch-vue 3.0.0-alpha.2 → 3.0.0-alpha.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.
Files changed (52) hide show
  1. package/dist/@appbaseio/reactivesearch-vue.umd.js +2315 -605
  2. package/dist/@appbaseio/reactivesearch-vue.umd.js.map +1 -1
  3. package/dist/@appbaseio/reactivesearch-vue.umd.min.js +5 -5
  4. package/dist/@appbaseio/reactivesearch-vue.umd.min.js.map +1 -1
  5. package/dist/cjs/{ComponentWrapper-611cf7f9.js → ComponentWrapper-2dc930e1.js} +20 -19
  6. package/dist/cjs/{DropDown-dc184468.js → DropDown-7bd56543.js} +3 -4
  7. package/dist/cjs/DynamicRangeSlider.js +50 -49
  8. package/dist/cjs/MultiDropdownList.js +33 -33
  9. package/dist/cjs/MultiList.js +29 -30
  10. package/dist/cjs/MultiRange.js +17 -17
  11. package/dist/cjs/{Pagination-b5ddc906.js → Pagination-4ffc67cd.js} +3 -4
  12. package/dist/cjs/{PreferencesConsumer-22d1b49f.js → PreferencesConsumer-2c69ac61.js} +1 -1
  13. package/dist/cjs/RangeInput.js +6 -7
  14. package/dist/cjs/RangeSlider.js +14 -14
  15. package/dist/cjs/ReactiveBase.js +32 -13
  16. package/dist/cjs/{ReactiveComponent-0a6b819b.js → ReactiveComponent-4435adfa.js} +84 -81
  17. package/dist/cjs/ReactiveComponent.js +7 -7
  18. package/dist/cjs/ReactiveGoogleMap.js +33 -34
  19. package/dist/cjs/ReactiveList.js +37 -27
  20. package/dist/cjs/SelectedFilters.js +7 -8
  21. package/dist/cjs/SingleDropdownList.js +23 -24
  22. package/dist/cjs/SingleList.js +20 -21
  23. package/dist/cjs/SingleRange.js +14 -14
  24. package/dist/cjs/StateProvider.js +4 -5
  25. package/dist/cjs/ToggleButton.js +17 -18
  26. package/dist/cjs/{index-d8d8f291.js → index-1481798c.js} +4 -7
  27. package/dist/cjs/index.js +11 -16
  28. package/dist/cjs/initReactivesearch.js +10 -464
  29. package/dist/cjs/install.js +8 -7
  30. package/dist/cjs/{utils-83fd01e9.js → utils-36b1b880.js} +2 -5
  31. package/dist/cjs/version.js +1 -1
  32. package/dist/es/{ComponentWrapper-3dfe6931.js → ComponentWrapper-3a215eed.js} +9 -7
  33. package/dist/es/DynamicRangeSlider.js +32 -30
  34. package/dist/es/MultiDropdownList.js +16 -15
  35. package/dist/es/MultiList.js +15 -15
  36. package/dist/es/MultiRange.js +7 -6
  37. package/dist/es/RangeInput.js +1 -1
  38. package/dist/es/RangeSlider.js +4 -3
  39. package/dist/es/ReactiveBase.js +27 -8
  40. package/dist/es/{ReactiveComponent-8fb219ec.js → ReactiveComponent-04d94e01.js} +38 -34
  41. package/dist/es/ReactiveComponent.js +2 -2
  42. package/dist/es/ReactiveGoogleMap.js +11 -11
  43. package/dist/es/ReactiveList.js +16 -5
  44. package/dist/es/SingleDropdownList.js +6 -6
  45. package/dist/es/SingleList.js +6 -6
  46. package/dist/es/SingleRange.js +4 -3
  47. package/dist/es/ToggleButton.js +6 -6
  48. package/dist/es/index.js +6 -11
  49. package/dist/es/initReactivesearch.js +9 -463
  50. package/dist/es/install.js +3 -2
  51. package/dist/es/version.js +1 -1
  52. package/package.json +2 -2
@@ -4,8 +4,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; }
6
6
 
7
- var configureStore = require('@appbaseio/reactivecore');
8
- var configureStore__default = _interopDefault(configureStore);
7
+ var reactivecore = require('@appbaseio/reactivecore');
9
8
  var constants = require('@appbaseio/reactivecore/lib/utils/constants');
10
9
  require('./_rollupPluginBabelHelpers-f8b843f8.js');
11
10
  var vue = require('vue');
@@ -14,20 +13,20 @@ require('@appbaseio/vue-emotion');
14
13
  var vueTypes = require('./vueTypes-1bf00978.js');
15
14
  require('@appbaseio/reactivecore/lib/utils/transform');
16
15
  require('redux');
17
- var index = require('./index-d8d8f291.js');
18
- var ComponentWrapper = require('./ComponentWrapper-611cf7f9.js');
19
- var PreferencesConsumer = require('./PreferencesConsumer-22d1b49f.js');
16
+ var index = require('./index-1481798c.js');
17
+ var ComponentWrapper = require('./ComponentWrapper-2dc930e1.js');
18
+ var PreferencesConsumer = require('./PreferencesConsumer-2c69ac61.js');
20
19
  var Title = require('./Title-8802a218.js');
21
20
  var Container = require('./Container-29f049b2.js');
22
21
  var ssr = require('./ssr-c58b64c4.js');
23
22
 
24
- var updateQuery = configureStore.Actions.updateQuery,
25
- setQueryOptions = configureStore.Actions.setQueryOptions,
26
- setCustomQuery = configureStore.Actions.setCustomQuery;
27
- var checkValueChange = configureStore.helper.checkValueChange,
28
- getClassName = configureStore.helper.getClassName,
29
- getOptionsFromQuery = configureStore.helper.getOptionsFromQuery,
30
- isEqual = configureStore.helper.isEqual;
23
+ var updateQuery = reactivecore.Actions.updateQuery,
24
+ setQueryOptions = reactivecore.Actions.setQueryOptions,
25
+ setCustomQuery = reactivecore.Actions.setCustomQuery;
26
+ var checkValueChange = reactivecore.helper.checkValueChange,
27
+ getClassName = reactivecore.helper.getClassName,
28
+ getOptionsFromQuery = reactivecore.helper.getOptionsFromQuery,
29
+ isEqual = reactivecore.helper.isEqual;
31
30
  var RangeSlider = {
32
31
  name: 'RangeSlider',
33
32
  components: ssr.getComponents(),
@@ -164,8 +163,6 @@ var RangeSlider = {
164
163
 
165
164
  // Set custom query in store
166
165
  index.updateCustomQuery(this.componentId, this.setCustomQuery, this.$props, this.currentValue);
167
- },
168
- beforeMount: function beforeMount() {
169
166
  var _this$$props = this.$props,
170
167
  value = _this$$props.value,
171
168
  defaultValue = _this$$props.defaultValue;
@@ -261,6 +258,9 @@ var RangeConnected = PreferencesConsumer.PreferencesConsumer(ComponentWrapper.Co
261
258
  componentType: constants.componentTypes.rangeSlider
262
259
  }));
263
260
  RangeConnected.name = RangeSlider.name;
261
+ RangeConnected.defaultQuery = RangeSlider.defaultQuery;
262
+ RangeConnected.parseValue = RangeSlider.parseValue;
263
+ RangeConnected.hasInternalComponent = RangeSlider.hasInternalComponent;
264
264
  RangeConnected.install = function (Vue) {
265
265
  Vue.component(RangeConnected.name, RangeConnected);
266
266
  };
@@ -4,8 +4,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; }
6
6
 
7
- var configureStore = require('@appbaseio/reactivecore');
8
- var configureStore__default = _interopDefault(configureStore);
7
+ var reactivecore = require('@appbaseio/reactivecore');
9
8
  require('@appbaseio/reactivecore/lib/utils/constants');
10
9
  var _rollupPluginBabelHelpers = require('./_rollupPluginBabelHelpers-f8b843f8.js');
11
10
  var vue = require('vue');
@@ -14,7 +13,9 @@ var helper = require('@appbaseio/reactivecore/lib/utils/helper');
14
13
  var vueEmotion = require('@appbaseio/vue-emotion');
15
14
  var vueTypes = require('./vueTypes-1bf00978.js');
16
15
  require('redux');
17
- var index = require('./index-d8d8f291.js');
16
+ var index = require('./index-1481798c.js');
17
+ var configureStore = require('@appbaseio/reactivecore/lib');
18
+ var configureStore__default = _interopDefault(configureStore);
18
19
  var analytics = require('@appbaseio/reactivecore/lib/actions/analytics');
19
20
  var Appbase = _interopDefault(require('appbase-js'));
20
21
  var AppbaseAnalytics = _interopDefault(require('@appbaseio/analytics'));
@@ -86,9 +87,9 @@ var Base$1 = vueEmotion.styled(Base)(_templateObject || (_templateObject = _roll
86
87
  function _isSlot$1(s) {
87
88
  return typeof s === 'function' || Object.prototype.toString.call(s) === '[object Object]' && !vue.isVNode(s);
88
89
  }
89
- var setHeaders = configureStore.Actions.setHeaders,
90
- setValue = configureStore.Actions.setValue;
91
- var isEqual = configureStore.helper.isEqual;
90
+ var setHeaders = reactivecore.Actions.setHeaders,
91
+ setValue = reactivecore.Actions.setValue;
92
+ var isEqual = reactivecore.helper.isEqual;
92
93
  var URLParamsProvider = {
93
94
  name: 'URLParamsProvider',
94
95
  props: {
@@ -115,12 +116,12 @@ var URLParamsProvider = {
115
116
  try {
116
117
  var component = item[0],
117
118
  value = item[1];
118
- var _ref = _this.selectedValues[component] || {
119
+ var _ref2 = _this.selectedValues[component] || {
119
120
  label: component
120
121
  },
121
- label = _ref.label,
122
- showFilter = _ref.showFilter,
123
- URLParams = _ref.URLParams;
122
+ label = _ref2.label,
123
+ showFilter = _ref2.showFilter,
124
+ URLParams = _ref2.URLParams;
124
125
  _this.setValue(component, JSON.parse(value), label, showFilter, URLParams, undefined, undefined, undefined, 'URL');
125
126
  } catch (e) {
126
127
  // Do not set value if JSON parsing fails.
@@ -337,6 +338,7 @@ function getTheme(preset) {
337
338
  function _isSlot$2(s) {
338
339
  return typeof s === 'function' || Object.prototype.toString.call(s) === '[object Object]' && !vue.isVNode(s);
339
340
  }
341
+ var setValues = configureStore.Actions.setValues;
340
342
  var ReactiveBase = {
341
343
  name: 'ReactiveBase',
342
344
  data: function data() {
@@ -363,6 +365,7 @@ var ReactiveBase = {
363
365
  initialQueriesSyncTime: vueTypes.types.number,
364
366
  className: vueTypes.types.string,
365
367
  initialState: VueTypes.object.def({}),
368
+ contextCollector: VueTypes.func,
366
369
  transformRequest: vueTypes.types.func,
367
370
  transformResponse: vueTypes.types.func,
368
371
  as: VueTypes.string.def('div'),
@@ -373,11 +376,15 @@ var ReactiveBase = {
373
376
  preferences: VueTypes.object
374
377
  },
375
378
  provide: function provide() {
379
+ var createCacheFn = vueEmotion.createCache;
380
+ if (vueEmotion.createCache["default"]) {
381
+ createCacheFn = vueEmotion.createCache["default"];
382
+ }
376
383
  return {
377
384
  theme_reactivesearch: index.composeThemeObject(getTheme(this.$props.themePreset), this.$props.theme),
378
385
  store: this.store,
379
386
  $searchPreferences: this.preferences,
380
- $emotionCache: this.$parent && this.$parent.$emotionCache || vueEmotion.createCache({
387
+ $emotionCache: this.$parent && this.$parent.$emotionCache || createCacheFn({
381
388
  key: 'css'
382
389
  })
383
390
  };
@@ -531,8 +538,20 @@ var ReactiveBase = {
531
538
  selectedValues: selectedValues,
532
539
  urlValues: urlValues,
533
540
  headers: this.getHeaders
534
- }, this.$props.initialState);
535
- this.store = configureStore__default(initialState);
541
+ }, this.initialState);
542
+ var storeFn = configureStore__default;
543
+ if (configureStore__default["default"]) {
544
+ storeFn = configureStore__default["default"];
545
+ }
546
+ this.store = storeFn(initialState);
547
+ // server side rendered app to collect context
548
+ if (typeof window === 'undefined' && props.contextCollector) {
549
+ var res = props.contextCollector({
550
+ ctx: this.store
551
+ });
552
+ // necessary for supporting SSR of queryParams
553
+ this.store.dispatch(setValues(res.selectedValues));
554
+ }
536
555
  this.analyticsRef = analyticsRef;
537
556
  }
538
557
  },
@@ -2,8 +2,7 @@
2
2
 
3
3
  function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; }
4
4
 
5
- var configureStore = require('@appbaseio/reactivecore');
6
- var configureStore__default = _interopDefault(configureStore);
5
+ var reactivecore = require('@appbaseio/reactivecore');
7
6
  var constants = require('@appbaseio/reactivecore/lib/utils/constants');
8
7
  var _transformOn = _interopDefault(require('@vue/babel-helper-vue-transform-on'));
9
8
  var _rollupPluginBabelHelpers = require('./_rollupPluginBabelHelpers-f8b843f8.js');
@@ -15,13 +14,13 @@ var emotion = require('emotion');
15
14
  var Button = require('./Button-ad042719.js');
16
15
  var vueTypes = require('./vueTypes-1bf00978.js');
17
16
  var ReactiveList = require('./ReactiveList.js');
18
- var index = require('./index-d8d8f291.js');
19
- var ComponentWrapper = require('./ComponentWrapper-611cf7f9.js');
20
- var PreferencesConsumer = require('./PreferencesConsumer-22d1b49f.js');
17
+ var index = require('./index-1481798c.js');
18
+ var ComponentWrapper = require('./ComponentWrapper-2dc930e1.js');
19
+ var PreferencesConsumer = require('./PreferencesConsumer-2c69ac61.js');
21
20
  var Title = require('./Title-8802a218.js');
22
21
  var Flex = require('./Flex-d5675ea6.js');
23
22
  var hotkeys = _interopDefault(require('hotkeys-js'));
24
- var DropDown = require('./DropDown-dc184468.js');
23
+ var DropDown = require('./DropDown-7bd56543.js');
25
24
  var Input = require('./Input-088dfcb4.js');
26
25
  var Container = require('./Container-29f049b2.js');
27
26
  var Highlight = _interopDefault(require('vue-highlight-words'));
@@ -48,7 +47,7 @@ InputAddon.defaultProps = {
48
47
  className: 'input-addon'
49
48
  };
50
49
 
51
- var getClassName = configureStore.helper.getClassName;
50
+ var getClassName = reactivecore.helper.getClassName;
52
51
  var SuggestionWrapper = {
53
52
  name: 'SuggestionWrapper',
54
53
  props: {
@@ -517,14 +516,14 @@ var Mic = {
517
516
  if (status === STATUS.active) {
518
517
  this.status = STATUS.inactive;
519
518
  }
520
- var _this$$props = this.$props,
521
- handleResult = _this$$props.handleResult,
522
- onNoMatch = _this$$props.onNoMatch,
523
- onError = _this$$props.onError,
524
- lang = _this$$props.lang,
525
- getInstance = _this$$props.getInstance;
526
- var _window = window,
527
- SpeechRecognition = _window.SpeechRecognition;
519
+ var _this$$props2 = this.$props,
520
+ handleResult = _this$$props2.handleResult,
521
+ onNoMatch = _this$$props2.onNoMatch,
522
+ onError = _this$$props2.onError,
523
+ lang = _this$$props2.lang,
524
+ getInstance = _this$$props2.getInstance;
525
+ var _window2 = window,
526
+ SpeechRecognition = _window2.SpeechRecognition;
528
527
  if (this.instance && this.status !== STATUS.denied) {
529
528
  this.status = STATUS.inactive;
530
529
  this.instance.stop();
@@ -748,17 +747,17 @@ var TagItem = vueEmotion.styled('span')(_templateObject2 || (_templateObject2 =
748
747
  function _isSlot(s) {
749
748
  return typeof s === 'function' || Object.prototype.toString.call(s) === '[object Object]' && !vue.isVNode(s);
750
749
  }
751
- var updateQuery = configureStore.Actions.updateQuery,
752
- setCustomQuery = configureStore.Actions.setCustomQuery,
753
- setDefaultQuery = configureStore.Actions.setDefaultQuery,
754
- recordSuggestionClick = configureStore.Actions.recordSuggestionClick;
755
- var _debounce = configureStore.helper.debounce,
756
- checkValueChange = configureStore.helper.checkValueChange,
757
- getClassName$1 = configureStore.helper.getClassName,
758
- isEqual = configureStore.helper.isEqual,
759
- getCompositeAggsQuery = configureStore.helper.getCompositeAggsQuery,
760
- withClickIds = configureStore.helper.withClickIds,
761
- getResultStats = configureStore.helper.getResultStats;
750
+ var updateQuery = reactivecore.Actions.updateQuery,
751
+ setCustomQuery = reactivecore.Actions.setCustomQuery,
752
+ setDefaultQuery = reactivecore.Actions.setDefaultQuery,
753
+ recordSuggestionClick = reactivecore.Actions.recordSuggestionClick;
754
+ var _debounce = reactivecore.helper.debounce,
755
+ checkValueChange = reactivecore.helper.checkValueChange,
756
+ getClassName$1 = reactivecore.helper.getClassName,
757
+ isEqual = reactivecore.helper.isEqual,
758
+ getCompositeAggsQuery = reactivecore.helper.getCompositeAggsQuery,
759
+ withClickIds = reactivecore.helper.withClickIds,
760
+ getResultStats = reactivecore.helper.getResultStats;
762
761
  var SearchBox = vue.defineComponent({
763
762
  name: 'SearchBox',
764
763
  isTagsMode: false,
@@ -795,6 +794,13 @@ var SearchBox = vue.defineComponent({
795
794
  // Set custom and default queries in store
796
795
  this.triggerCustomQuery(this.currentValue, this.selectedCategory);
797
796
  this.triggerDefaultQuery(this.currentValue);
797
+ if (this.selectedValue) {
798
+ this.setValue(this.selectedValue, true, this.$props, this.$options.isTagsMode ? reactivecore.causes.SUGGESTION_SELECT : undefined);
799
+ } else if (this.$props.value) {
800
+ this.setValue(this.$props.value, true, this.$props, this.$options.isTagsMode ? reactivecore.causes.SUGGESTION_SELECT : undefined);
801
+ } else if (this.$props.defaultValue) {
802
+ this.setValue(this.$props.defaultValue, true, this.$props, this.$options.isTagsMode ? reactivecore.causes.SUGGESTION_SELECT : undefined);
803
+ }
798
804
  },
799
805
  computed: {
800
806
  hasCustomRenderer: function hasCustomRenderer() {
@@ -885,15 +891,6 @@ var SearchBox = vue.defineComponent({
885
891
  searchboxId: VueTypes.string,
886
892
  endpoint: vueTypes.types.endpointConfig
887
893
  },
888
- beforeMount: function beforeMount() {
889
- if (this.selectedValue) {
890
- this.setValue(this.selectedValue, true, this.$props, this.$options.isTagsMode ? configureStore.causes.SUGGESTION_SELECT : undefined);
891
- } else if (this.$props.value) {
892
- this.setValue(this.$props.value, true, this.$props, this.$options.isTagsMode ? configureStore.causes.SUGGESTION_SELECT : undefined);
893
- } else if (this.$props.defaultValue) {
894
- this.setValue(this.$props.defaultValue, true, this.$props, this.$options.isTagsMode ? configureStore.causes.SUGGESTION_SELECT : undefined);
895
- }
896
- },
897
894
  mounted: function mounted() {
898
895
  this.listenForFocusShortcuts();
899
896
  },
@@ -917,7 +914,7 @@ var SearchBox = vue.defineComponent({
917
914
  },
918
915
  value: function value(newVal, oldVal) {
919
916
  if (!isEqual(newVal, oldVal)) {
920
- this.setValue(newVal, true, this.$props, newVal === '' ? configureStore.causes.CLEAR_VALUE : undefined, false);
917
+ this.setValue(newVal, true, this.$props, newVal === '' ? reactivecore.causes.CLEAR_VALUE : undefined, false);
921
918
  }
922
919
  },
923
920
  defaultQuery: function defaultQuery(newVal, oldVal) {
@@ -943,15 +940,15 @@ var SearchBox = vue.defineComponent({
943
940
  if (!isEqual(newVal, oldVal) && (this.$options.isTagsMode ? !isEqual(this.$data.selectedTags, newVal) : this.$data.currentValue !== newVal)) {
944
941
  if (!newVal && this.$data.currentValue) {
945
942
  // selected value is cleared, call onValueSelected
946
- this.onValueSelectedHandler('', configureStore.causes.CLEAR_VALUE);
943
+ this.onValueSelectedHandler('', reactivecore.causes.CLEAR_VALUE);
947
944
  }
948
945
  if (this.$options.isTagsMode) {
949
946
  // handling reset of tags through SelectedFilters or URL
950
947
  this.selectedTags = [];
951
948
  }
952
- var cause = !newVal ? configureStore.causes.CLEAR_VALUE : undefined;
949
+ var cause = !newVal ? reactivecore.causes.CLEAR_VALUE : undefined;
953
950
  if (this.$options.isTagsMode) {
954
- cause = configureStore.causes.SUGGESTION_SELECT;
951
+ cause = reactivecore.causes.SUGGESTION_SELECT;
955
952
  }
956
953
  this.setValue(newVal || '', true, this.$props, cause);
957
954
  }
@@ -1003,7 +1000,7 @@ var SearchBox = vue.defineComponent({
1003
1000
  },
1004
1001
  methods: {
1005
1002
  handleText: function handleText(value, cause) {
1006
- if (cause === configureStore.causes.CLEAR_VALUE) {
1003
+ if (cause === reactivecore.causes.CLEAR_VALUE) {
1007
1004
  this.triggerCustomQuery(value);
1008
1005
  this.triggerDefaultQuery(value);
1009
1006
  } else if (this.$props.autosuggest) {
@@ -1044,7 +1041,7 @@ var SearchBox = vue.defineComponent({
1044
1041
  var currentValue = this.currentValue;
1045
1042
  if (currentValue.trim()) {
1046
1043
  this.setValue(currentValue, true);
1047
- this.onValueSelectedHandler(currentValue, configureStore.causes.SEARCH_ICON_CLICK);
1044
+ this.onValueSelectedHandler(currentValue, reactivecore.causes.SEARCH_ICON_CLICK);
1048
1045
  }
1049
1046
  },
1050
1047
  setValue: function setValue(value, isDefaultValue, props, cause, toggleIsOpen, categoryValue) {
@@ -1065,7 +1062,7 @@ var SearchBox = vue.defineComponent({
1065
1062
  if (_this.$options.isTagsMode && isEqual(value, _this.selectedTags)) {
1066
1063
  return;
1067
1064
  }
1068
- if (_this.$options.isTagsMode && cause === configureStore.causes.SUGGESTION_SELECT) {
1065
+ if (_this.$options.isTagsMode && cause === reactivecore.causes.SUGGESTION_SELECT) {
1069
1066
  if (Array.isArray(_this.selectedTags) && _this.selectedTags.length) {
1070
1067
  // check if value already present in selectedTags
1071
1068
  if (typeof value === 'string' && _this.selectedTags.includes(value)) {
@@ -1086,7 +1083,7 @@ var SearchBox = vue.defineComponent({
1086
1083
  _this.currentValue = index.decodeHtml(value);
1087
1084
  }
1088
1085
  var queryHandlerValue = value;
1089
- if (_this.$options.isTagsMode && cause === configureStore.causes.SUGGESTION_SELECT) {
1086
+ if (_this.$options.isTagsMode && cause === reactivecore.causes.SUGGESTION_SELECT) {
1090
1087
  queryHandlerValue = Array.isArray(_this.selectedTags) && _this.selectedTags.length ? _this.selectedTags : undefined;
1091
1088
  }
1092
1089
  if (isDefaultValue) {
@@ -1098,12 +1095,12 @@ var SearchBox = vue.defineComponent({
1098
1095
  } // in case of strict selection only SUGGESTION_SELECT should be able
1099
1096
  // to set the query otherwise the value should reset
1100
1097
  if (props.strictSelection) {
1101
- if (cause === configureStore.causes.SUGGESTION_SELECT || (_this.$options.isTagsMode ? _this.selectedTags.length === 0 : value === '')) {
1098
+ if (cause === reactivecore.causes.SUGGESTION_SELECT || (_this.$options.isTagsMode ? _this.selectedTags.length === 0 : value === '')) {
1102
1099
  _this.triggerCustomQuery(queryHandlerValue, _this.$options.isTagsMode ? undefined : categoryValue);
1103
1100
  } else {
1104
1101
  _this.setValue('', true);
1105
1102
  }
1106
- } else if (props.value === undefined || cause === configureStore.causes.SUGGESTION_SELECT || cause === configureStore.causes.CLEAR_VALUE) {
1103
+ } else if (props.value === undefined || cause === reactivecore.causes.SUGGESTION_SELECT || cause === reactivecore.causes.CLEAR_VALUE) {
1107
1104
  _this.triggerCustomQuery(queryHandlerValue, _this.$options.isTagsMode ? undefined : categoryValue);
1108
1105
  }
1109
1106
  } else {
@@ -1218,8 +1215,8 @@ var SearchBox = vue.defineComponent({
1218
1215
  this.recordSuggestionClick(searchPosition, docId);
1219
1216
  },
1220
1217
  clearValue: function clearValue() {
1221
- this.setValue('', false, this.$props, configureStore.causes.CLEAR_VALUE, false);
1222
- this.onValueSelectedHandler('', configureStore.causes.CLEAR_VALUE);
1218
+ this.setValue('', false, this.$props, reactivecore.causes.CLEAR_VALUE, false);
1219
+ this.onValueSelectedHandler('', reactivecore.causes.CLEAR_VALUE);
1223
1220
  },
1224
1221
  handleKeyDown: function handleKeyDown(event, highlightedIndex) {
1225
1222
  if (highlightedIndex === void 0) {
@@ -1230,10 +1227,10 @@ var SearchBox = vue.defineComponent({
1230
1227
  if (this.$props.autosuggest === false) {
1231
1228
  this.enterButtonOnClick();
1232
1229
  } else if (highlightedIndex === null) {
1233
- this.setValue(event.target.value, true, this.$props, this.$options.isTagsMode ? configureStore.causes.SUGGESTION_SELECT : undefined // to handle tags
1230
+ this.setValue(event.target.value, true, this.$props, this.$options.isTagsMode ? reactivecore.causes.SUGGESTION_SELECT : undefined // to handle tags
1234
1231
  );
1235
1232
 
1236
- this.onValueSelectedHandler(event.target.value, configureStore.causes.ENTER_PRESS);
1233
+ this.onValueSelectedHandler(event.target.value, reactivecore.causes.ENTER_PRESS);
1237
1234
  }
1238
1235
  }
1239
1236
 
@@ -1249,7 +1246,7 @@ var SearchBox = vue.defineComponent({
1249
1246
  }
1250
1247
  var value = this.$props.value;
1251
1248
  if (value === undefined) {
1252
- this.setValue(inputValue, false, this.$props, inputValue === '' ? configureStore.causes.CLEAR_VALUE : undefined);
1249
+ this.setValue(inputValue, false, this.$props, inputValue === '' ? reactivecore.causes.CLEAR_VALUE : undefined);
1253
1250
  } else {
1254
1251
  this.$emit('change', inputValue, function (_ref3) {
1255
1252
  var isOpen = _ref3.isOpen;
@@ -1269,7 +1266,7 @@ var SearchBox = vue.defineComponent({
1269
1266
  // Record analytics for selected suggestions
1270
1267
  this.triggerClickAnalytics(suggestion._click_id);
1271
1268
  if (value === undefined) {
1272
- this.setValue(suggestion.value, true, this.$props, configureStore.causes.SUGGESTION_SELECT, false, suggestion._category);
1269
+ this.setValue(suggestion.value, true, this.$props, reactivecore.causes.SUGGESTION_SELECT, false, suggestion._category);
1273
1270
  } else {
1274
1271
  var emitValue = suggestion.value;
1275
1272
  if (this.$options.isTagsMode) {
@@ -1281,7 +1278,7 @@ var SearchBox = vue.defineComponent({
1281
1278
  }
1282
1279
  emitValue.push(suggestion.value);
1283
1280
  }
1284
- this.setValue(emitValue, true, this.$props, configureStore.causes.SUGGESTION_SELECT, false, suggestion._category);
1281
+ this.setValue(emitValue, true, this.$props, reactivecore.causes.SUGGESTION_SELECT, false, suggestion._category);
1285
1282
  this.$emit('change', emitValue, function (_ref4) {
1286
1283
  var isOpen = _ref4.isOpen;
1287
1284
  return _this3.triggerQuery(_rollupPluginBabelHelpers._extends({
@@ -1292,7 +1289,7 @@ var SearchBox = vue.defineComponent({
1292
1289
  }));
1293
1290
  });
1294
1291
  }
1295
- this.onValueSelectedHandler(suggestion.value, configureStore.causes.SUGGESTION_SELECT, suggestion.source);
1292
+ this.onValueSelectedHandler(suggestion.value, reactivecore.causes.SUGGESTION_SELECT, suggestion.source);
1296
1293
  },
1297
1294
  onValueSelectedHandler: function onValueSelectedHandler(currentValue) {
1298
1295
  if (currentValue === void 0) {
@@ -1371,12 +1368,12 @@ var SearchBox = vue.defineComponent({
1371
1368
  renderInputAddonBefore: function renderInputAddonBefore() {
1372
1369
  var addonBefore = this.$slots.addonBefore;
1373
1370
  if (addonBefore) {
1374
- var _slot;
1371
+ var _slot2;
1375
1372
  return vue.createVNode(InputAddon, {
1376
1373
  "class": "addon-before"
1377
- }, _isSlot(_slot = addonBefore()) ? _slot : {
1374
+ }, _isSlot(_slot2 = addonBefore()) ? _slot2 : {
1378
1375
  "default": function _default() {
1379
- return [_slot];
1376
+ return [_slot2];
1380
1377
  }
1381
1378
  });
1382
1379
  }
@@ -1385,12 +1382,12 @@ var SearchBox = vue.defineComponent({
1385
1382
  renderInputAddonAfter: function renderInputAddonAfter() {
1386
1383
  var addonAfter = this.$slots.addonAfter;
1387
1384
  if (addonAfter) {
1388
- var _slot2;
1385
+ var _slot4;
1389
1386
  return vue.createVNode(InputAddon, {
1390
1387
  "class": "addon-after"
1391
- }, _isSlot(_slot2 = addonAfter()) ? _slot2 : {
1388
+ }, _isSlot(_slot4 = addonAfter()) ? _slot4 : {
1392
1389
  "default": function _default() {
1393
- return [_slot2];
1390
+ return [_slot4];
1394
1391
  }
1395
1392
  });
1396
1393
  }
@@ -1432,7 +1429,7 @@ var SearchBox = vue.defineComponent({
1432
1429
  },
1433
1430
  renderIcons: function renderIcons() {
1434
1431
  var _this6 = this;
1435
- var _slot3, _slot4, _slot5;
1432
+ var _slot5, _slot6, _slot7;
1436
1433
  var _this$$props3 = this.$props,
1437
1434
  iconPosition = _this$$props3.iconPosition,
1438
1435
  showClear = _this$$props3.showClear,
@@ -1451,9 +1448,9 @@ var SearchBox = vue.defineComponent({
1451
1448
  "onClick": _this6.clearValue,
1452
1449
  "showIcon": showIcon,
1453
1450
  "isClearIcon": true
1454
- }, _isSlot(_slot3 = _this6.renderCancelIcon()) ? _slot3 : {
1451
+ }, _isSlot(_slot5 = _this6.renderCancelIcon()) ? _slot5 : {
1455
1452
  "default": function _default() {
1456
- return [_slot3];
1453
+ return [_slot5];
1457
1454
  }
1458
1455
  }), showVoiceSearch && vue.createVNode(Mic, {
1459
1456
  "getInstance": getMicInstance,
@@ -1462,9 +1459,9 @@ var SearchBox = vue.defineComponent({
1462
1459
  "className": getClassName$1(innerClass, 'mic') || null
1463
1460
  }, null), iconPosition === 'right' && showIcon && vue.createVNode(DropDown.IconWrapper, {
1464
1461
  "onClick": _this6.handleSearchIconClick
1465
- }, _isSlot(_slot4 = _this6.renderIcon()) ? _slot4 : {
1462
+ }, _isSlot(_slot6 = _this6.renderIcon()) ? _slot6 : {
1466
1463
  "default": function _default() {
1467
- return [_slot4];
1464
+ return [_slot6];
1468
1465
  }
1469
1466
  })];
1470
1467
  }
@@ -1475,9 +1472,9 @@ var SearchBox = vue.defineComponent({
1475
1472
  "default": function _default() {
1476
1473
  return [iconPosition === 'left' && showIcon && vue.createVNode(DropDown.IconWrapper, {
1477
1474
  "onClick": _this6.handleSearchIconClick
1478
- }, _isSlot(_slot5 = _this6.renderIcon()) ? _slot5 : {
1475
+ }, _isSlot(_slot7 = _this6.renderIcon()) ? _slot7 : {
1479
1476
  "default": function _default() {
1480
- return [_slot5];
1477
+ return [_slot7];
1481
1478
  }
1482
1479
  })];
1483
1480
  }
@@ -1562,7 +1559,7 @@ var SearchBox = vue.defineComponent({
1562
1559
  },
1563
1560
  clearAllTags: function clearAllTags() {
1564
1561
  this.selectedTags = [];
1565
- this.setValue('', true, this.$props, configureStore.causes.SUGGESTION_SELECT);
1562
+ this.setValue('', true, this.$props, reactivecore.causes.SUGGESTION_SELECT);
1566
1563
  if (this.$props.value !== undefined) {
1567
1564
  this.$emit('change', this.selectedTags, this.triggerQuery);
1568
1565
  }
@@ -1571,7 +1568,7 @@ var SearchBox = vue.defineComponent({
1571
1568
  this.selectedTags = [].concat(this.selectedTags.filter(function (tag) {
1572
1569
  return tag !== tagValue;
1573
1570
  }));
1574
- this.setValue('', true, this.$props, configureStore.causes.SUGGESTION_SELECT);
1571
+ this.setValue('', true, this.$props, reactivecore.causes.SUGGESTION_SELECT);
1575
1572
  if (this.$props.value !== undefined) {
1576
1573
  this.$emit('change', this.selectedTags, this.triggerQuery);
1577
1574
  }
@@ -1787,6 +1784,9 @@ var SearchBox = vue.defineComponent({
1787
1784
  document.removeEventListener('keydown', this.onKeyDown);
1788
1785
  }
1789
1786
  });
1787
+ SearchBox.hasInternalComponent = function () {
1788
+ return true;
1789
+ };
1790
1790
  SearchBox.defaultQuery = function (value, props) {
1791
1791
  var finalQuery = null;
1792
1792
  finalQuery = {
@@ -1845,6 +1845,9 @@ var SBConnected = PreferencesConsumer.PreferencesConsumer(ComponentWrapper.Compo
1845
1845
  internalComponent: true
1846
1846
  }));
1847
1847
  SBConnected.name = SearchBox.name;
1848
+ SBConnected.defaultQuery = SearchBox.defaultQuery;
1849
+ SBConnected.shouldQuery = SearchBox.shouldQuery;
1850
+ SBConnected.hasInternalComponent = SearchBox.hasInternalComponent;
1848
1851
  SBConnected.install = function (Vue) {
1849
1852
  Vue.component(SBConnected.name, SBConnected);
1850
1853
  };
@@ -1852,16 +1855,16 @@ SBConnected.install = function (Vue) {
1852
1855
  SBConnected.componentType = constants.componentTypes.searchBox;
1853
1856
 
1854
1857
  var _excluded = ["options"];
1855
- var updateQuery$1 = configureStore.Actions.updateQuery,
1856
- setQueryOptions = configureStore.Actions.setQueryOptions,
1857
- setCustomQuery$1 = configureStore.Actions.setCustomQuery,
1858
- setDefaultQuery$1 = configureStore.Actions.setDefaultQuery;
1859
- var parseHits = configureStore.helper.parseHits,
1860
- isEqual$1 = configureStore.helper.isEqual,
1861
- getCompositeAggsQuery$1 = configureStore.helper.getCompositeAggsQuery,
1862
- getResultStats$1 = configureStore.helper.getResultStats,
1863
- extractQueryFromCustomQuery = configureStore.helper.extractQueryFromCustomQuery,
1864
- getOptionsForCustomQuery = configureStore.helper.getOptionsForCustomQuery;
1858
+ var updateQuery$1 = reactivecore.Actions.updateQuery,
1859
+ setQueryOptions = reactivecore.Actions.setQueryOptions,
1860
+ setCustomQuery$1 = reactivecore.Actions.setCustomQuery,
1861
+ setDefaultQuery$1 = reactivecore.Actions.setDefaultQuery;
1862
+ var parseHits = reactivecore.helper.parseHits,
1863
+ isEqual$1 = reactivecore.helper.isEqual,
1864
+ getCompositeAggsQuery$1 = reactivecore.helper.getCompositeAggsQuery,
1865
+ getResultStats$1 = reactivecore.helper.getResultStats,
1866
+ extractQueryFromCustomQuery = reactivecore.helper.extractQueryFromCustomQuery,
1867
+ getOptionsForCustomQuery = reactivecore.helper.getOptionsForCustomQuery;
1865
1868
  var ReactiveComponent = {
1866
1869
  name: 'ReactiveComponent',
1867
1870
  props: {
@@ -2173,12 +2176,12 @@ var RcConnected = PreferencesConsumer.PreferencesConsumer({
2173
2176
  }
2174
2177
  });
2175
2178
  RcConnected.name = ReactiveComponent.name;
2179
+ RcConnected.hasInternalComponent = ReactiveComponent.hasInternalComponent;
2180
+ // Add componentType for SSR
2181
+ RcConnected.componentType = constants.componentTypes.reactiveComponent;
2176
2182
  RcConnected.install = function (Vue) {
2177
2183
  Vue.component(RcConnected.name, RcConnected);
2178
2184
  };
2179
2185
 
2180
- // Add componentType for SSR
2181
- RcConnected.componentType = constants.componentTypes.reactiveComponent;
2182
-
2183
2186
  exports.ReactiveComponent = RcConnected;
2184
2187
  exports.SearchBox = SBConnected;
@@ -14,27 +14,27 @@ require('emotion');
14
14
  require('polished');
15
15
  require('./Button-ad042719.js');
16
16
  require('./vueTypes-1bf00978.js');
17
- require('./Pagination-b5ddc906.js');
17
+ require('./Pagination-4ffc67cd.js');
18
18
  require('./ReactiveList.js');
19
19
  require('@appbaseio/reactivecore/lib/utils/transform');
20
20
  require('redux');
21
- require('./index-d8d8f291.js');
22
- require('./ComponentWrapper-611cf7f9.js');
23
- require('./PreferencesConsumer-22d1b49f.js');
21
+ require('./index-1481798c.js');
22
+ require('./ComponentWrapper-2dc930e1.js');
23
+ require('./PreferencesConsumer-2c69ac61.js');
24
24
  require('./Title-8802a218.js');
25
25
  require('./ListItem-d57d648d.js');
26
26
  require('./Card-f5ab024a.js');
27
27
  require('./Flex-d5675ea6.js');
28
28
  require('hotkeys-js');
29
- var ReactiveComponent = require('./ReactiveComponent-0a6b819b.js');
30
- require('./DropDown-dc184468.js');
29
+ var ReactiveComponent = require('./ReactiveComponent-4435adfa.js');
30
+ require('./DropDown-7bd56543.js');
31
31
  require('./Input-088dfcb4.js');
32
32
  require('compute-scroll-into-view');
33
33
  require('./Container-29f049b2.js');
34
34
  require('vue-highlight-words');
35
35
  require('@appbaseio/reactivecore/lib/utils/suggestions');
36
36
  require('./FormControlList-fadd792f.js');
37
- require('./utils-83fd01e9.js');
37
+ require('./utils-36b1b880.js');
38
38
  require('./SingleList.js');
39
39
  require('./MultiList.js');
40
40
  require('./SingleDropdownList.js');