I've noticed that some tables sometimes have an additional empty column at the end.
For example, the first table in our table guidance has another column after the "Jenkey" column. (In case that gets fixed soon, here is the archived version of the page.) The way tables are styled means that such an empty column is not visible.
This is how it looks with all the cells made visible:

It turns out that the reason why that happens is because there is an invisible non-breaking space at the end of one row.
(Not sure if this will have copied the space character correctly. It is not a normal space but a non-breaking space character. This character will most probably have come from copying and pasting from a Google Doc.)
Is there a way to fix this on the code level?
Whenever any kind of space follows the pipe and there are no other characters before the newline, presumably that should always be ignored.
If yes, is this repo the right place to fix this or should it be fixed in upstream Kramdown or via sanitising Publisher input?
I've noticed that some tables sometimes have an additional empty column at the end.
For example, the first table in our table guidance has another column after the "Jenkey" column. (In case that gets fixed soon, here is the archived version of the page.) The way tables are styled means that such an empty column is not visible.
This is how it looks with all the cells made visible:

It turns out that the reason why that happens is because there is an invisible non-breaking space at the end of one row.
(Not sure if this will have copied the space character correctly. It is not a normal space but a non-breaking space character. This character will most probably have come from copying and pasting from a Google Doc.)
Is there a way to fix this on the code level?
Whenever any kind of space follows the pipe and there are no other characters before the newline, presumably that should always be ignored.
If yes, is this repo the right place to fix this or should it be fixed in upstream Kramdown or via sanitising Publisher input?