@bigbinary/neeto-filters-frontend 2.9.5 → 2.9.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bigbinary/neeto-filters-frontend",
3
- "version": "2.9.5",
3
+ "version": "2.9.7",
4
4
  "description": "Manage filters across neeto products.",
5
5
  "author": "BigBinary",
6
6
  "license": "MIT",
@@ -47,7 +47,7 @@
47
47
  "@babel/runtime": "^7.19.0",
48
48
  "@bigbinary/eslint-plugin-neeto": "^1.0.21",
49
49
  "@bigbinary/neeto-commons-frontend": "^2.0.67",
50
- "@bigbinary/neeto-icons": "1.9.12",
50
+ "@bigbinary/neeto-icons": "^1.11.0",
51
51
  "@bigbinary/neeto-molecules": "^1.0.19",
52
52
  "@bigbinary/neetoui": "4.4.0",
53
53
  "@emotion/is-prop-valid": "1.2.0",
package/types.d.ts CHANGED
@@ -1,3 +1,4 @@
1
+ import React from "react";
1
2
  import { ButtonProps, PaneProps } from "@bigbinary/neetoui";
2
3
 
3
4
  interface labelAndValue {
@@ -28,7 +29,8 @@ interface KeywordType {
28
29
 
29
30
  type condition = {
30
31
  node: string;
31
- rule: "contains"
32
+ rule:
33
+ | "contains"
32
34
  | "does_not_contain"
33
35
  | "is"
34
36
  | "is_not"
@@ -42,7 +44,8 @@ type condition = {
42
44
  | "before"
43
45
  | "after"
44
46
  | "between";
45
- type: "date"
47
+ type:
48
+ | "date"
46
49
  | "single_date"
47
50
  | "time"
48
51
  | "single_time"
@@ -56,45 +59,45 @@ type condition = {
56
59
  model?: string;
57
60
  hidden?: boolean;
58
61
  [otherProps: string]: any;
59
- }
62
+ };
60
63
 
61
64
  type filters = {
62
65
  conditions: condition[];
63
66
  [otherProps: string]: any;
64
- }
67
+ };
65
68
 
66
69
  type selectors = {
67
70
  [key: string]: any;
68
71
  };
69
72
 
70
- export function Filters(
71
- props: {
72
- isOpen: boolean;
73
- setIsOpen: (boolean) => void;
74
- columns: ColumnType[];
75
- onChange: (filters: filters) => void;
76
- onSelectorsChange?: (selectors: selectors) => void;
77
- buttonProps?: ButtonProps;
78
- paneProps?: PaneProps;
79
- isSearchable?: boolean;
80
- className?: string;
81
- keyword?: KeywordType;
82
- [otherProps: string]: any;
83
- }
84
- ): JSX.Element;
73
+ export function Filters(props: {
74
+ isOpen: boolean;
75
+ setIsOpen: (boolean) => void;
76
+ columns: ColumnType[];
77
+ onChange: (filters: filters) => void;
78
+ onSelectorsChange?: (selectors: selectors) => void;
79
+ buttonProps?: ButtonProps;
80
+ paneProps?: PaneProps;
81
+ isSearchable?: boolean;
82
+ className?: string;
83
+ keyword?: KeywordType;
84
+ children?: React.ReactNode;
85
+ [otherProps: string]: any;
86
+ }): JSX.Element;
85
87
 
86
- export function Bar(
87
- props: {
88
- setIsPaneOpen: (boolean) => void;
89
- columns: ColumnType[];
90
- keyword?: KeywordType;
91
- className?: string;
92
- onChange: (filters: filters) => void;
93
- onSelectorsChange?: (selectors: selectors) => void;
94
- [otherProps: string]: any;
95
- }
96
- ): JSX.Element;
88
+ export function Bar(props: {
89
+ setIsPaneOpen: (boolean) => void;
90
+ columns: ColumnType[];
91
+ keyword?: KeywordType;
92
+ className?: string;
93
+ onChange: (filters: filters) => void;
94
+ onSelectorsChange?: (selectors: selectors) => void;
95
+ children?: React.ReactNode;
96
+ [otherProps: string]: any;
97
+ }): JSX.Element;
97
98
 
98
- export function buildFiltersFromURL(columns: Array<ColumnType | KeywordType>): filters[];
99
+ export function buildFiltersFromURL(
100
+ columns: Array<ColumnType | KeywordType>
101
+ ): filters[];
99
102
 
100
103
  export function buildSelectorsFromURL(columns: Array<ColumnType>): selectors;