Uploaded image for project: 'Jira Data Center'
  1. Jira Data Center
  2. JRASERVER-63798

Paste PDF into the editor from clipboard using Chrome does not work

    XMLWordPrintable

Details

    Description

      NOTE: This bug report is for JIRA Server. Using JIRA Cloud? See the corresponding bug report.

      Summary

      Paste PDF into the editor from clipboard using Chrome does not work.

      Environment

      • JIRA 1000.695.1 (Cloud), JIRA 7.3.0 (Server)
      • Chrome 55.0.2883.95
      • macOS Sierra

      Steps to Reproduce

      Scenario1

      1. Copy a PDF file in Finder.app
      2. Open a JIRA issue in edit mode
      3. Press Cmd + V in the editor

      Scenario2

      1. Open Terminal.app
      2. Execute the following commands
        $ defaults write com.apple.screencapture type pdf
        $ killall SystemUIServer
        
      1. Press Command + Control + Shift + 3 to capture a screenshot into the clipboard
      2. Open a JIRA issue in edit mode
      3. Press Cmd + V in the editor

      Expected Results

      The paste from the clipboard should work correctly in the both scenario.

      Actual Results

      Scenario1

      The PDF wasn't attached to the page and the filename is just pasted as a text.

      Scenario2

      The paste failed silently.
      If we monitor the step in developer tools, we can see the following JavaScript error.

      batch.js?acjsFiveVersionEnabled=true&agile_global_admin_condition=true&jag=true&jaguser=true&jira-n…:9238 Uncaught TypeError: Cannot read property 'slice' of undefined
          at Object.b.convertBlobToImage (batch.js?acjsFiveVersionEnabled=true&agile_global_admin_condition=true&jag=true&jaguser=true&jira-n…:9238)
          at batch.js?acjsFiveVersionEnabled=true&agile_global_admin_condition=true&jag=true&jaguser=true&jira-n…:9286
          at new D (batch.js?acjsFiveVersionEnabled=true&agile_global_admin_condition=true&jag=true&jaguser=true&jira-n…:9286)
          at batch.js?acjsFiveVersionEnabled=true&agile_global_admin_condition=true&jag=true&jaguser=true&jira-n…:9286
          at G (batch.js?acjsFiveVersionEnabled=true&agile_global_admin_condition=true&jag=true&jaguser=true&jira-n…:9286)
          at a (batch.js?acjsFiveVersionEnabled=true&agile_global_admin_condition=true&jag=true&jaguser=true&jira-n…:9286)
          at batch.js?acjsFiveVersionEnabled=true&agile_global_admin_condition=true&jag=true&jaguser=true&jira-n…:9286
          at dispatch (batch.js?locale=ja-JP:120)
          at h (batch.js?locale=ja-JP:112)
      

      When it comes to some of third-party apps, they try to store images as PDF when copying them into clipboard.
      That's why these scenario should be also considered.

      Notes

      This problem might be caused by this browser's spec.
      Even though we don't support pasting PDF from clipboard, it would be more user friendly if JIRA could show some error on the UI.

      Workaround

      Use the other browsers instead.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              yokamoto Yuki Okamoto (Inactive)
              Votes:
              1 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: