Try to fix quotes in Global Search.

Thanks to xet7 !

Related https://github.com/wekan/wekan/pull/3492
This commit is contained in:
Lauri Ojansivu 2021-01-28 17:51:35 +02:00
parent ff787bb6ca
commit 0ff215f78f

View file

@ -190,10 +190,10 @@ BlazeComponent.extendComponent({
this.searching.set(true);
const reOperator1 = /^((?<operator>[\p{Letter}\p{Mark}]+):|(?<abbrev>[#@]))(?<value>[\p{Letter}\p{Mark}]+)(\s+|$)/iu;
const reOperator2 = /^((?<operator>[\p{Letter}\p{Mark}]+):|(?<abbrev>[#@]))(?<quote>["']*)(?<value>.*?)\k<quote>(\s+|$)/iu;
const reText = /^(?<text>\S+)(\s+|$)/u;
const reQuotedText = /^(?<quote>["'])(?<text>[\w\p{L}]+)\k<quote>(\s+|$)/u;
const reOperator1 = `/^((?<operator>[\p{Letter}\p{Mark}]+):|(?<abbrev>[#@]))(?<value>[\p{Letter}\p{Mark}]+)(\s+|$)/iu`;
const reOperator2 = `/^((?<operator>[\p{Letter}\p{Mark}]+):|(?<abbrev>[#@]))(?<quote>["']*)(?<value>.*?)\k<quote>(\s+|$)/iu`;
const reText = `/^(?<text>\S+)(\s+|$)/u`;
const reQuotedText = `/^(?<quote>["'])(?<text>[\w\p{L}]+)\k<quote>(\s+|$)/u`;
const operators = {
'operator-board': 'boards',