Fix field serialization regression and UI bug for text-based file attachment comments.

Review Request #13928 — Created June 4, 2024 and submitted — Latest diff uploaded

Information

Review Board
release-7.x

Reviewers

This change contains two fixes for text-based file attachment comments.

First, we had a regression in our parsing of serialized fields. We weren't
including the viewMode attribute in our parsed results, so it would always
be null and comments wouldn't be displayed.

Second, when building the comment bubbles that appear on the line numbers of a
file, we wouldn't properly calculate the comment bubble height for comments
that are on the view mode that is not currently visible. Now we bail if the
view mode for the comment isn't visible, and only calculate if its visible.

  • Ran JS unit tests.
  • Created and viewed existing comments on a Markdown file, saw that comment
    sizes were properly calculated.
  • Created and viewed existing comments on a .txt file, saw that comment
    sizes were properly calculated.

Commits

Files