give names to complex slices
This commit is contained in:
parent
b02a30a2fd
commit
84f30113e4
@ -107,10 +107,11 @@ function jpDistributeFuriganaInflected(expression, reading, source) {
|
|||||||
}
|
}
|
||||||
const offset = source.length - stemLength;
|
const offset = source.length - stemLength;
|
||||||
|
|
||||||
for (const segment of jpDistributeFurigana(
|
const stemExpression = source.slice(0, source.length - offset);
|
||||||
source.slice(0, offset === 0 ? source.length : source.length - offset),
|
const stemReading = reading.slice(
|
||||||
reading.slice(0, offset === 0 ? reading.length : reading.length - expression.length + stemLength)
|
0, offset === 0 ? reading.length : reading.length - expression.length + stemLength
|
||||||
)) {
|
);
|
||||||
|
for (const segment of jpDistributeFurigana(stemExpression, stemReading)) {
|
||||||
output.push(segment);
|
output.push(segment);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user