(e, t = [])
| 1382 | return (this.inlineQueue.push({ src: e, tokens: t }), t); |
| 1383 | } |
| 1384 | inlineTokens(e, t = []) { |
| 1385 | let n = e, |
| 1386 | s = null; |
| 1387 | if (this.tokens.links) { |
| 1388 | let o = Object.keys(this.tokens.links); |
| 1389 | if (o.length > 0) |
| 1390 | for ( |
| 1391 | ; |
| 1392 | (s = this.tokenizer.rules.inline.reflinkSearch.exec(n)) != null; |
| 1393 | ) |
| 1394 | o.includes(s[0].slice(s[0].lastIndexOf("[") + 1, -1)) && |
| 1395 | (n = |
| 1396 | n.slice(0, s.index) + |
| 1397 | "[" + |
| 1398 | "a".repeat(s[0].length - 2) + |
| 1399 | "]" + |
| 1400 | n.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex)); |
| 1401 | } |
| 1402 | for ( |
| 1403 | ; |
| 1404 | (s = this.tokenizer.rules.inline.anyPunctuation.exec(n)) != null; |
| 1405 | ) |
| 1406 | n = |
| 1407 | n.slice(0, s.index) + |
| 1408 | "++" + |
| 1409 | n.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex); |
| 1410 | for (; (s = this.tokenizer.rules.inline.blockSkip.exec(n)) != null; ) |
| 1411 | n = |
| 1412 | n.slice(0, s.index) + |
| 1413 | "[" + |
| 1414 | "a".repeat(s[0].length - 2) + |
| 1415 | "]" + |
| 1416 | n.slice(this.tokenizer.rules.inline.blockSkip.lastIndex); |
| 1417 | let i = !1, |
| 1418 | r = ""; |
| 1419 | for (; e; ) { |
| 1420 | (i || (r = ""), (i = !1)); |
| 1421 | let o; |
| 1422 | if ( |
| 1423 | this.options.extensions?.inline?.some((c) => |
| 1424 | (o = c.call({ lexer: this }, e, t)) |
| 1425 | ? ((e = e.substring(o.raw.length)), t.push(o), !0) |
| 1426 | : !1, |
| 1427 | ) |
| 1428 | ) |
| 1429 | continue; |
| 1430 | if ((o = this.tokenizer.escape(e))) { |
| 1431 | ((e = e.substring(o.raw.length)), t.push(o)); |
| 1432 | continue; |
| 1433 | } |
| 1434 | if ((o = this.tokenizer.tag(e))) { |
| 1435 | ((e = e.substring(o.raw.length)), t.push(o)); |
| 1436 | continue; |
| 1437 | } |
| 1438 | if ((o = this.tokenizer.link(e))) { |
| 1439 | ((e = e.substring(o.raw.length)), t.push(o)); |
| 1440 | continue; |
| 1441 | } |
no test coverage detected