@appbaseio/reactivesearch-vue 2.0.0-alpha.3 → 3.0.0-alpha.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.
Files changed (108) hide show
  1. package/dist/@appbaseio/reactivesearch-vue.umd.js +17405 -25231
  2. package/dist/@appbaseio/reactivesearch-vue.umd.js.map +1 -1
  3. package/dist/@appbaseio/reactivesearch-vue.umd.min.js +6 -15
  4. package/dist/@appbaseio/reactivesearch-vue.umd.min.js.map +1 -1
  5. package/dist/cjs/Button-ad042719.js +59 -0
  6. package/dist/cjs/Card-f5ab024a.js +27 -0
  7. package/dist/cjs/{ComponentWrapper-ad3dad02.js → ComponentWrapper-75f88599.js} +42 -56
  8. package/dist/cjs/Container-29f049b2.js +12 -0
  9. package/dist/cjs/DropDown-6cf84c47.js +698 -0
  10. package/dist/cjs/DynamicRangeSlider.js +103 -155
  11. package/dist/cjs/Flex-d5675ea6.js +48 -0
  12. package/dist/cjs/FormControlList-fadd792f.js +42 -0
  13. package/dist/cjs/Input-4b434436.js +74 -0
  14. package/dist/cjs/ListItem-d57d648d.js +42 -0
  15. package/dist/cjs/MultiDropdownList.js +124 -240
  16. package/dist/cjs/MultiList.js +123 -261
  17. package/dist/cjs/MultiRange.js +87 -133
  18. package/dist/cjs/{Pagination-71e85fa9.js → Pagination-b5ddc906.js} +70 -83
  19. package/dist/cjs/PreferencesConsumer-eb265924.js +75 -0
  20. package/dist/cjs/RangeInput.js +163 -171
  21. package/dist/cjs/RangeSlider.js +81 -109
  22. package/dist/cjs/ReactiveBase.js +139 -157
  23. package/dist/cjs/ReactiveComponent-eb8db4c1.js +2189 -0
  24. package/dist/cjs/ReactiveComponent.js +46 -340
  25. package/dist/cjs/ReactiveGoogleMap.js +445 -655
  26. package/dist/cjs/ReactiveList.js +179 -304
  27. package/dist/cjs/ResultCard.js +36 -36
  28. package/dist/cjs/ResultList.js +48 -56
  29. package/dist/cjs/SelectedFilters.js +62 -69
  30. package/dist/cjs/SingleDropdownList.js +117 -177
  31. package/dist/cjs/SingleList.js +121 -205
  32. package/dist/cjs/SingleRange.js +78 -105
  33. package/dist/cjs/StateProvider.js +74 -47
  34. package/dist/cjs/Title-8802a218.js +12 -0
  35. package/dist/cjs/ToggleButton.js +72 -119
  36. package/dist/cjs/{_rollupPluginBabelHelpers-c705cbe6.js → _rollupPluginBabelHelpers-f8b843f8.js} +0 -15
  37. package/dist/cjs/{index-6a167fe0.js → index-d8d8f291.js} +38 -108
  38. package/dist/cjs/index.js +44 -41
  39. package/dist/cjs/initReactivesearch.js +69 -152
  40. package/dist/cjs/install.js +47 -43
  41. package/dist/cjs/ssr-6907ada3.js +66 -0
  42. package/dist/cjs/{utils-d6a52588.js → utils-83fd01e9.js} +7 -16
  43. package/dist/cjs/version.js +1 -1
  44. package/dist/cjs/{vueTypes-727b7c63.js → vueTypes-1bf00978.js} +8 -19
  45. package/dist/es/Button-474510e3.js +53 -0
  46. package/dist/es/{Card-450683f1.js → Card-38cbe652.js} +3 -3
  47. package/dist/es/{ComponentWrapper-424e86fd.js → ComponentWrapper-5166c76a.js} +42 -56
  48. package/dist/es/{Container-ba826e96.js → Container-d00219f7.js} +2 -2
  49. package/dist/es/DropDown-8764360c.js +688 -0
  50. package/dist/es/DynamicRangeSlider.js +103 -155
  51. package/dist/es/Flex-a08e22d7.js +46 -0
  52. package/dist/es/FormControlList-fe6eaee4.js +38 -0
  53. package/dist/es/Input-4a8ef1f3.js +69 -0
  54. package/dist/es/{ListItem-cad14c5e.js → ListItem-16756c02.js} +7 -8
  55. package/dist/es/MultiDropdownList.js +124 -240
  56. package/dist/es/MultiList.js +123 -261
  57. package/dist/es/MultiRange.js +87 -133
  58. package/dist/es/{Pagination-784bf143.js → Pagination-72bd1d9e.js} +70 -83
  59. package/dist/es/PreferencesConsumer-c276709c.js +73 -0
  60. package/dist/es/RangeInput.js +163 -170
  61. package/dist/es/RangeSlider.js +81 -109
  62. package/dist/es/ReactiveBase.js +138 -155
  63. package/dist/es/ReactiveComponent-f9fa5780.js +2183 -0
  64. package/dist/es/ReactiveComponent.js +42 -337
  65. package/dist/es/ReactiveGoogleMap.js +440 -649
  66. package/dist/es/ReactiveList.js +177 -301
  67. package/dist/es/ResultCard.js +36 -36
  68. package/dist/es/ResultList.js +48 -56
  69. package/dist/es/SelectedFilters.js +62 -69
  70. package/dist/es/SingleDropdownList.js +117 -177
  71. package/dist/es/SingleList.js +121 -205
  72. package/dist/es/SingleRange.js +78 -105
  73. package/dist/es/StateProvider.js +75 -48
  74. package/dist/es/{Title-3342664a.js → Title-863dfa42.js} +2 -2
  75. package/dist/es/ToggleButton.js +72 -119
  76. package/dist/es/{_rollupPluginBabelHelpers-76660dab.js → _rollupPluginBabelHelpers-ded08042.js} +0 -15
  77. package/dist/es/{index-7788a843.js → index-4520a598.js} +39 -107
  78. package/dist/es/index.js +30 -32
  79. package/dist/es/initReactivesearch.js +69 -152
  80. package/dist/es/install.js +49 -41
  81. package/dist/es/{ssr-b2c0b401.js → ssr-af398f0c.js} +36 -7
  82. package/dist/es/{utils-9e68acee.js → utils-9e5a16a1.js} +7 -16
  83. package/dist/es/version.js +1 -1
  84. package/dist/es/{vueTypes-b8146772.js → vueTypes-f1923c72.js} +8 -19
  85. package/package.json +10 -9
  86. package/dist/cjs/Button-446f819e.js +0 -68
  87. package/dist/cjs/CancelSvg-9f258f4f.js +0 -449
  88. package/dist/cjs/Card-642547a8.js +0 -30
  89. package/dist/cjs/Container-daf30918.js +0 -15
  90. package/dist/cjs/DataSearch-6cf29cf0.js +0 -2323
  91. package/dist/cjs/DataSearch.js +0 -30
  92. package/dist/cjs/DropDown-c479bbb0.js +0 -328
  93. package/dist/cjs/Flex-aa517a13.js +0 -52
  94. package/dist/cjs/FormControlList-c195a592.js +0 -47
  95. package/dist/cjs/Input-e6603a7e.js +0 -79
  96. package/dist/cjs/ListItem-8c9e0d68.js +0 -46
  97. package/dist/cjs/Title-1de7d0f4.js +0 -15
  98. package/dist/cjs/install-42ba1d44.js +0 -1409
  99. package/dist/cjs/ssr-3027b848.js +0 -39
  100. package/dist/es/Button-d8bc15ea.js +0 -59
  101. package/dist/es/CancelSvg-4cfae5fd.js +0 -440
  102. package/dist/es/DataSearch-4888aa43.js +0 -2308
  103. package/dist/es/DataSearch.js +0 -22
  104. package/dist/es/DropDown-05a644a5.js +0 -322
  105. package/dist/es/Flex-1f0795c3.js +0 -47
  106. package/dist/es/FormControlList-c22d64f6.js +0 -40
  107. package/dist/es/Input-7a2a9fac.js +0 -71
  108. package/dist/es/install-80bc2764.js +0 -1402
