@hortiview/shared-components 0.0.7520 → 0.0.7554

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 (41) hide show
  1. package/dist/assets/genericCard.css +1 -1
  2. package/dist/components/AlertBanner/AlertBanner.test.js +1 -1
  3. package/dist/components/BaseView/BaseView.test.js +1 -1
  4. package/dist/components/BasicHeading/BasicHeading.test.js +1 -1
  5. package/dist/components/BlockView/BlockView.test.js +1 -1
  6. package/dist/components/ContextMenu/ContextMenu.test.js +1 -1
  7. package/dist/components/DeleteModal/DeleteModal.test.js +1 -1
  8. package/dist/components/Disclaimer/Disclaimer.test.js +1 -1
  9. package/dist/components/EmptyView/EmptyView.test.js +1 -1
  10. package/dist/components/Filter/Filter.js +98 -82
  11. package/dist/components/Filter/Filter.test.js +29 -15
  12. package/dist/components/FormComponents/FormCheckBox/FormCheckBox.test.js +1 -1
  13. package/dist/components/FormComponents/FormDatePicker/FormDatePicker.test.js +1 -1
  14. package/dist/components/FormComponents/FormRadio/FormRadio.test.js +1 -1
  15. package/dist/components/FormComponents/FormSelect/FormSelect.test.js +2 -2
  16. package/dist/components/FormComponents/FormSlider/FormSlider.test.js +1 -1
  17. package/dist/components/FormComponents/FormText/FormText.test.js +1 -1
  18. package/dist/components/GenericTable/GenericTable.js +1 -1
  19. package/dist/components/GenericTable/GenericTable.test.js +1 -1
  20. package/dist/components/GenericTable/Mobile/GenericCard.js +21 -20
  21. package/dist/components/GenericTable/Mobile/GenericCard.test.js +1 -1
  22. package/dist/components/GenericTable/Mobile/GenericCardList.js +1 -1
  23. package/dist/components/GenericTable/Mobile/GenericCardList.test.js +1 -4
  24. package/dist/components/HashTabView/HashTabView.test.js +1 -1
  25. package/dist/components/HeaderFilter/HeaderFilter.test.js +1 -1
  26. package/dist/components/Iconify/Iconify.test.js +1 -1
  27. package/dist/components/InfoGroup/InfoGroup.test.js +1 -1
  28. package/dist/components/ListArea/ListArea.test.js +1 -1
  29. package/dist/components/LoadingSpinner/Big/BigLoadingSpinner.test.js +1 -1
  30. package/dist/components/LoadingSpinner/Default/LoadingSpinner.test.js +1 -1
  31. package/dist/components/OverflowTooltip/OverflowTooltip.test.js +2 -2
  32. package/dist/components/Scrollbar/scrollbar.test.js +1 -1
  33. package/dist/components/SearchBar/SearchBar.test.js +1 -1
  34. package/dist/components/VerticalDivider/VerticalDivider.test.js +1 -1
  35. package/dist/genericCard.module-k0bicNfi.js +15 -0
  36. package/dist/hooks/useBreakpoints.test.js +1 -1
  37. package/dist/{index-DW4oU_OU.js → index-BF3ufhvD.js} +1 -1
  38. package/dist/{react.esm-Dy4VzU4L.js → react.esm-CCrewPgi.js} +1743 -1736
  39. package/dist/types/Filter.d.ts +34 -10
  40. package/package.json +1 -1
  41. package/dist/genericCard.module-CnQn6tMH.js +0 -14
@@ -1,15 +1,28 @@
1
+ type FilterDataCommon = {
2
+ id: string;
3
+ title: string;
4
+ icon?: string;
5
+ };
6
+ type FilterDataType = {
7
+ type: 'select';
8
+ /**
9
+ * Available options for the filter
10
+ */
11
+ availableOptions: FilterOption[];
12
+ } | {
13
+ type: 'toggle';
14
+ availableOptions?: never;
15
+ } | {
16
+ type: 'search';
17
+ availableOptions?: never;
18
+ };
1
19
  /**
2
20
  * Filter data type
3
21
  * @param id - filter id (unique)
4
22
  * @param title - filter title
5
23
  * @param availableOptions - available options for the filter
6
24
  */
7
- export type FilterData = {
8
- id: string;
9
- title: string;
10
- icon?: string;
11
- availableOptions: FilterOption[];
12
- };
25
+ export type FilterData = FilterDataCommon & FilterDataType;
13
26
  /**
14
27
  * Filter option data type
15
28
  * @param id - option id (unique)
@@ -21,12 +34,23 @@ export type FilterOption = {
21
34
  text: string;
22
35
  icon?: string;
23
36
  };
37
+ type FilterSelectionCommon = {
38
+ id: string;
39
+ };
40
+ type FilterSelectionType = {
41
+ type: 'select';
42
+ filterValue: FilterOption[];
43
+ } | {
44
+ type: 'toggle';
45
+ filterValue: boolean;
46
+ } | {
47
+ type: 'search';
48
+ filterValue: string | undefined;
49
+ };
24
50
  /**
25
51
  * Filter selection data type
26
52
  * @param id - filter id (unique)
27
53
  * @param selectedOptions - selected options of the filter (multiple)
28
54
  */
29
- export type FilterSelection = {
30
- id: string;
31
- selectedOptions: FilterOption[];
32
- };
55
+ export type FilterSelection = FilterSelectionCommon & FilterSelectionType;
56
+ export {};
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@hortiview/shared-components",
3
3
  "description": "This is a shared component library. It should used in the HortiView platform and its modules.",
4
- "version": "0.0.7520",
4
+ "version": "0.0.7554",
5
5
  "type": "module",
6
6
  "repository": "https://dev.azure.com/sdundc/HV%20Platform/_git/HortiView-Frontend-Shared",
7
7
  "author": "Falk Menge <falk.menge.ext@bayer.com>",
@@ -1,14 +0,0 @@
1
- import "./assets/genericCard.css";
2
- const t = "_cardTitle_a6o2v_1", o = "_cardBody_a6o2v_5", n = "_cardContent_a6o2v_10", _ = "_row_a6o2v_14", a = "_font_a6o2v_18", e = "_title_a6o2v_26", c = "_emptyContainer_a6o2v_34", r = "_empty_a6o2v_34", d = {
3
- cardTitle: t,
4
- cardBody: o,
5
- cardContent: n,
6
- row: _,
7
- font: a,
8
- title: e,
9
- emptyContainer: c,
10
- empty: r
11
- };
12
- export {
13
- d as s
14
- };