Files
ElyOffice/tasks/reviews/R4.8-r1.md
T
2026-10-14 15:56:47 -04:00

1.7 KiB

FAIL

  1. C:/Users/zhang/Documents/Github/Ely-GPUI-Components/src/documents/document/tables.rs:62 — Table rewrites mistake preceding text for a container prefix in CR-only documents. Reproduction: load Before\r\r| A | B |\r| - | - |\r| 1 | 2 |\r\rAfter\r, place the caret on 1, and call edit_table(TableEdit::Tidy). The LF-only prefix lookup captures Before\r\r; the writer repeats it before the delimiter and body rows, so Before occurs three times and the table is broken. This reproduces through the public document API; ElyMark's loader preserves bare CR. The writer also replaces internal CRLF endings with LF when supplied CRLF component text. This violates §14.3's content and line-ending preservation. Use CR/LF/CRLF-aware line boundaries for prefix detection and validation, and carry the table's line ending into the writer. Add public-API regressions for Tidy and moves with preceding content and these line endings. Evidence: .work/R4.8-r1-review/probes-public.log.

  2. C:/Users/zhang/Documents/Github/Ely-GPUI-Components/src/documents/document/tables.rs:197 — UnicodeWidthStr::width() does not match the stipulated Typora wcswidth for interior tabs. Reproduction: tidy | a\tb | x |\n| - | - |\n| q | r |\n. Typora's bundled function returns width 6 for a\tb (tabSize: 4), requiring a six-dash first delimiter and a six-column padded q cell. This writer produces | ---- | ---- | and pads the first column to four instead; the public document API reproduces it. Use the agreed width rules consistently for both column measurement and cell padding, with a regression containing an interior tab. Evidence: .work/R4.8-r1-review/typora-width.log and .work/R4.8-r1-review/probes-public.log.