The old version of EntityIndex::best_info manipulated the text of spans without alterting the associated link offsets. To do this would be convoluted when having to consider '•', so instead we do not replace '*' with '•' any longer, but only strip the prefix of '*' and whitespace and then subtract the removed prefix length from all link offsets. When rendering the snippets on the frontend, we perform the '*' replacement since the index have been made into snippets and the text is thus free to change.
The old version of
EntityIndex::best_info
manipulated the text of spans without alterting the associated link offsets. To do this would be convoluted when having to consider'•'
, so instead we do not replace'*'
with'•'
any longer, but only strip the prefix of'*'
and whitespace and then subtract the removed prefix length from all link offsets. When rendering the snippets on the frontend, we perform the'*'
replacement since the index have been made into snippets and the text is thus free to change.