54 lines
2.7 KiB
TypeScript
54 lines
2.7 KiB
TypeScript
/* Metro module 9679; source: modules/search/tokens/SearchTokensUtils.tsx; dependencies: [4100, 2] */
|
|
import RegexUtils from '../../../utils/RegexUtils.tsx'; /* Metro dependency 4100 */
|
|
import * as FileImportTrackerModule from '../../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
|
|
|
|
function _fun76034(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#76034, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9865:6, offset: 0x01dc2247, size: 152 bytes, params: 8, frame: 17
|
|
const Object = global.Object;
|
|
Object.defineProperty(exports, '__esModule', {value: true});
|
|
(FileImportTrackerModule).fileFinishedImporting('modules/search/tokens/SearchTokensUtils.tsx');
|
|
exports.ANSWER_IN_REGEX = RegExp('(?:\\s*#?((?:"(\\\\\\\\|\\\\"|[^\\\\"])*")|(?:[^\\s]+)))', 'i');
|
|
exports.GENERIC_REGEX = RegExp('(?:\\s*([^\\s]+))', '');
|
|
exports.makeRegexForOptionsWithNegation = makeRegexForOptionsWithNegation;
|
|
exports.validateForMapWithNegation = function(a0, a1, a2) {
|
|
var r2;
|
|
var r0;
|
|
var value = a2.getMatch(1);
|
|
var value2 = value.startsWith('-');
|
|
if (value2) {
|
|
value = value.slice(1);
|
|
r2 = value;
|
|
} else {
|
|
r2 = value;
|
|
}
|
|
var property = a1[r2];
|
|
r0 = property != null && property !== '';
|
|
if (r0) {
|
|
a2.setData(a0, value2 ? '-' + property : property);
|
|
r0 = true;
|
|
}
|
|
return r0;
|
|
};
|
|
function makeRegexForOptionsWithNegation(a0) { // fn#76035, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9865:306, offset: 0x01dc22df, size: 130 bytes, params: 2, frame: 15
|
|
const items2 = [];
|
|
arraySpread(items2, a0, 0, undefined);
|
|
let value = items2.sort(function(a0, {length}) {
|
|
return length - a0.length;
|
|
});
|
|
const RegExp = global.RegExp;
|
|
value = value.map(_fun76037);
|
|
value = value.join('|');
|
|
value = '(?:\\s*(-?(?:' + value + ')))';
|
|
const value2 = Object.create(RegExp.prototype, {constructor: {value: RegExp}});
|
|
const regExp = new RegExp(value, 'i');
|
|
return regExp instanceof Object ? regExp : value2;
|
|
function _fun76037(a0) { // fn#76037, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:9865:437, offset: 0x01dc2361, size: 40 bytes, params: 2, frame: 11
|
|
const value = environment.__proto__;
|
|
return (RegexUtils).escape(a0);
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
global.__d(_fun76034, 9679, [4100, 2]) /* metro module 9679, dependencies: [4100, 2] */;
|