typedoc-plugin-markdown icon indicating copy to clipboard operation
typedoc-plugin-markdown copied to clipboard

Extra spaces when merging lines in a table

Open KillyMXI opened this issue 3 years ago • 1 comments

Updating packages:

-    "typedoc": "^0.22.15",
-    "typedoc-plugin-markdown": "^3.12.1",
+    "typedoc": "^0.23.10",
+    "typedoc-plugin-markdown": "^3.13.4",

Causes changes in generated tables:

 | Name | Type | Description |
 | :------ | :------ | :------ |
-| `column` | `number` | Column number within the line in the source string (1-based).  _(Always zero if line numbers not enabled in the lexer options.)_ |
-| `len` | `number` | The length of the matched substring.  _(Might be different from the text length in case replace value was used in a RegexRule.)_ |
-| `line` | `number` | Line number in the source string (1-based).  _(Always zero if not enabled in the lexer options.)_ |
+| `column` | `number` | Column number within the line in the source string (1-based).    _(Always zero if line numbers not enabled in the lexer options.)_ |
+| `len` | `number` | The length of the matched substring.    _(Might be different from the text length in case replace value  was used in a RegexRule.)_ |
+| `line` | `number` | Line number in the source string (1-based).    _(Always zero if not enabled in the lexer options.)_ |
 | `name` | `string` | Name of the rule produced this token. |
...

Namely, extra spaces where original type definition contained line breaks.

Previous behavior caused one extra space in case of empty line. New behavior caused 3 extra spaces in case of empty line and 1 extra space in case of line break. Previous behavior was pretty unnoticeable. The diff drawn my attention to it and now I find 4 spaces rather annoying even though not critical.

Looks like the way comment lines are extracted is changed and now it requires more trimming.

(Side note: I'd consider an option to insert single <br> in place of empty lines to preserve content separation, but that's not essential.)

KillyMXI avatar Aug 04 '22 10:08 KillyMXI

I'd consider an option to insert
in place of empty lines to preserve content separation

Thanks - not a bad idea i'll add to list.

tgreyuk avatar Aug 04 '22 21:08 tgreyuk

[email protected]

tgreyuk avatar May 03 '24 22:05 tgreyuk