Add some polish to file attachment switching.

Review Request #229 - Created Dec. 19, 2016 and updated

guest9016
Review Board
3fa2ed9...
guest1041, guest1048
This change does a few small things to polish up the next/previous file
attachments feature:

- Instead of just relying on `FileAttachment.__str__`, we use the
  `display_name` property for the caption. This will fall back on the filename
  if no caption has been set.
- The style for the next/previous switchers had a huge font size set, which
  looked kind of goofy and didn't match what we had in the review request box.
- We have a "dummy" file review UI for file attachments that aren't reviewable.
  This had some code to set the caption in the review UI header in the case
  where we were looking at a diff, but didn't set the caption when there was
  only a single revision.

  This dummy review UI is still pretty dumb, and should probably have some
  indication that the file can't be displayed inline, along with a download
  link, but that can come in some later change.

Testing done:
Switched around file attachments and saw that things looked better.

Reviewed at https://reviews.reviewboard.org/r/8574/

  
  • 2
  • 0
  • 0
  • 2
Description From Last Updated
use other guest4920 guest4920
RAfa?, zjeba?e? ;_; guest1326 guest1326
guest1326
  1. 
      
  2. RAfa?, zjeba?e? ;_;

  3. 
      
guest4920
  1. Test header

  2. reviewboard/templates/reviews/ui/base.html (Diff revision 1)
     
     
     
     
     

    use other

  3. 
      
Loading...