Add a JavaScript hook for extending the File Attachment thumbnail container UI.

Review Request #12951 — Created April 19, 2023 and submitted

Information

Review Board
release-6.x

Reviewers

This adds a JavaScript hook for extending the File Attachment thumbnail
container UI. The hook can be used to display additional content on
file attachment thumbnails and in the file attachment actions menu.

This also adds a method to the File Attachment thumbnail view that allows
callers to add an action to the file attachment actions menu.

  • Ran JS unit tests.
  • Ran unit tests.
  • Manually tested with the new "Download as PDF" action that's being added in
    in Power Pack.
  • Manually tested with a simple extension and view, the one in the example
    in the docs.
  • Built the docs and made sure they look ok.
Summary ID
Add a JavaScript hook for extending the File Attachment thumbnail UI.
6f449b1cf964645cc794bcf7207e5da520f664b7
Description From Last Updated

Missing semicolon. Column: 11 Error code: W033

reviewbotreviewbot

Missing semicolon. Column: 12 Error code: W033

reviewbotreviewbot

Missing semicolon. Column: 34 Error code: W033

reviewbotreviewbot

line too long (87 > 79 characters) Column: 80 Error code: E501

reviewbotreviewbot

I think it would be nicer to use a template literal here instead of +

daviddavid

Let's call this $appendItem. It would also be nicer to use a template literal here instead of +

daviddavid

line too long (87 > 79 characters) Column: 80 Error code: E501

reviewbotreviewbot

'$appendItem' is defined but never used. Column: 15 Error code: W098

reviewbotreviewbot

line too long (87 > 79 characters) Column: 80 Error code: E501

reviewbotreviewbot

The ==== lines should be the same width as the name

daviddavid

Let's sort these alphabetically.

daviddavid

Sort alphabetically.

daviddavid

Sort alphabetically.

daviddavid

Sort alphabetically.

daviddavid

line too long (87 > 79 characters) Column: 80 Error code: E501

reviewbotreviewbot

line too long (87 > 79 characters) Column: 80 Error code: E501

reviewbotreviewbot
Checks run (2 failed)
flake8 failed.
JSHint failed.

flake8

JSHint

maubin
Review request changed

Checks run (1 failed, 1 succeeded)

flake8 failed.
JSHint passed.

flake8

david
  1. 
      
  2. Show all issues

    I think it would be nicer to use a template literal here instead of +

  3. Show all issues

    Let's call this $appendItem. It would also be nicer to use a template literal here instead of +

  4. 
      
maubin
Review request changed

Checks run (2 failed)

flake8 failed.
JSHint failed.

flake8

JSHint

maubin
Review request changed

Checks run (1 failed, 1 succeeded)

flake8 failed.
JSHint passed.

flake8

david
  1. 
      
  2. Show all issues

    The ==== lines should be the same width as the name

  3. Show all issues

    Let's sort these alphabetically.

  4. Show all issues

    Sort alphabetically.

  5. Show all issues

    Sort alphabetically.

  6. Show all issues

    Sort alphabetically.

  7. 
      
maubin
Review request changed

Checks run (1 failed, 1 succeeded)

flake8 failed.
JSHint passed.

flake8

david
  1. Ship It!
  2. 
      
maubin
Review request changed

Status: Closed (submitted)

Change Summary:

Pushed to release-6.x (44e44e7)
Loading...