summaryrefslogtreecommitdiff
path: root/src/Text/Pandoc/Readers/HTML/Table.hs
AgeCommit message (Collapse)Author
2023-08-05HTML reader: properly calculate RowHeadColumns.John MacFarlane
The previous algorithm did not handle rowspans; this one does. Closes #8984.
2023-08-05HTML reader: require unanimity for RowHeadColumns.John MacFarlane
Previously we used the max. #8634 switched to the min, but this had bad results. This commit sets the RowHeadColumns to the consensus value from all rows, or 0 if there is no consensus. See #8984.
2023-08-05HTML reader: fix bug in calculation of RowHeadColumns.John MacFarlane
We were adding up cells, not colspans. Note: there may still be incorrect results in the presence of rowspans. See https://github.com/jgm/pandoc/issues/8984#issuecomment-1666467926
2023-08-05Revert "Update TableBody RowHeadColumns caculation: change from max to min ↵John MacFarlane
(#8634)" This reverts commit f257c97170ba8db3b771135b98b198d5de2bdb5b. For the reason, see #8984. The change caused the "grid shape" of some tables to change.
2023-06-24Update TableBody RowHeadColumns caculation: change from max to min (#8634)Ruqi
This change sets RowHeadColumns to the minimum value of each row, which gives better results in cases where rows have different numbers of leading th tags.
2023-01-10Update copyright years, it's 2023!Albert Krewinkel
2022-01-02Copyright notices: update for 2022Albert Krewinkel
2021-09-23HTML reader: handle empty tbody element in table.John MacFarlane
Closes #7589.
2021-05-30HTML reader: fix column width regression.John MacFarlane
Column widths specified with a style attribute were off by a factor of 100 in 2.14. Closes #7334.
2021-05-22Handle relative lengths (e.g. `2*`) in HTML column widths.John MacFarlane
See <https://www.w3.org/TR/html4/types.html#h-6.6>. "A relative length has the form "i*", where "i" is an integer. When allotting space among elements competing for that space, user agents allot pixel and percentage lengths first, then divide up remaining available space among relative lengths. Each relative length receives a portion of the available space that is proportional to the integer preceding the "*". The value "*" is equivalent to "1*". Thus, if 60 pixels of space are available after the user agent allots pixel and percentage space, and the competing relative lengths are 1*, 2*, and 3*, the 1* will be alloted 10 pixels, the 2* will be alloted 20 pixels, and the 3* will be alloted 30 pixels." Closes #4063.
2021-05-22Revert "HTML reader: simplify col width parsing"John MacFarlane
This reverts commit f76fe2ab56606528d4710cc6c40bceb5788c3906.
2021-05-22HTML reader: simplify col width parsingAlbert Krewinkel
2021-03-19Protect partial uses of maximum with NonEmpty.John MacFarlane
2021-01-08Update copyright notices for 2021 (#7012)Albert Krewinkel
2020-11-27HTML reader tests: improve test coverage of new featuresAlbert Krewinkel
2020-11-27HTML reader: support body headers, row head columnsAlbert Krewinkel
Closes: #6312
2020-11-26HTML reader: improve support for table headers, footer, attributesAlbert Krewinkel
- `<tfoot>` elements are no longer added to the table body but used as table footer. - Separate `<tbody>` elements are no longer combined into one. - Attributes on `<thead>`, `<tbody>`, `<th>`/`<td>`, and `<tfoot>` elements are preserved.
2020-11-26HTML reader: allow finer grained options for tag omissionAlbert Krewinkel
2020-11-24HTML reader: support row or column-spanning table cellsAlbert Krewinkel
2020-11-24HTML reader: support blocks in captionAlbert Krewinkel
2020-11-24HTML reader: extract table parsing into separate moduleAlbert Krewinkel