@beabee/beabee-common 1.12.3 → 1.13.1
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/dist/cjs/search/callouts.js +1 -1
- package/dist/cjs/search/index.js +1 -6
- package/dist/cjs/utils/callouts.js +2 -0
- package/dist/esm/search/callouts.js +1 -1
- package/dist/esm/search/index.js +1 -6
- package/dist/esm/utils/callouts.js +2 -0
- package/dist/types/search/callouts.d.ts +1 -1
- package/dist/types/search/index.d.ts +9 -1
- package/package.json +1 -1
package/dist/cjs/search/index.js
CHANGED
|
@@ -64,18 +64,13 @@ exports.nullableOperators = {
|
|
|
64
64
|
};
|
|
65
65
|
exports.operatorsByType = {
|
|
66
66
|
text: { ...equalityOperators, ...arrayOperators, ...stringOperators },
|
|
67
|
+
blob: arrayOperators,
|
|
67
68
|
date: numericOperators,
|
|
68
69
|
number: numericOperators,
|
|
69
70
|
boolean: { equal: equalityOperators.equal },
|
|
70
71
|
array: arrayOperators,
|
|
71
72
|
enum: equalityOperators,
|
|
72
73
|
contact: equalityOperators,
|
|
73
|
-
// custom: {
|
|
74
|
-
// ...equalityOperators,
|
|
75
|
-
// ...arrayOperators,
|
|
76
|
-
// ...stringOperators,
|
|
77
|
-
// ...numericOperators,
|
|
78
|
-
// },
|
|
79
74
|
};
|
|
80
75
|
// More general type to allow mapping while maintaining full type above
|
|
81
76
|
exports.operatorsByTypeMap = exports.operatorsByType;
|
|
@@ -34,6 +34,8 @@ function convertComponentToFilter(component) {
|
|
|
34
34
|
type: component.type === "radio" ? "enum" : "array",
|
|
35
35
|
options: convertValuesToOptions(component.values),
|
|
36
36
|
};
|
|
37
|
+
case "textarea":
|
|
38
|
+
return { ...baseItem, type: "blob" };
|
|
37
39
|
default:
|
|
38
40
|
return { ...baseItem, type: "text" };
|
|
39
41
|
}
|
package/dist/esm/search/index.js
CHANGED
|
@@ -47,18 +47,13 @@ export const nullableOperators = {
|
|
|
47
47
|
};
|
|
48
48
|
export const operatorsByType = {
|
|
49
49
|
text: { ...equalityOperators, ...arrayOperators, ...stringOperators },
|
|
50
|
+
blob: arrayOperators,
|
|
50
51
|
date: numericOperators,
|
|
51
52
|
number: numericOperators,
|
|
52
53
|
boolean: { equal: equalityOperators.equal },
|
|
53
54
|
array: arrayOperators,
|
|
54
55
|
enum: equalityOperators,
|
|
55
56
|
contact: equalityOperators,
|
|
56
|
-
// custom: {
|
|
57
|
-
// ...equalityOperators,
|
|
58
|
-
// ...arrayOperators,
|
|
59
|
-
// ...stringOperators,
|
|
60
|
-
// ...numericOperators,
|
|
61
|
-
// },
|
|
62
57
|
};
|
|
63
58
|
// More general type to allow mapping while maintaining full type above
|
|
64
59
|
export const operatorsByTypeMap = operatorsByType;
|
|
@@ -30,6 +30,8 @@ function convertComponentToFilter(component) {
|
|
|
30
30
|
type: component.type === "radio" ? "enum" : "array",
|
|
31
31
|
options: convertValuesToOptions(component.values),
|
|
32
32
|
};
|
|
33
|
+
case "textarea":
|
|
34
|
+
return { ...baseItem, type: "blob" };
|
|
33
35
|
default:
|
|
34
36
|
return { ...baseItem, type: "text" };
|
|
35
37
|
}
|
|
@@ -26,7 +26,7 @@ export interface ValidatedRuleGroup<Field extends string> {
|
|
|
26
26
|
condition: "AND" | "OR";
|
|
27
27
|
rules: (ValidatedRuleGroup<Field> | ValidatedRule<Field>)[];
|
|
28
28
|
}
|
|
29
|
-
export type FilterType = "text" | "date" | "number" | "boolean" | "array" | "enum" | "contact";
|
|
29
|
+
export type FilterType = "text" | "blob" | "date" | "number" | "boolean" | "array" | "enum" | "contact";
|
|
30
30
|
interface BaseFilterArgs {
|
|
31
31
|
type: FilterType;
|
|
32
32
|
nullable?: boolean;
|
|
@@ -83,6 +83,14 @@ export declare const operatorsByType: {
|
|
|
83
83
|
args: number;
|
|
84
84
|
};
|
|
85
85
|
};
|
|
86
|
+
readonly blob: {
|
|
87
|
+
contains: {
|
|
88
|
+
args: number;
|
|
89
|
+
};
|
|
90
|
+
not_contains: {
|
|
91
|
+
args: number;
|
|
92
|
+
};
|
|
93
|
+
};
|
|
86
94
|
readonly date: {
|
|
87
95
|
between: {
|
|
88
96
|
args: number;
|