@evoke-platform/ui-components 1.1.0-testing.5 → 1.1.0-testing.6
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.
@@ -309,9 +309,10 @@ const CriteriaBuilder = (props) => {
|
|
309
309
|
const propertyType = properties.find((property) => property.id === rule.field)?.type;
|
310
310
|
let adjustedValue = rule.value;
|
311
311
|
if ((propertyType === 'array' ||
|
312
|
-
(propertyType === 'string'
|
312
|
+
((propertyType === 'string' || propertyType === 'richText') &&
|
313
|
+
(rule.operator === 'in' || rule.operator === 'notIn'))) &&
|
313
314
|
isSavedValue) {
|
314
|
-
adjustedValue = rule.value
|
315
|
+
adjustedValue = rule.value?.split(',');
|
315
316
|
}
|
316
317
|
else if ((rule.operator === 'null' || rule.operator === 'notNull') && rule.value) {
|
317
318
|
adjustedValue = null;
|
@@ -49,7 +49,6 @@ const ValueEditor = (props) => {
|
|
49
49
|
}
|
50
50
|
else if (['in', 'notIn'].includes(operator) && !Array.isArray(value)) {
|
51
51
|
handleOnChange([]);
|
52
|
-
setInputValue('');
|
53
52
|
}
|
54
53
|
}, [operator]);
|
55
54
|
if (context.disabledCriteria) {
|
@@ -182,7 +181,6 @@ const ValueEditor = (props) => {
|
|
182
181
|
inputValue &&
|
183
182
|
(options.some((option) => option.name === inputValue) || !options.length) &&
|
184
183
|
(operator === 'in' || operator === 'notIn')) {
|
185
|
-
event.preventDefault();
|
186
184
|
const newValues = Array.isArray(value) ? [...value, inputValue] : [inputValue];
|
187
185
|
handleOnChange(Array.from(new Set(newValues)));
|
188
186
|
setInputValue('');
|