@netgrif/components-core 6.2.8 → 6.2.9

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.
@@ -9473,7 +9473,7 @@ class Substring extends Operator {
9473
9473
  // TODO IMPROVEMENT 27.4.2020 - we could use regular expressions to search for substrings which would solve the unintuitive
9474
9474
  // behavior that occurs when we search for strings that contain spaces. We need to escape the input string in a special way
9475
9475
  // if we choose to do this
9476
- const escapedValue = Operator.escapeInput(args[0]).value.replace(' ', '\\ ');
9476
+ const escapedValue = Operator.escapeInput(args[0]).value.replace(/ /g, '\\ ');
9477
9477
  return Operator.forEachKeyword(elasticKeywords, keyword => new Query(`(${keyword}:*${escapedValue}*)`));
9478
9478
  }
9479
9479
  getOperatorNameTemplate() {
@@ -12903,7 +12903,7 @@ class SearchService {
12903
12903
  * @param searchedSubstring value that should be searched on all full text fields
12904
12904
  */
12905
12905
  setFullTextFilter(searchedSubstring) {
12906
- const whiteSpacedSubstring = searchedSubstring.replace(' ', '\\ ');
12906
+ const whiteSpacedSubstring = searchedSubstring.replace(/ /g, '\\ ');
12907
12907
  this._fullTextFilter = new SimpleFilter('', this._baseFilter.type, { fullText: whiteSpacedSubstring });
12908
12908
  this.updateActiveFilter();
12909
12909
  }