@koda-sl/baker-cli 0.436.0-dev.17d582030 → 0.436.0-dev.7e3937022
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.
- package/dist/cli.js +1 -5
- package/dist/cli.js.map +1 -1
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -71163,9 +71163,6 @@ var QUOTED_RUN = 5;
|
|
|
71163
71163
|
var SIGNING_ROLE = /^(attribution|author|byline|name|reviewer|source|signature)$/i;
|
|
71164
71164
|
var SIGNED = /(?:^\s*|[\p{Pf}\p{Pe}"'.!?…。!?]\s*)[—–―-]\s*[\p{L}\p{N}]/u;
|
|
71165
71165
|
var QUOTE_ROLE = /^(quote|testimonial|review)$/i;
|
|
71166
|
-
function isSignatureLine(line) {
|
|
71167
|
-
return SIGNING_ROLE.test(line.role ?? "") || /^\s*[—–―-]\s*[\p{L}\p{N}]/u.test(line.text);
|
|
71168
|
-
}
|
|
71169
71166
|
function isCustomersWords(line) {
|
|
71170
71167
|
return SIGNED.test(line.text) || QUOTE_ROLE.test(line.role ?? "") || SIGNING_ROLE.test(line.role ?? "");
|
|
71171
71168
|
}
|
|
@@ -88379,8 +88376,7 @@ async function customersWordsAmong(lines, judge) {
|
|
|
88379
88376
|
const open = [];
|
|
88380
88377
|
lines.forEach((line, i) => {
|
|
88381
88378
|
if (line.role === MESSAGE_ROLE) return;
|
|
88382
|
-
|
|
88383
|
-
if (isCustomersWords(line) || below !== void 0 && isSignatureLine(below)) kept.add(i);
|
|
88379
|
+
if (isCustomersWords(line)) kept.add(i);
|
|
88384
88380
|
else open.push(i);
|
|
88385
88381
|
});
|
|
88386
88382
|
if (!judge || open.length === 0) return kept;
|