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

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

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.
Summary ID
Fix field serialization regression for text file attachment comments.
1d31e8f807a4c45ee2069bc881a1a203e5249e00
Description From Last Updated

The integer comparison is faster than the .is() check, so let's place that first. That'll let us return early if …

chipx86chipx86
david
  1. Ship It!
  2. 
      
chipx86
  1. 
      
  2. Show all issues

    The integer comparison is faster than the .is() check, so let's place that first. That'll let us return early if resizing vertically.

  3. 
      
maubin
Review request changed
Status:
Completed
Change Summary:
Pushed to release-7.x (637814b)