@equinor/fusion-react-filter 1.1.11 → 2.1.0-filter.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 (403) hide show
  1. package/README.md +4 -4
  2. package/components/package.json +6 -0
  3. package/dist/FilterProvider.d.ts +7 -28
  4. package/dist/FilterProvider.d.ts.map +1 -1
  5. package/dist/FilterProvider.js +24 -31
  6. package/dist/FilterProvider.js.map +1 -1
  7. package/dist/actions.d.ts +32 -0
  8. package/dist/actions.d.ts.map +1 -0
  9. package/dist/actions.js +20 -0
  10. package/dist/actions.js.map +1 -0
  11. package/dist/components/filter/FilterOptionHeader.d.ts +7 -0
  12. package/dist/components/filter/FilterOptionHeader.d.ts.map +1 -0
  13. package/dist/components/filter/FilterOptionHeader.js +69 -0
  14. package/dist/components/filter/FilterOptionHeader.js.map +1 -0
  15. package/dist/components/filter/checkbox/CheckboxFilter.d.ts +16 -0
  16. package/dist/components/filter/checkbox/CheckboxFilter.d.ts.map +1 -0
  17. package/dist/components/filter/checkbox/CheckboxFilter.js +16 -0
  18. package/dist/components/filter/checkbox/CheckboxFilter.js.map +1 -0
  19. package/dist/components/filter/checkbox/CheckboxFilter.style.d.ts +5 -0
  20. package/dist/components/filter/checkbox/CheckboxFilter.style.d.ts.map +1 -0
  21. package/dist/components/filter/checkbox/CheckboxFilter.style.js +19 -0
  22. package/dist/components/filter/checkbox/CheckboxFilter.style.js.map +1 -0
  23. package/dist/components/filter/checkbox/CheckboxFilterOption.d.ts +14 -0
  24. package/dist/components/filter/checkbox/CheckboxFilterOption.d.ts.map +1 -0
  25. package/dist/components/filter/checkbox/CheckboxFilterOption.js +19 -0
  26. package/dist/components/filter/checkbox/CheckboxFilterOption.js.map +1 -0
  27. package/dist/components/filter/checkbox/CheckboxFilterOption.style.d.ts +3 -0
  28. package/dist/components/filter/checkbox/CheckboxFilterOption.style.d.ts.map +1 -0
  29. package/dist/components/filter/checkbox/CheckboxFilterOption.style.js +40 -0
  30. package/dist/components/filter/checkbox/CheckboxFilterOption.style.js.map +1 -0
  31. package/dist/components/filter/checkbox/CheckboxFilterOptionAll.d.ts +3 -0
  32. package/dist/components/filter/checkbox/CheckboxFilterOptionAll.d.ts.map +1 -0
  33. package/dist/components/filter/checkbox/CheckboxFilterOptionAll.js +24 -0
  34. package/dist/components/filter/checkbox/CheckboxFilterOptionAll.js.map +1 -0
  35. package/dist/components/filter/checkbox/CheckboxFilterOptions.d.ts +3 -0
  36. package/dist/components/filter/checkbox/CheckboxFilterOptions.d.ts.map +1 -0
  37. package/dist/components/filter/checkbox/CheckboxFilterOptions.js +37 -0
  38. package/dist/components/filter/checkbox/CheckboxFilterOptions.js.map +1 -0
  39. package/dist/components/filter/checkbox/CheckboxFilterProvider.d.ts +13 -0
  40. package/dist/components/filter/checkbox/CheckboxFilterProvider.d.ts.map +1 -0
  41. package/dist/components/filter/checkbox/CheckboxFilterProvider.js +16 -0
  42. package/dist/components/filter/checkbox/CheckboxFilterProvider.js.map +1 -0
  43. package/dist/components/filter/checkbox/context.d.ts +4 -0
  44. package/dist/components/filter/checkbox/context.d.ts.map +1 -0
  45. package/dist/components/filter/checkbox/context.js +3 -0
  46. package/dist/components/filter/checkbox/context.js.map +1 -0
  47. package/dist/components/filter/checkbox/index.d.ts +2 -0
  48. package/dist/components/filter/checkbox/index.d.ts.map +1 -0
  49. package/dist/components/filter/checkbox/index.js +2 -0
  50. package/dist/components/filter/checkbox/index.js.map +1 -0
  51. package/dist/components/filter/checkbox/types.d.ts +7 -0
  52. package/dist/components/filter/checkbox/types.d.ts.map +1 -0
  53. package/dist/components/filter/checkbox/types.js +2 -0
  54. package/dist/components/filter/checkbox/types.js.map +1 -0
  55. package/dist/components/filter/index.d.ts +5 -0
  56. package/dist/components/filter/index.d.ts.map +1 -0
  57. package/dist/components/filter/index.js +5 -0
  58. package/dist/components/filter/index.js.map +1 -0
  59. package/dist/components/filter/search/SearchFilter.d.ts +17 -0
  60. package/dist/components/filter/search/SearchFilter.d.ts.map +1 -0
  61. package/dist/components/filter/search/SearchFilter.js +47 -0
  62. package/dist/components/filter/search/SearchFilter.js.map +1 -0
  63. package/dist/components/filter/search/index.d.ts +2 -0
  64. package/dist/components/filter/search/index.d.ts.map +1 -0
  65. package/dist/components/filter/search/index.js +2 -0
  66. package/dist/components/filter/search/index.js.map +1 -0
  67. package/dist/components/filter/types.d.ts +7 -0
  68. package/dist/components/filter/types.d.ts.map +1 -0
  69. package/dist/components/filter/types.js +2 -0
  70. package/dist/components/filter/types.js.map +1 -0
  71. package/dist/components/index.d.ts +4 -0
  72. package/dist/components/index.d.ts.map +1 -0
  73. package/dist/components/index.js +4 -0
  74. package/dist/components/index.js.map +1 -0
  75. package/dist/components/misc/ClearFilterButton.d.ts +10 -0
  76. package/dist/components/misc/ClearFilterButton.d.ts.map +1 -0
  77. package/dist/components/misc/ClearFilterButton.js +25 -0
  78. package/dist/components/misc/ClearFilterButton.js.map +1 -0
  79. package/dist/components/misc/FilterContainer.d.ts +12 -0
  80. package/dist/components/misc/FilterContainer.d.ts.map +1 -0
  81. package/dist/components/misc/FilterContainer.js +18 -0
  82. package/dist/components/misc/FilterContainer.js.map +1 -0
  83. package/dist/components/misc/index.d.ts +3 -0
  84. package/dist/components/misc/index.d.ts.map +1 -0
  85. package/dist/components/misc/index.js +3 -0
  86. package/dist/components/misc/index.js.map +1 -0
  87. package/dist/components/panel/FilterPanel.d.ts +19 -0
  88. package/dist/components/panel/FilterPanel.d.ts.map +1 -0
  89. package/dist/components/panel/FilterPanel.js +17 -0
  90. package/dist/components/panel/FilterPanel.js.map +1 -0
  91. package/dist/components/panel/FilterPanelBar.d.ts +3 -0
  92. package/dist/components/panel/FilterPanelBar.d.ts.map +1 -0
  93. package/dist/components/panel/FilterPanelBar.js +31 -0
  94. package/dist/components/panel/FilterPanelBar.js.map +1 -0
  95. package/dist/components/panel/FilterPanelFilters.d.ts +3 -0
  96. package/dist/components/panel/FilterPanelFilters.d.ts.map +1 -0
  97. package/dist/components/panel/FilterPanelFilters.js +13 -0
  98. package/dist/components/panel/FilterPanelFilters.js.map +1 -0
  99. package/dist/components/panel/FilterPanelProvider.d.ts +32 -0
  100. package/dist/components/panel/FilterPanelProvider.d.ts.map +1 -0
  101. package/dist/components/panel/FilterPanelProvider.js +35 -0
  102. package/dist/components/panel/FilterPanelProvider.js.map +1 -0
  103. package/dist/components/panel/FilterPanelSelector.d.ts +7 -0
  104. package/dist/components/panel/FilterPanelSelector.d.ts.map +1 -0
  105. package/dist/components/panel/FilterPanelSelector.js +17 -0
  106. package/dist/components/panel/FilterPanelSelector.js.map +1 -0
  107. package/dist/components/panel/index.d.ts +5 -0
  108. package/dist/components/panel/index.d.ts.map +1 -0
  109. package/dist/components/panel/index.js +5 -0
  110. package/dist/components/panel/index.js.map +1 -0
  111. package/dist/context.d.ts +6 -0
  112. package/dist/context.d.ts.map +1 -0
  113. package/dist/context.js +6 -0
  114. package/dist/context.js.map +1 -0
  115. package/dist/hooks/index.d.ts +12 -0
  116. package/dist/hooks/index.d.ts.map +1 -0
  117. package/dist/hooks/index.js +25 -0
  118. package/dist/hooks/index.js.map +1 -0
  119. package/dist/hooks/useClearFilter.d.ts +9 -0
  120. package/dist/hooks/useClearFilter.d.ts.map +1 -0
  121. package/dist/hooks/useClearFilter.js +30 -0
  122. package/dist/hooks/useClearFilter.js.map +1 -0
  123. package/dist/hooks/useFilter.d.ts +7 -0
  124. package/dist/hooks/useFilter.d.ts.map +1 -0
  125. package/dist/hooks/useFilter.js +26 -0
  126. package/dist/hooks/useFilter.js.map +1 -0
  127. package/dist/hooks/useFilterData.d.ts +11 -0
  128. package/dist/hooks/useFilterData.d.ts.map +1 -0
  129. package/dist/hooks/useFilterData.js +39 -0
  130. package/dist/hooks/useFilterData.js.map +1 -0
  131. package/dist/hooks/useFilterSelection.d.ts +5 -9
  132. package/dist/hooks/useFilterSelection.d.ts.map +1 -1
  133. package/dist/hooks/useFilterSelection.js +6 -21
  134. package/dist/hooks/useFilterSelection.js.map +1 -1
  135. package/dist/index.d.ts +4 -14
  136. package/dist/index.d.ts.map +1 -1
  137. package/dist/index.js +3 -15
  138. package/dist/index.js.map +1 -1
  139. package/dist/options/FilterOptionProvider.d.ts +12 -0
  140. package/dist/options/FilterOptionProvider.d.ts.map +1 -0
  141. package/dist/options/FilterOptionProvider.js +55 -0
  142. package/dist/options/FilterOptionProvider.js.map +1 -0
  143. package/dist/options/actions.d.ts +8 -0
  144. package/dist/options/actions.d.ts.map +1 -0
  145. package/dist/options/actions.js +6 -0
  146. package/dist/options/actions.js.map +1 -0
  147. package/dist/options/context.d.ts +6 -0
  148. package/dist/options/context.d.ts.map +1 -0
  149. package/dist/options/context.js +7 -0
  150. package/dist/options/context.js.map +1 -0
  151. package/dist/options/create-options.d.ts +4 -0
  152. package/dist/options/create-options.d.ts.map +1 -0
  153. package/dist/options/create-options.js +24 -0
  154. package/dist/options/create-options.js.map +1 -0
  155. package/dist/options/index.d.ts +6 -0
  156. package/dist/options/index.d.ts.map +1 -0
  157. package/dist/options/index.js +6 -0
  158. package/dist/options/index.js.map +1 -0
  159. package/dist/options/reducer.d.ts +58 -0
  160. package/dist/options/reducer.d.ts.map +1 -0
  161. package/dist/options/reducer.js +4 -0
  162. package/dist/options/reducer.js.map +1 -0
  163. package/dist/options/search/filter-option-match.d.ts +7 -0
  164. package/dist/options/search/filter-option-match.d.ts.map +1 -0
  165. package/dist/options/search/filter-option-match.js +10 -0
  166. package/dist/options/search/filter-option-match.js.map +1 -0
  167. package/dist/options/search/filter-option-search.d.ts +8 -0
  168. package/dist/options/search/filter-option-search.d.ts.map +1 -0
  169. package/dist/options/search/filter-option-search.js +12 -0
  170. package/dist/options/search/filter-option-search.js.map +1 -0
  171. package/dist/options/search/index.d.ts +2 -0
  172. package/dist/options/search/index.d.ts.map +1 -0
  173. package/dist/options/search/index.js +2 -0
  174. package/dist/options/search/index.js.map +1 -0
  175. package/dist/options/search/types.d.ts +9 -0
  176. package/dist/options/search/types.d.ts.map +1 -0
  177. package/dist/options/search/types.js +2 -0
  178. package/dist/options/search/types.js.map +1 -0
  179. package/dist/options/search/useFilterOptionSearch.d.ts +12 -0
  180. package/dist/options/search/useFilterOptionSearch.d.ts.map +1 -0
  181. package/dist/options/search/useFilterOptionSearch.js +28 -0
  182. package/dist/options/search/useFilterOptionSearch.js.map +1 -0
  183. package/dist/options/types.d.ts +32 -0
  184. package/dist/options/types.d.ts.map +1 -0
  185. package/dist/options/types.js +2 -0
  186. package/dist/options/types.js.map +1 -0
  187. package/dist/reducers.d.ts +170 -0
  188. package/dist/reducers.d.ts.map +1 -0
  189. package/dist/reducers.js +23 -0
  190. package/dist/reducers.js.map +1 -0
  191. package/dist/{types/Filter.d.ts → types.d.ts} +19 -16
  192. package/dist/types.d.ts.map +1 -0
  193. package/dist/types.js +2 -0
  194. package/dist/types.js.map +1 -0
  195. package/options/package.json +6 -0
  196. package/package.json +16 -10
  197. package/dist/FilterContext.d.ts +0 -8
  198. package/dist/FilterContext.d.ts.map +0 -1
  199. package/dist/FilterContext.js +0 -4
  200. package/dist/FilterContext.js.map +0 -1
  201. package/dist/components/CheckBoxFilter/CheckBoxFilter.d.ts +0 -34
  202. package/dist/components/CheckBoxFilter/CheckBoxFilter.d.ts.map +0 -1
  203. package/dist/components/CheckBoxFilter/CheckBoxFilter.js +0 -76
  204. package/dist/components/CheckBoxFilter/CheckBoxFilter.js.map +0 -1
  205. package/dist/components/CheckBoxFilter/CheckBoxOption.d.ts +0 -14
  206. package/dist/components/CheckBoxFilter/CheckBoxOption.d.ts.map +0 -1
  207. package/dist/components/CheckBoxFilter/CheckBoxOption.js +0 -10
  208. package/dist/components/CheckBoxFilter/CheckBoxOption.js.map +0 -1
  209. package/dist/components/CheckBoxFilter/CheckBoxOption.style.d.ts +0 -3
  210. package/dist/components/CheckBoxFilter/CheckBoxOption.style.d.ts.map +0 -1
  211. package/dist/components/CheckBoxFilter/CheckBoxOption.style.js +0 -24
  212. package/dist/components/CheckBoxFilter/CheckBoxOption.style.js.map +0 -1
  213. package/dist/components/CheckBoxFilter/CheckboxFilter.style.d.ts +0 -3
  214. package/dist/components/CheckBoxFilter/CheckboxFilter.style.d.ts.map +0 -1
  215. package/dist/components/CheckBoxFilter/CheckboxFilter.style.js +0 -29
  216. package/dist/components/CheckBoxFilter/CheckboxFilter.style.js.map +0 -1
  217. package/dist/components/CheckBoxFilter/SelectAllOption.d.ts +0 -12
  218. package/dist/components/CheckBoxFilter/SelectAllOption.d.ts.map +0 -1
  219. package/dist/components/CheckBoxFilter/SelectAllOption.js +0 -22
  220. package/dist/components/CheckBoxFilter/SelectAllOption.js.map +0 -1
  221. package/dist/components/CheckBoxFilter/index.d.ts +0 -5
  222. package/dist/components/CheckBoxFilter/index.d.ts.map +0 -1
  223. package/dist/components/CheckBoxFilter/index.js +0 -5
  224. package/dist/components/CheckBoxFilter/index.js.map +0 -1
  225. package/dist/components/FilterSection/FilterSection.d.ts +0 -29
  226. package/dist/components/FilterSection/FilterSection.d.ts.map +0 -1
  227. package/dist/components/FilterSection/FilterSection.js +0 -64
  228. package/dist/components/FilterSection/FilterSection.js.map +0 -1
  229. package/dist/components/FilterSection/FilterSection.style.d.ts +0 -3
  230. package/dist/components/FilterSection/FilterSection.style.d.ts.map +0 -1
  231. package/dist/components/FilterSection/FilterSection.style.js +0 -56
  232. package/dist/components/FilterSection/FilterSection.style.js.map +0 -1
  233. package/dist/components/FilterSection/index.d.ts +0 -3
  234. package/dist/components/FilterSection/index.d.ts.map +0 -1
  235. package/dist/components/FilterSection/index.js +0 -3
  236. package/dist/components/FilterSection/index.js.map +0 -1
  237. package/dist/components/FilterSelectionChips/FilterSelectionChips.d.ts +0 -7
  238. package/dist/components/FilterSelectionChips/FilterSelectionChips.d.ts.map +0 -1
  239. package/dist/components/FilterSelectionChips/FilterSelectionChips.js +0 -18
  240. package/dist/components/FilterSelectionChips/FilterSelectionChips.js.map +0 -1
  241. package/dist/components/FilterSelectionChips/FilterSelectionChips.style.d.ts +0 -3
  242. package/dist/components/FilterSelectionChips/FilterSelectionChips.style.d.ts.map +0 -1
  243. package/dist/components/FilterSelectionChips/FilterSelectionChips.style.js +0 -31
  244. package/dist/components/FilterSelectionChips/FilterSelectionChips.style.js.map +0 -1
  245. package/dist/components/FilterSelectionChips/index.d.ts +0 -2
  246. package/dist/components/FilterSelectionChips/index.d.ts.map +0 -1
  247. package/dist/components/FilterSelectionChips/index.js +0 -2
  248. package/dist/components/FilterSelectionChips/index.js.map +0 -1
  249. package/dist/components/FilterSelectionChips/useChipsSelection.d.ts +0 -9
  250. package/dist/components/FilterSelectionChips/useChipsSelection.d.ts.map +0 -1
  251. package/dist/components/FilterSelectionChips/useChipsSelection.js +0 -26
  252. package/dist/components/FilterSelectionChips/useChipsSelection.js.map +0 -1
  253. package/dist/components/FilterSelector/FilterCategory.d.ts +0 -7
  254. package/dist/components/FilterSelector/FilterCategory.d.ts.map +0 -1
  255. package/dist/components/FilterSelector/FilterCategory.js +0 -24
  256. package/dist/components/FilterSelector/FilterCategory.js.map +0 -1
  257. package/dist/components/FilterSelector/FilterCategory.style.d.ts +0 -3
  258. package/dist/components/FilterSelector/FilterCategory.style.d.ts.map +0 -1
  259. package/dist/components/FilterSelector/FilterCategory.style.js +0 -12
  260. package/dist/components/FilterSelector/FilterCategory.style.js.map +0 -1
  261. package/dist/components/FilterSelector/FilterSelector.d.ts +0 -31
  262. package/dist/components/FilterSelector/FilterSelector.d.ts.map +0 -1
  263. package/dist/components/FilterSelector/FilterSelector.js +0 -51
  264. package/dist/components/FilterSelector/FilterSelector.js.map +0 -1
  265. package/dist/components/FilterSelector/FilterSelector.style.d.ts +0 -3
  266. package/dist/components/FilterSelector/FilterSelector.style.d.ts.map +0 -1
  267. package/dist/components/FilterSelector/FilterSelector.style.js +0 -44
  268. package/dist/components/FilterSelector/FilterSelector.style.js.map +0 -1
  269. package/dist/components/FilterSelector/index.d.ts +0 -4
  270. package/dist/components/FilterSelector/index.d.ts.map +0 -1
  271. package/dist/components/FilterSelector/index.js +0 -4
  272. package/dist/components/FilterSelector/index.js.map +0 -1
  273. package/dist/components/GeneralBar/GeneralBar.d.ts +0 -26
  274. package/dist/components/GeneralBar/GeneralBar.d.ts.map +0 -1
  275. package/dist/components/GeneralBar/GeneralBar.js +0 -63
  276. package/dist/components/GeneralBar/GeneralBar.js.map +0 -1
  277. package/dist/components/GeneralBar/GeneralBar.style.d.ts +0 -3
  278. package/dist/components/GeneralBar/GeneralBar.style.d.ts.map +0 -1
  279. package/dist/components/GeneralBar/GeneralBar.style.js +0 -20
  280. package/dist/components/GeneralBar/GeneralBar.style.js.map +0 -1
  281. package/dist/components/GeneralBar/index.d.ts +0 -3
  282. package/dist/components/GeneralBar/index.d.ts.map +0 -1
  283. package/dist/components/GeneralBar/index.js +0 -3
  284. package/dist/components/GeneralBar/index.js.map +0 -1
  285. package/dist/components/HorizontalBar/HorizontalBar.d.ts +0 -10
  286. package/dist/components/HorizontalBar/HorizontalBar.d.ts.map +0 -1
  287. package/dist/components/HorizontalBar/HorizontalBar.js +0 -23
  288. package/dist/components/HorizontalBar/HorizontalBar.js.map +0 -1
  289. package/dist/components/HorizontalBar/index.d.ts +0 -3
  290. package/dist/components/HorizontalBar/index.d.ts.map +0 -1
  291. package/dist/components/HorizontalBar/index.js +0 -3
  292. package/dist/components/HorizontalBar/index.js.map +0 -1
  293. package/dist/components/HorizontalFilterPanel/HorizontalFilterPanel.d.ts +0 -17
  294. package/dist/components/HorizontalFilterPanel/HorizontalFilterPanel.d.ts.map +0 -1
  295. package/dist/components/HorizontalFilterPanel/HorizontalFilterPanel.js +0 -28
  296. package/dist/components/HorizontalFilterPanel/HorizontalFilterPanel.js.map +0 -1
  297. package/dist/components/HorizontalFilterPanel/index.d.ts +0 -3
  298. package/dist/components/HorizontalFilterPanel/index.d.ts.map +0 -1
  299. package/dist/components/HorizontalFilterPanel/index.js +0 -3
  300. package/dist/components/HorizontalFilterPanel/index.js.map +0 -1
  301. package/dist/components/Icon/index.d.ts +0 -11
  302. package/dist/components/Icon/index.d.ts.map +0 -1
  303. package/dist/components/Icon/index.js +0 -16
  304. package/dist/components/Icon/index.js.map +0 -1
  305. package/dist/components/RadioFilter/RadioFilter.d.ts +0 -17
  306. package/dist/components/RadioFilter/RadioFilter.d.ts.map +0 -1
  307. package/dist/components/RadioFilter/RadioFilter.js +0 -51
  308. package/dist/components/RadioFilter/RadioFilter.js.map +0 -1
  309. package/dist/components/RadioFilter/RadioFilter.style.d.ts +0 -3
  310. package/dist/components/RadioFilter/RadioFilter.style.d.ts.map +0 -1
  311. package/dist/components/RadioFilter/RadioFilter.style.js +0 -38
  312. package/dist/components/RadioFilter/RadioFilter.style.js.map +0 -1
  313. package/dist/components/RadioFilter/index.d.ts +0 -3
  314. package/dist/components/RadioFilter/index.d.ts.map +0 -1
  315. package/dist/components/RadioFilter/index.js +0 -3
  316. package/dist/components/RadioFilter/index.js.map +0 -1
  317. package/dist/epic/StatefulObserver.d.ts +0 -8
  318. package/dist/epic/StatefulObserver.d.ts.map +0 -1
  319. package/dist/epic/StatefulObserver.js +0 -26
  320. package/dist/epic/StatefulObserver.js.map +0 -1
  321. package/dist/epic/epic.d.ts +0 -14
  322. package/dist/epic/epic.d.ts.map +0 -1
  323. package/dist/epic/epic.js +0 -2
  324. package/dist/epic/epic.js.map +0 -1
  325. package/dist/epic/hooks/useObservableSelector.d.ts +0 -14
  326. package/dist/epic/hooks/useObservableSelector.d.ts.map +0 -1
  327. package/dist/epic/hooks/useObservableSelector.js +0 -16
  328. package/dist/epic/hooks/useObservableSelector.js.map +0 -1
  329. package/dist/epic/hooks/useObservableState.d.ts +0 -13
  330. package/dist/epic/hooks/useObservableState.d.ts.map +0 -1
  331. package/dist/epic/hooks/useObservableState.js +0 -18
  332. package/dist/epic/hooks/useObservableState.js.map +0 -1
  333. package/dist/epic/hooks/useSelector.d.ts +0 -10
  334. package/dist/epic/hooks/useSelector.d.ts.map +0 -1
  335. package/dist/epic/hooks/useSelector.js +0 -14
  336. package/dist/epic/hooks/useSelector.js.map +0 -1
  337. package/dist/epic/reducer.d.ts +0 -56
  338. package/dist/epic/reducer.d.ts.map +0 -1
  339. package/dist/epic/reducer.js +0 -78
  340. package/dist/epic/reducer.js.map +0 -1
  341. package/dist/filterStore/actions.d.ts +0 -23
  342. package/dist/filterStore/actions.d.ts.map +0 -1
  343. package/dist/filterStore/actions.js +0 -18
  344. package/dist/filterStore/actions.js.map +0 -1
  345. package/dist/filterStore/epics.d.ts +0 -10
  346. package/dist/filterStore/epics.d.ts.map +0 -1
  347. package/dist/filterStore/epics.js +0 -10
  348. package/dist/filterStore/epics.js.map +0 -1
  349. package/dist/filterStore/reducers.d.ts +0 -4
  350. package/dist/filterStore/reducers.d.ts.map +0 -1
  351. package/dist/filterStore/reducers.js +0 -43
  352. package/dist/filterStore/reducers.js.map +0 -1
  353. package/dist/filterStore/store.d.ts +0 -106
  354. package/dist/filterStore/store.d.ts.map +0 -1
  355. package/dist/filterStore/store.js +0 -158
  356. package/dist/filterStore/store.js.map +0 -1
  357. package/dist/hooks/useEventListener.d.ts +0 -4
  358. package/dist/hooks/useEventListener.d.ts.map +0 -1
  359. package/dist/hooks/useEventListener.js +0 -14
  360. package/dist/hooks/useEventListener.js.map +0 -1
  361. package/dist/hooks/useFilterChangeHandler.d.ts +0 -26
  362. package/dist/hooks/useFilterChangeHandler.d.ts.map +0 -1
  363. package/dist/hooks/useFilterChangeHandler.js +0 -43
  364. package/dist/hooks/useFilterChangeHandler.js.map +0 -1
  365. package/dist/hooks/useFilterContext.d.ts +0 -4
  366. package/dist/hooks/useFilterContext.d.ts.map +0 -1
  367. package/dist/hooks/useFilterContext.js +0 -5
  368. package/dist/hooks/useFilterContext.js.map +0 -1
  369. package/dist/hooks/useFilterOptionsBuilder.d.ts +0 -27
  370. package/dist/hooks/useFilterOptionsBuilder.d.ts.map +0 -1
  371. package/dist/hooks/useFilterOptionsBuilder.js +0 -39
  372. package/dist/hooks/useFilterOptionsBuilder.js.map +0 -1
  373. package/dist/hooks/useFilterOptionsCounter.d.ts +0 -16
  374. package/dist/hooks/useFilterOptionsCounter.d.ts.map +0 -1
  375. package/dist/hooks/useFilterOptionsCounter.js +0 -32
  376. package/dist/hooks/useFilterOptionsCounter.js.map +0 -1
  377. package/dist/hooks/useFilterStore.d.ts +0 -25
  378. package/dist/hooks/useFilterStore.d.ts.map +0 -1
  379. package/dist/hooks/useFilterStore.js +0 -34
  380. package/dist/hooks/useFilterStore.js.map +0 -1
  381. package/dist/hooks/useResizablePanel.d.ts +0 -20
  382. package/dist/hooks/useResizablePanel.d.ts.map +0 -1
  383. package/dist/hooks/useResizablePanel.js +0 -71
  384. package/dist/hooks/useResizablePanel.js.map +0 -1
  385. package/dist/types/Filter.d.ts.map +0 -1
  386. package/dist/types/Filter.js +0 -2
  387. package/dist/types/Filter.js.map +0 -1
  388. package/dist/types/FilterContainerProps.d.ts +0 -10
  389. package/dist/types/FilterContainerProps.d.ts.map +0 -1
  390. package/dist/types/FilterContainerProps.js +0 -2
  391. package/dist/types/FilterContainerProps.js.map +0 -1
  392. package/dist/types/FilterCounters.d.ts +0 -3
  393. package/dist/types/FilterCounters.d.ts.map +0 -1
  394. package/dist/types/FilterCounters.js +0 -2
  395. package/dist/types/FilterCounters.js.map +0 -1
  396. package/dist/types/FilterOption.d.ts +0 -13
  397. package/dist/types/FilterOption.d.ts.map +0 -1
  398. package/dist/types/FilterOption.js +0 -2
  399. package/dist/types/FilterOption.js.map +0 -1
  400. package/dist/types/FilterStoreState.d.ts +0 -6
  401. package/dist/types/FilterStoreState.d.ts.map +0 -1
  402. package/dist/types/FilterStoreState.js +0 -2
  403. package/dist/types/FilterStoreState.js.map +0 -1