@@ -4,25 +4,31 @@ 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 _rollupPluginBabelHelpers = require('./_rollupPluginBabelHelpers-c705cbe6.js');
7
+ var _rollupPluginBabelHelpers = require('./_rollupPluginBabelHelpers-f8b843f8.js');
8
+ var vue = require('vue');
8
9
  var VueTypes = _interopDefault(require('vue-types'));
9
- require('emotion');
10
10
  require('@appbaseio/vue-emotion');
11
+ require('emotion');
11
12
  require('polished');
12
- var vueTypes = require('./vueTypes-727b7c63.js');
13
- var _mergeJSXProps = _interopDefault(require('@vue/babel-helper-vue-jsx-merge-props'));
14
- var Title = require('./Title-1de7d0f4.js');
15
- var Card = require('./Card-642547a8.js');
13
+ var vueTypes = require('./vueTypes-1bf00978.js');
14
+ var Title = require('./Title-8802a218.js');
15
+ var Card = require('./Card-f5ab024a.js');
16
16
 
17
+ function _isSlot(s) {
18
+ return typeof s === 'function' || Object.prototype.toString.call(s) === '[object Object]' && !vue.isVNode(s);
19
+ }
17
20
  var ResultCardTitle = {
18
21
  name: 'ResultCardTitle',
19
22
  render: function render() {
20
- var h = arguments[0];
23
+ var _slot;
21
24
  var children = this.$slots["default"];
22
- return h(Title.Title, _mergeJSXProps([{}, this.$props]), [children]);
25
+ return vue.createVNode(Title.Title, this.$props, _isSlot(_slot = children()) ? _slot : {
26
+ "default": function _default() {
27
+ return [_slot];
28
+ }
29
+ });
23
30
  }
24
31
  };
