-
Notifications
You must be signed in to change notification settings - Fork 8
Description
What version of Tesseract has this bug?
1.4.31
Describe the bug
The post body preview length is counting (and trimming) raw input instead of visible text after applying markdown and link tags.
This results in either very short previews or broken rendering because the markdown tag is broken off midway or the closing tag is missing.
I think the issue is it currently does something along the lines of:
Raw input > trim > apply markup > output
instead of:
Raw input > apply markup > trim > output
To Reproduce
Steps to reproduce the behaviour:
- Configure Tesseract setting "Post Body Preview Length" to 120
- View a feed with "view type" set to hybrid or compact.
- Notice several posts have broken markdown / link tags showing in the body preview & other posts only preview very few words when a link is involved.
- Also notice expanding the preview fixes the broken markup.
Expected behaviour
Links and other markdown code is applied to text before counting the length and cutting it short.
In other words: show 120 rendered characters instead of 120 characters of raw input.
Screenshots
Link broken midway:
Very few words in preview when a link is involved (link url is counted towards length instead of only counting the link text):
Markdown broken due to cut-off:
Desktop (please complete the following information):
- OS: Windows 11
- Browser: Zen Browser (Firefox)
- Version: 1.9b (136.0)