@@ -1,12 +0,0 @@
1
- import { createStyles, makeStyles } from '@equinor/fusion-react-styles';
2
- export const useStyles = makeStyles(() => createStyles({
3
- FilterCategoryContainer: {
4
- display: 'flex',
5
- alignItems: 'center',
6
- },
7
- CategoryLabel: {
8
- cursor: 'pointer',
9
- },
10
- }));
11
- export default useStyles;
12
- //# sourceMappingURL=FilterCategory.style.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"FilterCategory.style.js","sourceRoot":"","sources":["../../../src/components/FilterSelector/FilterCategory.style.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,UAAU,EAAE,MAAM,8BAA8B,CAAC;AAExE,MAAM,CAAC,MAAM,SAAS,GAAG,UAAU,CAAC,GAAG,EAAE,CACvC,YAAY,CAAC;IACX,uBAAuB,EAAE;QACvB,OAAO,EAAE,MAAM;QACf,UAAU,EAAE,QAAQ;KACrB;IACD,aAAa,EAAE;QACb,MAAM,EAAE,SAAS;KAClB;CACF,CAAC,CACH,CAAC;AAEF,eAAe,SAAS,CAAC"}
@@ -1,31 +0,0 @@
1
- import { PropsWithChildren } from 'react';
2
- declare type FilterSelectorProps = {
3
- useSearch?: boolean;
4
- compact?: boolean;
5
- };
6
- export declare type FilterCategoryType = {
7
- filterKey: string;
8
- title: string;
9
- selected: boolean;
10
- disabled: boolean;
11
- description?: string;
12
- };
13
- /**
14
- * Filter Selector provides a way to select and unselect Filters.
15
- * Supplied filters will be list out and can be (un)selected through a checkbox.
16
- * The filter will then be (de)registered as an active filter.
17
- *
18
- * Component decides which filter that is selected by looking at the Selections.
19
- * If the key is in selections, filter will be marked as selected.
20
- *
21
- * @param useSearch Add a search bar to filter selector, to search for filters.
22
- * @param compact Compact Filter options text and checkbox size
23
- * @param children Add Filters components as children.
24
- * @example
25
- * <FilterSelector useSearch compact >
26
- * <CheckBoxFilter filter={filterSettings} />
27
- * </FilterSection>
28
- */
29
- export declare const FilterSelector: ({ useSearch, compact, children, }: PropsWithChildren<FilterSelectorProps>) => JSX.Element;
30
- export default FilterSelector;
31
- //# sourceMappingURL=FilterSelector.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"FilterSelector.d.ts","sourceRoot":"","sources":["../../../src/components/FilterSelector/FilterSelector.tsx"],"names":[],"mappings":"AAAA,OAAc,EAAY,iBAAiB,EAAmC,MAAM,OAAO,CAAC;AAY5F,aAAK,mBAAmB,GAAG;IAAE,SAAS,CAAC,EAAE,OAAO,CAAC;IAAC,OAAO,CAAC,EAAE,OAAO,CAAA;CAAE,CAAC;AAEtE,oBAAY,kBAAkB,GAAG;IAC/B,SAAS,EAAE,MAAM,CAAC;IAClB,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,OAAO,CAAC;IAClB,QAAQ,EAAE,OAAO,CAAC;IAClB,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,CAAC;AAkBF;;;;;;;;;;;;;;;GAeG;AAEH,eAAO,MAAM,cAAc,sCAIxB,kBAAkB,mBAAmB,CAAC,KAAG,WA6C3C,CAAC;AAEF,eAAe,cAAc,CAAC"}
@@ -1,51 +0,0 @@
1
- import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
2
- import { Children, useMemo, useState } from 'react';
3
- import { clsx } from '@equinor/fusion-react-styles';
4
- import FilterCategory from './FilterCategory';
5
- import useStyles from './FilterSelector.style';
6
- import { TextInput } from '@equinor/fusion-react-textinput';
7
- import Icon from '../Icon';
8
- import { arrow_back, arrow_forward } from '@equinor/eds-icons';
9
- import useFilterContext from '../../hooks/useFilterContext';
10
- import useSelector from '../../epic/hooks/useSelector';
11
- const filterCategories = (children, selection, filterSearch) => Children.toArray(children)
12
- .filter((child) => child.props.filter.title.toLocaleLowerCase().includes(filterSearch.toLocaleLowerCase()))
13
- .map((child) => {
14
- const { key, title, mandatory, description } = child.props.filter;
15
- return {
16
- filterKey: key,
17
- title: title,
18
- selected: Boolean(mandatory) || Object.hasOwnProperty.call(selection, key),
19
- disabled: Boolean(mandatory),
20
- description: description,
21
- };
22
- });
23
- /**
24
- * Filter Selector provides a way to select and unselect Filters.
25
- * Supplied filters will be list out and can be (un)selected through a checkbox.
26
- * The filter will then be (de)registered as an active filter.
27
- *
28
- * Component decides which filter that is selected by looking at the Selections.
29
- * If the key is in selections, filter will be marked as selected.
30
- *
31
- * @param useSearch Add a search bar to filter selector, to search for filters.
32
- * @param compact Compact Filter options text and checkbox size
33
- * @param children Add Filters components as children.
34
- * @example
35
- * <FilterSelector useSearch compact >
36
- * <CheckBoxFilter filter={filterSettings} />
37
- * </FilterSection>
38
- */
39
- export const FilterSelector = ({ useSearch = false, compact = false, children, }) => {
40
- const [show, setShow] = useState(true);
41
- const [filterSearch, setFilterSearch] = useState('');
42
- const { store } = useFilterContext();
43
- const selection = useSelector(store, 'selection');
44
- const onChange = (e) => setFilterSearch(e.currentTarget.value);
45
- const categories = useMemo(() => filterCategories(children, selection, filterSearch), [children, selection, filterSearch]);
46
- const styles = useStyles();
47
- const filterSelectorContainer = useMemo(() => clsx(styles.FilterSelectorContainer, show ? styles.FilterSelectorOpen : styles.FilterSelectorMinimized), [show, styles]);
48
- return (_jsxs("div", Object.assign({ className: filterSelectorContainer }, { children: [_jsx("div", Object.assign({ className: styles.SelectorHeader, onClick: () => setShow((s) => !s) }, { children: show ? (_jsxs(_Fragment, { children: [_jsx("span", Object.assign({ className: styles.SelectorHeaderText }, { children: "Filter Categories" }), void 0), _jsx(Icon, { icon: arrow_back }, void 0)] }, void 0)) : (_jsx(Icon, { icon: arrow_forward }, void 0)) }), void 0), show && (_jsxs(_Fragment, { children: [useSearch && _jsx(TextInput, { onInput: onChange, value: filterSearch, placeholder: 'Search', type: 'search' }, void 0), _jsx("ul", Object.assign({ className: styles.SelectorSection }, { children: categories.map((category) => (_jsx(FilterCategory, Object.assign({ compact: compact }, category), category.filterKey))) }), void 0)] }, void 0))] }), void 0));
49
- };
50
- export default FilterSelector;
51
- //# sourceMappingURL=FilterSelector.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"FilterSelector.js","sourceRoot":"","sources":["../../../src/components/FilterSelector/FilterSelector.tsx"],"names":[],"mappings":";AAAA,OAAc,EAAE,QAAQ,EAAmC,OAAO,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAC5F,OAAO,E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YACG,EAEL,IAAI,IAAI,CACP,8BACG,SAAS,IAAI,KAAC,SAAS,IAAC,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,YAAY,EAAE,WAAW,EAAE,QAAQ,EAAE,IAAI,EAAE,QAAQ,WAAI,EAC1G,2BAAI,SAAS,EAAE,MAAM,CAAC,eAAe,gBAClC,UAAU,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE,EAAE,CAAC,CAC5B,KAAC,cAAc,kBAA0B,OAAO,EAAE,OAAO,IAAM,QAAQ,GAAlD,QAAQ,CAAC,SAAS,CAAoC,CAC5E,CAAC,YACC,YACJ,CACJ,aACG,CACP,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,cAAc,CAAC"}
@@ -1,3 +0,0 @@
1
- export declare const useStyles: (props?: {} | undefined) => import("@material-ui/styles").ClassNameMap<"FilterSelectorContainer" | "FilterSelectorOpen" | "FilterSelectorMinimized" | "SelectorHeader" | "SelectorHeaderText" | "SelectorTextInputIcon" | "SelectorSection">;
2
- export default useStyles;
3
- //# sourceMappingURL=FilterSelector.style.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"FilterSelector.style.d.ts","sourceRoot":"","sources":["../../../src/components/FilterSelector/FilterSelector.style.tsx"],"names":[],"mappings":"AAEA,eAAO,MAAM,SAAS,8OA+CrB,CAAC;AAEF,eAAe,SAAS,CAAC"}
@@ -1,44 +0,0 @@
1
- import { createStyles, makeStyles } from '@equinor/fusion-react-styles';
2
- export const useStyles = makeStyles((theme) => createStyles({
3
- FilterSelectorContainer: {
4
- position: 'sticky',
5
- left: 0,
6
- zIndex: 99,
7
- display: 'flex',
8
- flexDirection: 'column',
9
- height: '100%',
10
- boxSizing: 'border-box',
11
- padding: '16px',
12
- paddingBottom: '0px',
13
- backgroundColor: 'inherit',
14
- borderRight: `solid 1px ${theme.colors.ui.background__medium.value.hex}`,
15
- },
16
- FilterSelectorOpen: {
17
- minWidth: '200px',
18
- },
19
- FilterSelectorMinimized: {
20
- width: '48px',
21
- },
22
- SelectorHeader: {
23
- display: 'flex',
24
- justifyContent: 'space-between',
25
- alignItems: 'center',
26
- cursor: 'pointer',
27
- fontWeight: 'bold',
28
- whiteSpace: 'nowrap',
29
- },
30
- SelectorHeaderText: {
31
- lineHeight: '24px',
32
- },
33
- SelectorTextInputIcon: {
34
- transform: 'scale(08)',
35
- cursor: 'pointer',
36
- },
37
- SelectorSection: {
38
- padding: '8px 0',
39
- overflowY: 'auto',
40
- margin: '0px',
41
- },
42
- }), { name: 'fusion-filterpane-filterSelector' });
43
- export default useStyles;
44
- //# sourceMappingURL=FilterSelector.style.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"FilterSelector.style.js","sourceRoot":"","sources":["../../../src/components/FilterSelector/FilterSelector.style.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,UAAU,EAAE,MAAM,8BAA8B,CAAC;AAExE,MAAM,CAAC,MAAM,SAAS,GAAG,UAAU,CACjC,CAAC,KAAK,EAAE,EAAE,CACR,YAAY,CAAC;IACX,uBAAuB,EAAE;QACvB,QAAQ,EAAE,QAAQ;QAClB,IAAI,EAAE,CAAC;QACP,MAAM,EAAE,EAAE;QACV,OAAO,EAAE,MAAM;QACf,aAAa,EAAE,QAAQ;QACvB,MAAM,EAAE,MAAM;QACd,SAAS,EAAE,YAAY;QACvB,OAAO,EAAE,MAAM;QACf,aAAa,EAAE,KAAK;QACpB,eAAe,EAAE,SAAS;QAC1B,WAAW,EAAE,aAAa,KAAK,CAAC,MAAM,CAAC,EAAE,CAAC,kBAAkB,CAAC,KAAK,CAAC,GAAG,EAAE;KACzE;IACD,kBAAkB,EAAE;QAClB,QAAQ,EAAE,OAAO;KAClB;IACD,uBAAuB,EAAE;QACvB,KAAK,EAAE,MAAM;KACd;IACD,cAAc,EAAE;QACd,OAAO,EAAE,MAAM;QACf,cAAc,EAAE,eAAe;QAC/B,UAAU,EAAE,QAAQ;QACpB,MAAM,EAAE,SAAS;QACjB,UAAU,EAAE,MAAM;QAClB,UAAU,EAAE,QAAQ;KACrB;IAED,kBAAkB,EAAE;QAClB,UAAU,EAAE,MAAM;KACnB;IAED,qBAAqB,EAAE;QACrB,SAAS,EAAE,WAAW;QACtB,MAAM,EAAE,SAAS;KAClB;IAED,eAAe,EAAE;QACf,OAAO,EAAE,OAAO;QAChB,SAAS,EAAE,MAAM;QACjB,MAAM,EAAE,KAAK;KACd;CACF,CAAC,EACJ,EAAE,IAAI,EAAE,kCAAkC,EAAE,CAC7C,CAAC;AAEF,eAAe,SAAS,CAAC"}
@@ -1,4 +0,0 @@
1
- export * from './FilterSelector';
2
- export * from './FilterCategory';
3
- export { default } from './FilterSelector';
4
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/FilterSelector/index.tsx"],"names":[],"mappings":"AAAA,cAAc,kBAAkB,CAAC;AACjC,cAAc,kBAAkB,CAAC;AAEjC,OAAO,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC"}
@@ -1,4 +0,0 @@
1
- export * from './FilterSelector';
2
- export * from './FilterCategory';
3
- export { default } from './FilterSelector';
4
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/FilterSelector/index.tsx"],"names":[],"mappings":"AAAA,cAAc,kBAAkB,CAAC;AACjC,cAAc,kBAAkB,CAAC;AAEjC,OAAO,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC"}
@@ -1,26 +0,0 @@
1
- import React, { PropsWithChildren } from 'react';
2
- import { TSelection } from '../../FilterProvider';
3
- declare type GeneralBarProps<TData, TSelection> = {
4
- onMinimize: React.Dispatch<React.SetStateAction<boolean>>;
5
- minimized: boolean;
6
- searchFilterFn: (data: TData, searchString: TSelection) => TData;
7
- };
8
- /**
9
- *A general purpose Bar that implements a "global" search for your dataset.
10
- *Show/hide buttons for the filter section and Clear filters button.
11
- *When minimized it also shows Chips, that summarized the chosen filters.
12
- *
13
- *Own components can be added as children. These will be shown after built in components.
14
- *
15
- * @param searchFilterFn How the search box should interact with the data
16
- * @param minimized open/close state of main filter view
17
- * @param onMinimize function added to Show/Hide filter button
18
- * @param children Added after built in components, flows left to right.
19
- * @example
20
- * const searchFn = (data,search) => data.filter((d) => d.name.includes(search) )
21
- * const [minimized,setMinimized] = useState(false)
22
- * <GeneralBar searchFilterFn={searchFn} minimized={minimized} onMinimize={setMinimized}
23
- */
24
- export declare const GeneralBar: <TData>({ searchFilterFn, minimized, onMinimize, children, }: React.PropsWithChildren<GeneralBarProps<TData, any>>) => JSX.Element;
25
- export default GeneralBar;
26
- //# sourceMappingURL=GeneralBar.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"GeneralBar.d.ts","sourceRoot":"","sources":["../../../src/components/GeneralBar/GeneralBar.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAA6C,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAS5F,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AA+BlD,aAAK,eAAe,CAAC,KAAK,EAAE,UAAU,IAAI;IACxC,UAAU,EAAE,KAAK,CAAC,QAAQ,CAAC,KAAK,CAAC,cAAc,CAAC,OAAO,CAAC,CAAC,CAAC;IAC1D,SAAS,EAAE,OAAO,CAAC;IACnB,cAAc,EAAE,CAAC,IAAI,EAAE,KAAK,EAAE,YAAY,EAAE,UAAU,KAAK,KAAK,CAAC;CAClE,CAAC;AAEF;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,UAAU,yHAKoC,WAiC1D,CAAC;AAEF,eAAe,UAAU,CAAC"}
@@ -1,63 +0,0 @@
1
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
- import { useCallback, useEffect, useMemo, useState } from 'react';
3
- import { Subject } from 'rxjs';
4
- import { pluck, withLatestFrom } from 'rxjs/operators';
5
- import Button from '@equinor/fusion-react-button';
6
- import useStyles from './GeneralBar.style';
7
- import FilterSelectionChips from '../FilterSelectionChips/FilterSelectionChips';
8
- import HorizontalBar from '../HorizontalBar/HorizontalBar';
9
- import { TextInput } from '@equinor/fusion-react-textinput';
10
- import useFilterContext from '../../hooks/useFilterContext';
11
- const useChangeHandler = (key) => {
12
- const { store } = useFilterContext();
13
- const change$ = useMemo(() => new Subject(), []);
14
- useEffect(() => {
15
- const subscription = change$
16
- .pipe(withLatestFrom(store.selection$.pipe(pluck(key))))
17
- .subscribe(([change]) => store.updateFilterSelection(key, change));
18
- return () => subscription.unsubscribe();
19
- }, [key]);
20
- return useCallback((searchValue) => change$.next(searchValue), [change$]);
21
- };
22
- const useSearch = (searchKey) => {
23
- const { store } = useFilterContext();
24
- const [searchValue, setSearchValue] = useState('');
25
- useEffect(() => {
26
- const subscription = store.selection$.pipe(pluck(searchKey)).subscribe((selection) => {
27
- setSearchValue(selection || '');
28
- });
29
- return () => subscription.unsubscribe();
30
- }, []);
31
- return searchValue;
32
- };
33
- /**
34
- *A general purpose Bar that implements a "global" search for your dataset.
35
- *Show/hide buttons for the filter section and Clear filters button.
36
- *When minimized it also shows Chips, that summarized the chosen filters.
37
- *
38
- *Own components can be added as children. These will be shown after built in components.
39
- *
40
- * @param searchFilterFn How the search box should interact with the data
41
- * @param minimized open/close state of main filter view
42
- * @param onMinimize function added to Show/Hide filter button
43
- * @param children Added after built in components, flows left to right.
44
- * @example
45
- * const searchFn = (data,search) => data.filter((d) => d.name.includes(search) )
46
- * const [minimized,setMinimized] = useState(false)
47
- * <GeneralBar searchFilterFn={searchFn} minimized={minimized} onMinimize={setMinimized}
48
- */
49
- export const GeneralBar = ({ searchFilterFn, minimized, onMinimize, children, }) => {
50
- const store = useFilterContext().store;
51
- const SEARCH_KEY = 'GENERALBAR_SEARCH';
52
- const filterSearch = useSearch(SEARCH_KEY);
53
- const handleChange = useChangeHandler(SEARCH_KEY);
54
- const onChange = useCallback((searchValue) => handleChange(searchValue.currentTarget.value), [handleChange]);
55
- useEffect(() => {
56
- store.registerFilter(SEARCH_KEY, searchFilterFn);
57
- return () => store.unRegisterFilter(SEARCH_KEY);
58
- }, [searchFilterFn, store]);
59
- const styles = useStyles();
60
- return (_jsxs(HorizontalBar, { children: [_jsx(TextInput, { onInput: onChange, value: filterSearch, placeholder: 'Search', type: 'search' }, void 0), _jsxs("div", Object.assign({ className: styles.ButtonContainer }, { children: [_jsx(Button, Object.assign({ variant: 'outlined', icon: 'filter_list', onClick: () => onMinimize(!minimized) }, { children: minimized ? 'Show filters' : 'Hide filters' }), void 0), _jsx(Button, Object.assign({ variant: 'outlined', icon: 'close', onClick: () => store.clearAllFilterSelections() }, { children: "Clear filters" }), void 0)] }), void 0), minimized && _jsx(FilterSelectionChips, {}, void 0), _jsx("div", { children: children }, void 0)] }, void 0));
61
- };
62
- export default GeneralBar;
63
- //# sourceMappingURL=GeneralBar.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"GeneralBar.js","sourceRoot":"","sources":["../../../src/components/GeneralBar/GeneralBar.tsx"],"names":[],"mappings":";AAAA,OAAc,EAAE,WAAW,EAAE,SAAS,EAAE,OAAO,EAAE,QAAQ,EAAqB,MAAM,OAAO,CAAC;AAC5F,OAAO,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;AAC/B,OAAO,EAAE,KAAK,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAEvD,OAAO,MAAM,MAAM,8BAA8B,CAAC;AAClD,OAAO,SAAS,MAAM,oBAAoB,CAAC;AAC3C,OAAO,oBAAoB,MAAM,8CAA8C,CAAC;AAChF,OAAO,aAAa,MAAM,gCAAgC,CAAC;AAG3D,OAAO,EAA8B,SAAS,EAAE,MAAM,iCAAiC,CAAC;AACxF,OAAO,gBAAgB,MAAM,8BAA8B,CAAC;AAE5D,MAAM,gBAAgB,GAAG,CAAC,GAAW,EAAE,EAAE;IACvC,MAAM,EAAE,KAAK,EAAE,GAAG,gBAAgB,EAAE,CAAC;IACrC,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AAK,CAAC,wBAAwB,EAAE,2CAElF,aACL,EACL,SAAS,IAAI,KAAC,oBAAoB,aAAG,EACtC,wBAAM,QAAQ,WAAO,YACP,CACjB,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,UAAU,CAAC"}
@@ -1,3 +0,0 @@
1
- declare const useStyles: (props?: {} | undefined) => import("@material-ui/styles").ClassNameMap<"TextInputIcon" | "ButtonContainer" | "SearchBar">;
2
- export default useStyles;
3
- //# sourceMappingURL=GeneralBar.style.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"GeneralBar.style.d.ts","sourceRoot":"","sources":["../../../src/components/GeneralBar/GeneralBar.style.tsx"],"names":[],"mappings":"AAEA,QAAA,MAAM,SAAS,2HAoBd,CAAC;AAEF,eAAe,SAAS,CAAC"}
@@ -1,20 +0,0 @@
1
- import { createStyles, makeStyles } from '@equinor/fusion-react-styles';
2
- const useStyles = makeStyles(() => createStyles({
3
- ButtonContainer: {
4
- display: 'grid',
5
- columnGap: '8px',
6
- gridTemplateColumns: '1fr 1fr',
7
- padding: ' 0 8px',
8
- whiteSpace: 'nowrap',
9
- },
10
- SearchBar: {
11
- width: '240px',
12
- margin: '0 8px',
13
- },
14
- TextInputIcon: {
15
- transform: 'scale(0.8)',
16
- cursor: 'pointer',
17
- },
18
- }), { name: 'fusion-filterpane-generalBar' });
19
- export default useStyles;
20
- //# sourceMappingURL=GeneralBar.style.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"GeneralBar.style.js","sourceRoot":"","sources":["../../../src/components/GeneralBar/GeneralBar.style.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,UAAU,EAAE,MAAM,8BAA8B,CAAC;AAExE,MAAM,SAAS,GAAG,UAAU,CAC1B,GAAG,EAAE,CACH,YAAY,CAAC;IACX,eAAe,EAAE;QACf,OAAO,EAAE,MAAM;QACf,SAAS,EAAE,KAAK;QAChB,mBAAmB,EAAE,SAAS;QAC9B,OAAO,EAAE,QAAQ;QACjB,UAAU,EAAE,QAAQ;KACrB;IACD,SAAS,EAAE;QACT,KAAK,EAAE,OAAO;QACd,MAAM,EAAE,OAAO;KAChB;IACD,aAAa,EAAE;QACb,SAAS,EAAE,YAAY;QACvB,MAAM,EAAE,SAAS;KAClB;CACF,CAAC,EACJ,EAAE,IAAI,EAAE,8BAA8B,EAAE,CACzC,CAAC;AAEF,eAAe,SAAS,CAAC"}
@@ -1,3 +0,0 @@
1
- export * from './GeneralBar';
2
- export { default } from './GeneralBar';
3
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/GeneralBar/index.tsx"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAC;AAE7B,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC"}
@@ -1,3 +0,0 @@
1
- export * from './GeneralBar';
2
- export { default } from './GeneralBar';
3
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/GeneralBar/index.tsx"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAC;AAE7B,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC"}
@@ -1,10 +0,0 @@
1
- import { FC } from 'react';
2
- /**
3
- * Generic empty horizontal bar. Use for consistent styling
4
- * @param children are added left to right.
5
- * @example
6
- * <HorizontalBar>{children}</HorizontalBar>
7
- */
8
- export declare const HorizontalBar: FC;
9
- export default HorizontalBar;
10
- //# sourceMappingURL=HorizontalBar.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"HorizontalBar.d.ts","sourceRoot":"","sources":["../../../src/components/HorizontalBar/HorizontalBar.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AAiB3B;;;;;GAKG;AACH,eAAO,MAAM,aAAa,EAAE,EAI3B,CAAC;AAEF,eAAe,aAAa,CAAC"}
@@ -1,23 +0,0 @@
1
- import { jsx as _jsx } from "react/jsx-runtime";
2
- import { createStyles, makeStyles } from '@equinor/fusion-react-styles';
3
- const useStyles = makeStyles((theme) => createStyles({
4
- HorizontalBar: {
5
- padding: '8px',
6
- display: 'flex',
7
- alignItems: 'center',
8
- height: '48px',
9
- borderBottom: `solid 1px ${theme.colors.ui.background__medium.value.hex}`,
10
- },
11
- }), { name: 'fusion-filterpane-horizontalBar' });
12
- /**
13
- * Generic empty horizontal bar. Use for consistent styling
14
- * @param children are added left to right.
15
- * @example
16
- * <HorizontalBar>{children}</HorizontalBar>
17
- */
18
- export const HorizontalBar = (props) => {
19
- const styles = useStyles();
20
- return _jsx("div", Object.assign({ className: styles.HorizontalBar }, { children: props?.children }), void 0);
21
- };
22
- export default HorizontalBar;
23
- //# sourceMappingURL=HorizontalBar.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"HorizontalBar.js","sourceRoot":"","sources":["../../../src/components/HorizontalBar/HorizontalBar.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,YAAY,EAAE,UAAU,EAAE,MAAM,8BAA8B,CAAC;AAExE,MAAM,SAAS,GAAG,UAAU,CAC1B,CAAC,KAAK,EAAE,EAAE,CACR,YAAY,CAAC;IACX,aAAa,EAAE;QACb,OAAO,EAAE,KAAK;QACd,OAAO,EAAE,MAAM;QACf,UAAU,EAAE,QAAQ;QACpB,MAAM,EAAE,MAAM;QACd,YAAY,EAAE,aAAa,KAAK,CAAC,MAAM,CAAC,EAAE,CAAC,kBAAkB,CAAC,KAAK,CAAC,GAAG,EAAE;KAC1E;CACF,CAAC,EACJ,EAAE,IAAI,EAAE,iCAAiC,EAAE,CAC5C,CAAC;AAEF;;;;;GAKG;AACH,MAAM,CAAC,MAAM,aAAa,GAAO,CAAC,KAAK,EAAe,EAAE;IACtD,MAAM,MAAM,GAAG,SAAS,EAAE,CAAC;IAE3B,OAAO,4BAAK,SAAS,EAAE,MAAM,CAAC,aAAa,gBAAG,KAAK,EAAE,QAAQ,YAAO,CAAC;AACvE,CAAC,CAAC;AAEF,eAAe,aAAa,CAAC"}
@@ -1,3 +0,0 @@
1
- export * from './HorizontalBar';
2
- export { default } from './HorizontalBar';
3
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/HorizontalBar/index.tsx"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAC;AAChC,OAAO,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAC"}
@@ -1,3 +0,0 @@
1
- export * from './HorizontalBar';
2
- export { default } from './HorizontalBar';
3
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/HorizontalBar/index.tsx"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAC;AAChC,OAAO,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAC"}
@@ -1,17 +0,0 @@
1
- import { PropsWithChildren } from 'react';
2
- declare type FilterPanelProps = Record<string, unknown>;
3
- /**
4
- * A simple component that spans horizontal, used as a container for the standard filterpanel.
5
- * Add components as children, they will flow as columns (flex-direction).
6
- *
7
- * @param children Add all components used for filterpanel
8
- * @example
9
- * <FilterPanel>
10
- * <FilterSection isMinimized={minimized} useFilterSelector useFilterSelectorSearch>
11
- * <CheckBoxFilter filter={{ ...firstNameCheck }} useSelectAll useSearch />
12
- * </FilterSection>
13
- * </FilterPanel>
14
- */
15
- export declare const HorizontalFilterPanel: ({ children }: PropsWithChildren<FilterPanelProps>) => JSX.Element;
16
- export default HorizontalFilterPanel;
17
- //# sourceMappingURL=HorizontalFilterPanel.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"HorizontalFilterPanel.d.ts","sourceRoot":"","sources":["../../../src/components/HorizontalFilterPanel/HorizontalFilterPanel.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAE1C,aAAK,gBAAgB,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;AAehD;;;;;;;;;;;GAWG;AAEH,eAAO,MAAM,qBAAqB,iBAAkB,kBAAkB,gBAAgB,CAAC,KAAG,WAGzF,CAAC;AAEF,eAAe,qBAAqB,CAAC"}
@@ -1,28 +0,0 @@
1
- import { jsx as _jsx } from "react/jsx-runtime";
2
- import { createStyles, makeStyles } from '@equinor/fusion-react-styles';
3
- const useStyles = makeStyles(() => createStyles({
4
- FilterPanelContainer: {
5
- display: 'flex',
6
- flexDirection: 'column',
7
- width: '100%',
8
- boxSizing: 'border-box',
9
- },
10
- }), { name: 'fusion-filterpane-horizontalFilterPanel' });
11
- /**
12
- * A simple component that spans horizontal, used as a container for the standard filterpanel.
13
- * Add components as children, they will flow as columns (flex-direction).
14
- *
15
- * @param children Add all components used for filterpanel
16
- * @example
17
- * <FilterPanel>
18
- * <FilterSection isMinimized={minimized} useFilterSelector useFilterSelectorSearch>
19
- * <CheckBoxFilter filter={{ ...firstNameCheck }} useSelectAll useSearch />
20
- * </FilterSection>
21
- * </FilterPanel>
22
- */
23
- export const HorizontalFilterPanel = ({ children }) => {
24
- const styles = useStyles();
25
- return _jsx("div", Object.assign({ className: styles.FilterPanelContainer }, { children: children }), void 0);
26
- };
27
- export default HorizontalFilterPanel;
28
- //# sourceMappingURL=HorizontalFilterPanel.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"HorizontalFilterPanel.js","sourceRoot":"","sources":["../../../src/components/HorizontalFilterPanel/HorizontalFilterPanel.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,YAAY,EAAE,UAAU,EAAE,MAAM,8BAA8B,CAAC;AAGxE,MAAM,SAAS,GAAG,UAAU,CAC1B,GAAG,EAAE,CACH,YAAY,CAAC;IACX,oBAAoB,EAAE;QACpB,OAAO,EAAE,MAAM;QACf,aAAa,EAAE,QAAQ;QACvB,KAAK,EAAE,MAAM;QACb,SAAS,EAAE,YAAY;KACxB;CACF,CAAC,EACJ,EAAE,IAAI,EAAE,yCAAyC,EAAE,CACpD,CAAC;AAEF;;;;;;;;;;;GAWG;AAEH,MAAM,CAAC,MAAM,qBAAqB,GAAG,CAAC,EAAE,QAAQ,EAAuC,EAAe,EAAE;IACtG,MAAM,MAAM,GAAG,SAAS,EAAE,CAAC;IAC3B,OAAO,4BAAK,SAAS,EAAE,MAAM,CAAC,oBAAoB,gBAAG,QAAQ,YAAO,CAAC;AACvE,CAAC,CAAC;AAEF,eAAe,qBAAqB,CAAC"}
@@ -1,3 +0,0 @@
1
- export * from './HorizontalFilterPanel';
2
- export { default } from './HorizontalFilterPanel';
3
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/HorizontalFilterPanel/index.tsx"],"names":[],"mappings":"AAAA,cAAc,yBAAyB,CAAC;AACxC,OAAO,EAAE,OAAO,EAAE,MAAM,yBAAyB,CAAC"}
@@ -1,3 +0,0 @@
1
- export * from './HorizontalFilterPanel';
2
- export { default } from './HorizontalFilterPanel';
3
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/HorizontalFilterPanel/index.tsx"],"names":[],"mappings":"AAAA,cAAc,yBAAyB,CAAC;AACxC,OAAO,EAAE,OAAO,EAAE,MAAM,yBAAyB,CAAC"}
@@ -1,11 +0,0 @@
1
- import { FunctionComponent, MouseEventHandler } from 'react';
2
- import { IconData } from '@equinor/eds-icons';
3
- declare type IconProps = {
4
- className?: string;
5
- icon: IconData;
6
- size?: string;
7
- onClick?: MouseEventHandler<HTMLElement>;
8
- };
9
- export declare const Icon: FunctionComponent<IconProps>;
10
- export default Icon;
11
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Icon/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAE7D,OAAO,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AAQ9C,aAAK,SAAS,GAAG;IACf,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,IAAI,EAAE,QAAQ,CAAC;IACf,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,iBAAiB,CAAC,WAAW,CAAC,CAAC;CAC1C,CAAC;AAaF,eAAO,MAAM,IAAI,EAAE,iBAAiB,CAAC,SAAS,CAe7C,CAAC;AAEF,eAAe,IAAI,CAAC"}
@@ -1,16 +0,0 @@
1
- import { jsx as _jsx } from "react/jsx-runtime";
2
- import { makeStyles, createStyles } from '@equinor/fusion-react-styles';
3
- const useStyle = makeStyles(() => createStyles({
4
- root: ({ size }) => ({
5
- fill: 'currentColor',
6
- height: size ?? '1.375em',
7
- width: 'auto',
8
- verticalAlign: 'middle',
9
- }),
10
- }));
11
- export const Icon = ({ className, icon, size, onClick }) => {
12
- const classes = useStyle({ size });
13
- return (_jsx("div", Object.assign({ className: className, onClick: onClick }, { children: _jsx("svg", Object.assign({ className: classes.root, width: icon.width, height: icon.height, viewBox: `0 0 ${icon.width} ${icon.height}`, xmlns: "http://www.w3.org/2000/svg" }, { children: _jsx("path", { fillRule: "evenodd", clipRule: "evenodd", d: icon.svgPathData }, void 0) }), void 0) }), void 0));
14
- };
15
- export default Icon;
16
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/Icon/index.tsx"],"names":[],"mappings":";AACA,OAAO,EAAe,UAAU,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAC;AAgBrF,MAAM,QAAQ,GAAG,UAAU,CAA0B,GAAG,EAAE,CACxD,YAAY,CAAC;IACX,IAAI,EAAE,CAAC,EAAE,IAAI,EAAE,EAAE,EAAE,CAAC,CAAC;QACnB,IAAI,EAAE,cAAc;QACpB,MAAM,EAAE,IAAI,IAAI,SAAS;QACzB,KAAK,EAAE,MAAM;QACb,aAAa,EAAE,QAAQ;KACxB,CAAC;CACH,CAAC,CACH,CAAC;AAEF,MAAM,CAAC,MAAM,IAAI,GAAiC,CAAC,EAAE,SAAS,EAAE,IAAI,EAAE,IAAI,EAAE,OAAO,EAAa,EAAE,EAAE;IAClG,MAAM,OAAO,GAAG,QAAQ,CAAC,EAAE,IAAI,EAAE,CAAC,CAAC;IACnC,OAAO,CACL,4BAAK,SAAS,EAAE,SAAS,EAAE,OAAO,EAAE,OAAO,gBACzC,4BACE,SAAS,EAAE,OAAO,CAAC,IAAI,EACvB,KAAK,EAAE,IAAI,CAAC,KAAK,EACjB,MAAM,EAAE,IAAI,CAAC,MAAM,EACnB,OAAO,EAAE,OAAO,IAAI,CAAC,KAAK,IAAI,IAAI,CAAC,MAAM,EAAE,EAC3C,KAAK,EAAC,4BAA4B,gBAElC,eAAM,QAAQ,EAAC,SAAS,EAAC,QAAQ,EAAC,SAAS,EAAC,CAAC,EAAE,IAAI,CAAC,WAAW,WAAI,YAC/D,YACF,CACP,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,IAAI,CAAC"}
@@ -1,17 +0,0 @@
1
- import { Filter } from '../../types/Filter';
2
- import { TSelection } from '../../FilterProvider';
3
- export declare type RadioFilterContainerProps<TData> = {
4
- filter: Filter<TData, TSelection>;
5
- useSearch?: boolean;
6
- };
7
- /**
8
- *Standard Checkbox filter.
9
- *List out all options, and user can check of each item they want to filter on.
10
- *
11
- * @param filter Filter definition
12
- * @param useSearch Show a search bar at top, searching withing the filter options
13
- * @param style Add additional styling to the Filter container and header.
14
- */
15
- export declare const RadioFilter: <TSelections extends Record<string, any>, TData>({ filter, useSearch, }: RadioFilterContainerProps<TData>) => JSX.Element;
16
- export default RadioFilter;
17
- //# sourceMappingURL=RadioFilter.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"RadioFilter.d.ts","sourceRoot":"","sources":["../../../src/components/RadioFilter/RadioFilter.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAC;AAK5C,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAalD,oBAAY,yBAAyB,CAAC,KAAK,IAAI;IAC7C,MAAM,EAAE,MAAM,CAAC,KAAK,EAAE,UAAU,CAAC,CAAC;IAClC,SAAS,CAAC,EAAE,OAAO,CAAC;CACrB,CAAC;AAEF;;;;;;;GAOG;AAEH,eAAO,MAAM,WAAW,gHAGc,WAwDrC,CAAC;AAEF,eAAe,WAAW,CAAC"}
@@ -1,51 +0,0 @@
1
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
- import { useCallback, useEffect, useState } from 'react';
3
- import useFilterChangeHandler from '../../hooks/useFilterChangeHandler';
4
- import useFilterOptionsBuilder from '../../hooks/useFilterOptionsBuilder';
5
- import useFilterSelection from '../../hooks/useFilterSelection';
6
- import { TextInput } from '@equinor/fusion-react-textinput';
7
- import Radio from '@equinor/fusion-react-radio';
8
- import useStyles from './RadioFilter.style';
9
- import useFilterContext from '../../hooks/useFilterContext';
10
- const optionVisible = (option, searchString) => Boolean(searchString.length
11
- ? (option.searchString || option.label?.toString())
12
- ?.toLocaleLowerCase()
13
- .includes(searchString.toLocaleLowerCase())
14
- : true);
15
- /**
16
- *Standard Checkbox filter.
17
- *List out all options, and user can check of each item they want to filter on.
18
- *
19
- * @param filter Filter definition
20
- * @param useSearch Show a search bar at top, searching withing the filter options
21
- * @param style Add additional styling to the Filter container and header.
22
- */
23
- export const RadioFilter = ({ filter, useSearch, }) => {
24
- const context = useFilterContext();
25
- const store = context.store;
26
- const { key, title, filterFn, optionsBuilderFn, description } = filter;
27
- const [filterSearch, setFilterSearch] = useState('');
28
- const selectionUpdate = (change) => change.key;
29
- const handleChange = useFilterChangeHandler(key, selectionUpdate);
30
- const onChange = useCallback((key) => {
31
- setFilterSearch('');
32
- handleChange({ key: key || '' });
33
- }, [handleChange]);
34
- const filterOptions = useFilterOptionsBuilder(optionsBuilderFn);
35
- const currentOptionsSelection = useFilterSelection(key);
36
- useEffect(() => {
37
- filterFn && store.registerFilter(key, filterFn);
38
- store.registerFilterSettings(filter);
39
- return () => store.unRegisterFilter(key);
40
- }, [store, key, filterFn, filter]);
41
- const Styles = useStyles();
42
- const onSearchValueChange = (e) => setFilterSearch(e.currentTarget.value);
43
- return (_jsxs("div", Object.assign({ className: Styles.RadioFilterContainer }, { children: [_jsx("header", Object.assign({ className: Styles.FilterHeader, title: description }, { children: title }), void 0), useSearch && (_jsx(TextInput, { onInput: onSearchValueChange, value: filterSearch, placeholder: 'Search', type: 'search' }, void 0)), _jsx("div", Object.assign({ className: Styles.FilterOptionsContainer }, { children: filterOptions?.sortOrder?.map((key) => {
44
- const data = filterOptions.options[key];
45
- if (!optionVisible(data, filterSearch))
46
- return;
47
- return (_jsxs("div", Object.assign({ className: Styles.FilterOption, onClick: () => onChange(key) }, { children: [_jsx(Radio, { checked: currentOptionsSelection === key ? true : undefined }, void 0), _jsx("label", Object.assign({ className: Styles.FilterOptionLabel }, { children: data.label }), void 0)] }), key));
48
- }) }), void 0)] }), 'Radio' + title));
49
- };
50
- export default RadioFilter;
51
- //# sourceMappingURL=RadioFilter.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"RadioFilter.js","sourceRoot":"","sources":["../../../src/components/RadioFilter/RadioFilter.tsx"],"names":[],"mappings":";AAAA,OAAc,EAAE,WAAW,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAChE,OAAO,sBAAsB,MAAM,oCAAoC,CAAC;AACxE,OAAO,uBAAuB,MAAM,qCAAqC,CAAC;AAC1E,OAAO,kBAAkB,MAAM,gCAAgC,CAAC;AAGhE,OAAO,EAAE,SAAS,EAA8B,MAAM,iCAAiC,CAAC;AACxF,OAAO,KAAK,MAAM,6BAA6B,CAAC;AAChD,OAAO,SAAS,MAAM,qBAAqB,CAAC;AAG5C,OAAO,gBA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,MAAM,CAAC,iBAAiB,gBAAG,IAAI,CAAC,KAAK,YAAS,MAFxB,GAAG,CAGvC,CACP,CAAC;gBACJ,CAAC,CAAC,YACE,MApB0C,OAAO,GAAG,KAAK,CAqB3D,CACP,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,WAAW,CAAC"}
@@ -1,3 +0,0 @@
1
- declare const useStyles: (props?: {} | undefined) => import("@material-ui/styles").ClassNameMap<"FilterHeader" | "FilterOptionsContainer" | "RadioFilterContainer" | "FilterOption" | "FilterOptionLabel">;
2
- export default useStyles;
3
- //# sourceMappingURL=RadioFilter.style.d.ts.map