25
-
26
32
  ResultCardTitle.install = function (Vue) {
27
33
  Vue.component(ResultCardTitle.name, ResultCardTitle);
28
34
  };
@@ -34,20 +40,16 @@ var ResultCardImage = {
34
40
  src: VueTypes.string.isRequired
35
41
  },
36
42
  render: function render() {
37
- var h = arguments[0];
38
-
39
43
  var _this$$props = this.$props,
40
- src = _this$$props.src,
41
- props = _rollupPluginBabelHelpers._objectWithoutPropertiesLoose(_this$$props, _excluded);
42
-
43
- return h(Card.Image, _mergeJSXProps([{
44
+ src = _this$$props.src,
45
+ props = _rollupPluginBabelHelpers._objectWithoutPropertiesLoose(_this$$props, _excluded);
46
+ return vue.createVNode(Card.Image, vue.mergeProps({
44
47
  "style": {
45
48
  backgroundImage: "url(" + src + ")"
46
49
  }
47
- }, props]));
50
+ }, props), null);
48
51
  }
49
52
  };
50
-
51
53
  ResultCardImage.install = function (Vue) {
52
54
  Vue.component(ResultCardImage.name, ResultCardImage);
53
55
  };
@@ -55,19 +57,18 @@ ResultCardImage.install = function (Vue) {
55
57
  var ResultCardDescription = {
56
58
  name: 'ResultCardDescription',
57
59
  functional: true,
58
- render: function render(_, _ref) {
59
- var props = _ref.props,
60
- children = _ref.children;
61
- var h = arguments[0];
62
- return h("article", _mergeJSXProps([{}, props]), [children]);
60
+ render: function render(context) {
61
+ return vue.createVNode("article", context.$props, [context.$slots["default"]()]);
63
62
  }
64
63
  };
65
-
66
64
  ResultCardDescription.install = function (Vue) {
67
65
  Vue.component(ResultCardDescription.name, ResultCardDescription);
68
66
  };
69
67
 
70
68
  var _excluded$1 = ["href", "target"];
69
+ function _isSlot$1(s) {
70
+ return typeof s === 'function' || Object.prototype.toString.call(s) === '[object Object]' && !vue.isVNode(s);
71
+ }
71
72
  var ResultCard = {
72
73
  name: 'ResultCard',
73
74
  components: {
@@ -80,24 +81,23 @@ var ResultCard = {
80
81
  href: vueTypes.types.string
81
82
  },
82
83
  render: function render() {
83
- var h = arguments[0];
84
+ var _slot;
84
85
  var children = this.$slots["default"];
85
-
86
86
  var _this$$props = this.$props,
87
- href = _this$$props.href,
88
- target = _this$$props.target,
89
- rest = _rollupPluginBabelHelpers._objectWithoutPropertiesLoose(_this$$props, _excluded$1);
90
-
91
- return h(Card.Card, _mergeJSXProps([{
92
- "attrs": {
93
- "href": href,
94
- "target": target,
95
- "rel": target === '_blank' ? 'noopener noreferrer' : null
87
+ href = _this$$props.href,
88
+ target = _this$$props.target,
89
+ rest = _rollupPluginBabelHelpers._objectWithoutPropertiesLoose(_this$$props, _excluded$1);
90
+ return vue.createVNode(Card.Card, vue.mergeProps({
91
+ "href": href,
92
+ "target": target,
93
+ "rel": target === '_blank' ? 'noopener noreferrer' : null
94
+ }, rest), _isSlot$1(_slot = children()) ? _slot : {
95
+ "default": function _default() {
96
+ return [_slot];
96
97
  }
97
- }, rest]), [children]);
98
+ });
98
99
  }
99
100
  };
100
-
101
101
  ResultCard.install = function (Vue) {
102
102
  Vue.component(ResultCard.name, ResultCard);
103
103
  Vue.component(ResultCardTitle.name, ResultCardTitle);
@@ -4,27 +4,23 @@ 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 _rollupPluginBabelHelpers = require('./_rollupPluginBabelHelpers-c705cbe6.js');
7
+ var _rollupPluginBabelHelpers = require('./_rollupPluginBabelHelpers-f8b843f8.js');
8
+ var vue = require('vue');
8
9
  var VueTypes = _interopDefault(require('vue-types'));
9
- require('emotion');
10
10
  require('@appbaseio/vue-emotion');
11
+ require('emotion');
11
12
  require('polished');
12
- var vueTypes = require('./vueTypes-727b7c63.js');
13
- var _mergeJSXProps = _interopDefault(require('@vue/babel-helper-vue-jsx-merge-props'));
14
- var Title = require('./Title-1de7d0f4.js');
15
- var ListItem = require('./ListItem-8c9e0d68.js');
13
+ var vueTypes = require('./vueTypes-1bf00978.js');
14
+ var Title = require('./Title-8802a218.js');
15
+ var ListItem = require('./ListItem-d57d648d.js');
16
16
 
17
17
  var ResultListContent = {
18
18
  name: 'ResultListContent',
19
19
  functional: true,
20
- render: function render(_, _ref) {
21
- var props = _ref.props,
22
- children = _ref.children;
23
- var h = arguments[0];
24
- return h("article", _mergeJSXProps([{}, props]), [children]);
20
+ render: function render(context) {
21
+ return vue.createVNode("article", context.$props, [context.$slots["default"]()]);
25
22
  }
26
23
  };
27
-
28
24
  ResultListContent.install = function (Vue) {
29
25
  Vue.component(ResultListContent.name, ResultListContent);
30
26
  };
@@ -32,14 +28,10 @@ ResultListContent.install = function (Vue) {
32
28
  var ResultListDescription = {
33
29
  name: 'ResultListDescription',
34
30
  functional: true,
35
- render: function render(_, _ref) {
36
- var props = _ref.props,
37
- children = _ref.children;
38
- var h = arguments[0];
39
- return h("div", _mergeJSXProps([{}, props]), [children]);
31
+ render: function render(context) {
32
+ return vue.createVNode("div", context.$props, [context.$slots["default"]()]);
40
33
  }
41
34
  };
42
-
43
35
  ResultListDescription.install = function (Vue) {
44
36
  Vue.component(ResultListDescription.name, ResultListDescription);
45
37
  };
@@ -52,40 +44,43 @@ var ResultListImage = {
52
44
  small: VueTypes.bool.def(false)
53
45
  },
54
46
  render: function render() {
55
- var h = arguments[0];
56
-
57
47
  var _this$$props = this.$props,
58
- src = _this$$props.src,
59
- small = _this$$props.small,
60
- props = _rollupPluginBabelHelpers._objectWithoutPropertiesLoose(_this$$props, _excluded);
61
-
62
- return h(ListItem.Image, _mergeJSXProps([{
63
- "attrs": {
64
- "src": src,
65
- "small": small
66
- }
67
- }, props]));
48
+ src = _this$$props.src,
49
+ small = _this$$props.small,
50
+ props = _rollupPluginBabelHelpers._objectWithoutPropertiesLoose(_this$$props, _excluded);
51
+ return vue.createVNode(ListItem.Image, vue.mergeProps({
52
+ "src": src,
53
+ "small": small
54
+ }, props), null);
68
55
  }
69
56
  };
70
-
71
57
  ResultListImage.install = function (Vue) {
72
58
  Vue.component(ResultListImage.name, ResultListImage);
73
59
  };
74
60
 
61
+ function _isSlot(s) {
62
+ return typeof s === 'function' || Object.prototype.toString.call(s) === '[object Object]' && !vue.isVNode(s);
63
+ }
75
64
  var ResultListTitle = {
76
65
  name: 'ResultListTitle',
77
66
  render: function render() {
78
- var h = arguments[0];
67
+ var _slot;
79
68
  var children = this.$slots["default"];
80
- return h(Title.Title, _mergeJSXProps([{}, this.$props]), [children]);
69
+ return vue.createVNode(Title.Title, this.$props, _isSlot(_slot = children()) ? _slot : {
70
+ "default": function _default() {
71
+ return [_slot];
72
+ }
73
+ });
81
74
  }
82
75
  };
83
-
84
76
  ResultListTitle.install = function (Vue) {
85
77
  Vue.component(ResultListTitle.name, ResultListTitle);
86
78
  };
87
79
 
88
80
  var _excluded$1 = ["href", "target"];
81
+ function _isSlot$1(s) {
82
+ return typeof s === 'function' || Object.prototype.toString.call(s) === '[object Object]' && !vue.isVNode(s);
83
+ }
89
84
  var ResultList = {
90
85
  name: 'ResultList',
91
86
  props: {
@@ -106,42 +101,39 @@ var ResultList = {
106
101
  return this.__state;
107
102
  },
108
103
  mounted: function mounted() {
109
- var children = this.$slots["default"];
104
+ var children = this.$slots["default"]();
110
105
  var ImageChild = children.find(function (o) {
111
- return o.componentOptions && o.componentOptions.tag === ResultListImage.name;
106
+ return o.type && o.type.name === ResultListImage.name;
112
107
  });
113
-
114
- if (ImageChild && ImageChild.componentOptions && ImageChild.componentOptions.propsData) {
108
+ if (ImageChild && ImageChild.props) {
115
109
  this.hasImage = true;
116
-
117
- if (ImageChild.componentOptions.propsData.small) {
110
+ if (ImageChild.props.small) {
118
111
  this.isSmall = true;
119
112
  }
120
113
  }
121
114
  },
122
115
  render: function render() {
123
- var h = arguments[0];
124
-
116
+ var _slot;
125
117
  var _this$$props = this.$props,
126
- href = _this$$props.href,
127
- target = _this$$props.target,
128
- props = _rollupPluginBabelHelpers._objectWithoutPropertiesLoose(_this$$props, _excluded$1);
129
-
118
+ href = _this$$props.href,
119
+ target = _this$$props.target,
120
+ props = _rollupPluginBabelHelpers._objectWithoutPropertiesLoose(_this$$props, _excluded$1);
130
121
  var hasImage = this.hasImage,
131
- isSmall = this.isSmall;
122
+ isSmall = this.isSmall;
132
123
  var children = this.$slots["default"];
133
- return h(ListItem.ListItem, _mergeJSXProps([{
134
- "attrs": {
135
- "href": href,
136
- "image": hasImage,
137
- "small": isSmall,
138
- "target": target,
139
- "rel": target === '_blank' ? 'noopener noreferrer' : null
124
+ return vue.createVNode(ListItem.ListItem, vue.mergeProps({
125
+ "href": href,
126
+ "image": hasImage,
127
+ "small": isSmall,
128
+ "target": target,
129
+ "rel": target === '_blank' ? 'noopener noreferrer' : null
130
+ }, props), _isSlot$1(_slot = children()) ? _slot : {
131
+ "default": function _default() {
132
+ return [_slot];
140
133
  }
141
- }, props]), [children]);
134
+ });
142
135
  }
143
136
  };
144
-
145
137
  ResultList.install = function (Vue) {
146
138
  Vue.component(ResultList.name, ResultList);
147
139
  Vue.component(ResultListContent.name, ResultListContent);
@@ -6,24 +6,26 @@ function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'defau
6
6
 
7
7
  var configureStore = require('@appbaseio/reactivecore');
8
8
  var configureStore__default = _interopDefault(configureStore);
9
- var _rollupPluginBabelHelpers = require('./_rollupPluginBabelHelpers-c705cbe6.js');
10
- var VueTypes = _interopDefault(require('vue-types'));
11
9
  require('@appbaseio/reactivecore/lib/utils/constants');
12
- require('emotion');
10
+ var _transformOn = _interopDefault(require('@vue/babel-helper-vue-transform-on'));
11
+ require('./_rollupPluginBabelHelpers-f8b843f8.js');
12
+ var vue = require('vue');
13
+ var VueTypes = _interopDefault(require('vue-types'));
13
14
  require('@appbaseio/vue-emotion');
15
+ require('emotion');
14
16
  require('polished');
15
- var Button = require('./Button-446f819e.js');
16
- var vueTypes = require('./vueTypes-727b7c63.js');
17
+ var Button = require('./Button-ad042719.js');
18
+ var vueTypes = require('./vueTypes-1bf00978.js');
17
19
  require('redux');
18
- var index = require('./index-6a167fe0.js');
19
- var Title = require('./Title-1de7d0f4.js');
20
- var Container = require('./Container-daf30918.js');
20
+ var index = require('./index-d8d8f291.js');
21
+ var Title = require('./Title-8802a218.js');
22
+ var Container = require('./Container-29f049b2.js');
21
23
 
22
24
  var setValue = configureStore.Actions.setValue,
23
- clearValues = configureStore.Actions.clearValues,
24
- resetValuesToDefault = configureStore.Actions.resetValuesToDefault;
25
+ clearValues = configureStore.Actions.clearValues,
26
+ resetValuesToDefault = configureStore.Actions.resetValuesToDefault;
25
27
  var getClassName = configureStore.helper.getClassName,
26
- handleA11yAction = configureStore.helper.handleA11yAction;
28
+ handleA11yAction = configureStore.helper.handleA11yAction;
27
29
  var SelectedFilters = {
28
30
  name: 'SelectedFilters',
29
31
  props: {
@@ -43,11 +45,8 @@ var SelectedFilters = {
43
45
  },
44
46
  render: function render() {
45
47
  var _this = this;
46
-
47
- var h = arguments[0];
48
-
49
- if (this.$scopedSlots["default"]) {
50
- return this.$scopedSlots["default"]({
48
+ if (this.$slots["default"]) {
49
+ return this.$slots["default"]({
51
50
  components: this.components,
52
51
  selectedValues: this.selectedValues,
53
52
  clearValues: this.clearValues,
@@ -56,54 +55,58 @@ var SelectedFilters = {
56
55
  resetValuesToDefault: this.resetValuesToDefault
57
56
  });
58
57
  }
59
-
60
58
  var filtersToRender = this.renderFilters();
61
59
  var hasValues = !!filtersToRender.length;
62
- return h(Container.Container, {
60
+ return vue.createVNode(Container.Container, {
63
61
  "class": Button.filters(this.theme) + " " + (this.$props.className || '')
64
- }, [this.$props.title && hasValues && h(Title.Title, {
65
- "class": getClassName(this.$props.innerClass, 'title') || ''
66
- }, [this.$props.title]), filtersToRender, this.$props.showClearAll && hasValues && filtersToRender.length > 1 ? h(Button.Button, {
67
- "class": getClassName(this.$props.innerClass, 'button') || '',
68
- "on": _rollupPluginBabelHelpers._extends({}, {
69
- click: this.clearValues,
70
- keypress: function keypress(event) {
71
- return handleA11yAction(event, function () {
72
- return _this.clearValues();
73
- });
74
- }
75
- }),
76
- "attrs": {
77
- "tabIndex": "0"
62
+ }, {
63
+ "default": function _default() {
64
+ return [_this.$props.title && hasValues && vue.createVNode(Title.Title, {
65
+ "class": getClassName(_this.$props.innerClass, 'title') || ''
66
+ }, {
67
+ "default": function _default() {
68
+ return [_this.$props.title];
69
+ }
70
+ }), filtersToRender, _this.$props.showClearAll && hasValues && filtersToRender.length > 1 ? vue.createVNode(Button.Button, vue.mergeProps(_transformOn({
71
+ click: _this.clearValues,
72
+ keypress: function keypress(event) {
73
+ return handleA11yAction(event, function () {
74
+ return _this.clearValues();
75
+ });
76
+ }
77
+ }), {
78
+ "class": getClassName(_this.$props.innerClass, 'button') || '',
79
+ "tabIndex": "0"
80
+ }), {
81
+ "default": function _default() {
82
+ return [_this.$props.clearAllLabel];
83
+ }
84
+ }) : null];
78
85
  }
79
- }, [this.$props.clearAllLabel]) : null]);
86
+ });
80
87
  },
81
88
  methods: {
82
89
  remove: function remove(component, value) {
83
90
  if (value === void 0) {
84
91
  value = null;
85
92
  }
86
-
87
93
  this.setValue(component, null);
88
94
  this.$emit('clear', component, value);
89
95
  },
90
96
  clearValues: function clearValues() {
91
97
  var resetToDefault = this.resetToDefault,
92
- resetToValues = this.resetToValues,
93
- clearAllBlacklistComponents = this.clearAllBlacklistComponents;
94
-
98
+ resetToValues = this.resetToValues,
99
+ clearAllBlacklistComponents = this.clearAllBlacklistComponents;
95
100
  if (resetToDefault) {
96
101
  this.resetValuesToDefault(clearAllBlacklistComponents);
97
102
  } else {
98
103
  this.clearValuesAction(resetToValues, clearAllBlacklistComponents);
99
104
  }
100
-
101
105
  this.$emit('clear', resetToValues);
102
106
  },
103
107
  clearValue: function clearValue(componentId) {
104
108
  var resetToDefault = this.resetToDefault,
105
- resetToValues = this.resetToValues;
106
-
109
+ resetToValues = this.resetToValues;
107
110
  if (resetToDefault) {
108
111
  this.resetValuesToDefault(this.components.filter(function (component) {
109
112
  return component !== componentId;
@@ -111,69 +114,61 @@ var SelectedFilters = {
111
114
  } else {
112
115
  this.setValue(componentId, (resetToValues == null ? void 0 : resetToValues[componentId]) || null);
113
116
  }
114
-
115
117
  this.$emit('clear', resetToValues == null ? void 0 : resetToValues[componentId]);
116
118
  },
117
119
  renderValue: function renderValue(value, isArray) {
118
120
  var _this2 = this;
119
-
120
121
  if (isArray && value.length) {
121
122
  var arrayToRender = value.map(function (item) {
122
123
  return _this2.renderValue(item);
123
124
  });
124
125
  return arrayToRender.join(', ');
125
126
  }
126
-
127
127
  if (value && typeof value === 'object') {
128
128
  // TODO: support for NestedList
129
129
  var label = (typeof value.label === 'string' ? value.label : value.value) || value.key || value.distance || null;
130
-
131
130
  if (value.location) {
132
131
  label = value.location + " - " + label;
133
132
  }
134
-
135
133
  return label;
136
134
  }
137
-
138
135
  return value;
139
136
  },
140
137
  renderFilterButton: function renderFilterButton(component, keyProp, handleRemove, label) {
141
- var h = this.$createElement;
142
- return h(Button.Button, {
138
+ return vue.createVNode(Button.Button, vue.mergeProps(_transformOn({
139
+ click: handleRemove,
140
+ keypress: function keypress(event) {
141
+ return handleA11yAction(event, handleRemove);
142
+ }
143
+ }), {
143
144
  "class": getClassName(this.$props.innerClass, 'button') || '',
144
145
  "key": keyProp,
145
- "on": _rollupPluginBabelHelpers._extends({}, {
146
- click: handleRemove,
147
- keypress: function keypress(event) {
148
- return handleA11yAction(event, handleRemove);
149
- }
150
- }),
151
- "attrs": {
152
- "tabIndex": "0"
146
+ "tabIndex": "0"
147
+ }), {
148
+ "default": function _default() {
149
+ return [vue.createVNode("span", null, [label]), vue.createVNode("span", null, [vue.createTextVNode("\u2715")])];
153
150
  }
154
- }, [h("span", [label]), h("span", ["\u2715"])]);
151
+ });
155
152
  },
156
153
  renderFilters: function renderFilters() {
157
154
  var _this3 = this;
158
-
159
155
  var selectedValues = this.selectedValues;
160
156
  var filterComponents = Object.keys(selectedValues).filter(function (id) {
161
157
  return _this3.components.includes(id) && selectedValues[id].showFilter;
162
158
  });
163
159
  return filterComponents.map(function (component, index$1) {
164
160
  var _selectedValues$compo = selectedValues[component],
165
- label = _selectedValues$compo.label,
166
- value = _selectedValues$compo.value;
167
- var isArray = Array.isArray(value); // default behaviour
161
+ label = _selectedValues$compo.label,
162
+ value = _selectedValues$compo.value;
163
+ var isArray = Array.isArray(value);
168
164
 
165
+ // default behaviour
169
166
  if (label && (isArray && value.length || !isArray && value)) {
170
167
  var valueToRender = _this3.renderValue(value, isArray);
171
-
172
168
  return _this3.renderFilterButton(component, component + "-" + (index$1 + 1), function () {
173
169
  return _this3.remove(component, value);
174
170
  }, selectedValues[component].label + ": " + index.decodeHtml(valueToRender));
175
171
  }
176
-
177
172
  return null;
178
173
  }).filter(Boolean);
179
174
  }
@@ -184,23 +179,21 @@ var SelectedFilters = {
184
179
  }
185
180
  }
186
181
  };
187
-
188
182
  var mapStateToProps = function mapStateToProps(state) {
189
183
  return {
190
184
  components: state.components,
191
185
  selectedValues: state.selectedValues
192
186
  };
193
187
  };
194
-
195
188
  var mapDispatchtoProps = {
196
189
  clearValuesAction: clearValues,
197
190
  setValue: setValue,
198
191
  resetValuesToDefault: resetValuesToDefault
199
192
  };
200
193
  var RcConnected = index.connect(mapStateToProps, mapDispatchtoProps)(SelectedFilters);
201
-
202
- SelectedFilters.install = function (Vue) {
203
- Vue.component(SelectedFilters.name, RcConnected);
194
+ RcConnected.name = SelectedFilters.name;
195
+ RcConnected.install = function (Vue) {
196
+ Vue.component(RcConnected.name, RcConnected);
204
197
  };
205
198
 
206
- exports.default = SelectedFilters;
199
+ exports.default = RcConnected;