Uploaded image for project: 'Atlassian Ecosystem'
  1. Atlassian Ecosystem
  2. ECO-6

JavaScript API doesn't work if Jira runs in iframe itself

    • Minor
    • 3

      Created from https://ecosystem.atlassian.net/browse/ACJIRA-2613

      Issue Summary

      Our customers want to embed our Jira app’s UI into Confluence pages. To do so, they add an iframe using Confluence’s built-in iframe macro, pointing to the respective Jira URL (e.g. https://foo.atlassian.net/projects/FOO?selectedItem=com.atlassian.plugins.atlassian-connect-plugin:app.jxl).

      In this setup, the Connect JavaScript API - while being loaded seemingly successfully - doesn’t work; the various callbacks, like window.AP.getCurrentUser, simply never resolve.

       

      To verify, call

      window.AP.getCurrentUser((x) => console.log(x));

       

      from the Connect iframe's console. It works if Jira runs in its own browser window, but doesn’t resolve if Jira runs within the iframe.

      There's suspicion that Connect gets confused about to the two nested iframes: First, Jira in Confluence, and then our app in Jira.

      Steps to Reproduce

      1. Confluence’s built-in iframe macro, pointing to the respective Jira URL (e.g. https://foo.atlassian.net/projects/FOO?selectedItem=com.atlassian.plugins.atlassian-connect-plugin:app.jxl).
      2. Call from the Connect iframe's console:
        window.AP.getCurrentUser((x) => console.log(x));

      Expected Results

      It resolves within Jira iframe.

      Actual Results

      It doesn’t resolve if Jira runs within the iframe. 

      Workaround

      Currently there is no known workaround for this behavior. A workaround will be added here when available

       

      Additionally it blocks important use cases for customers.

            [ECO-6] JavaScript API doesn't work if Jira runs in iframe itself

            Hi Joe. This indeed seems fixed now. Please convey our and our customers' thanks to the team involved. Great stuff. 👍

            To JXL for Jira customers who might be watching this: We are now working on a dedicated embed view of sheets, so if you put them on a Confluence page using the iframe macro you can focus on your sheet data instead of navigation UI. Feel free to watch our app to receive a note as soon as this gets released.

            Daniel Franz - JXL added a comment - Hi Joe. This indeed seems fixed now. Please convey our and our customers' thanks to the team involved. Great stuff. 👍 To JXL for Jira customers who might be watching this: We are now working on a dedicated embed view of sheets, so if you put them on a Confluence page using the iframe macro you can focus on your sheet data instead of navigation UI. Feel free to watch our app to receive a note as soon as this gets released.

            Joe Clark added a comment -

            Hey 21e8e5fc380a & 74700d9b524c - please let me know if this fix has been helpful in addressing this key source of customer frustration you described! 

             

            Joe Clark added a comment - Hey 21e8e5fc380a & 74700d9b524c - please let me know if this fix has been helpful in addressing this key source of customer frustration you described!   

            Hi 

            Thank you for your patience while we investigated and fixed this issue.

            We deployed an update in January resolving this issue. This should resolve embedding Jira in any parent application (Confluence, Bitbucket, etc).

            Sam Leatherdale added a comment - Hi  Thank you for your patience while we investigated and fixed this issue. We deployed an update in January resolving this issue. This should resolve embedding Jira in any parent application (Confluence, Bitbucket, etc).

            The JXL app gives me exactly what I need.  But, I cannot believe that in order to display the results on my Confluence Dashboard that I have to export the JXL data into MS Excel or Google Sheets.  This also means that data on my Confluence page is no longer live. 

            LeRoi Mines added a comment - The JXL app gives me exactly what I need.  But, I cannot believe that in order to display the results on my Confluence Dashboard that I have to export the JXL data into MS Excel or Google Sheets.  This also means that data on my Confluence page is no longer live. 

            Could I please get an update on this issue?

            Hannes Obweger - JXL for Jira added a comment - Could I please get an update on this issue?

            Just wanted to emphasise again that this is a highly impactful bug. Basically, third-party apps can't be displayed in the iframe macro because of this.

            Pretty please address with priority, as this blocks important use cases for our customers. They contact us (and other app vendors), it causes lots of support load on our side, we can't do anything else than telling them that this is a bug on the Atlassian side, they get angry because they already suspect that this is not going to get addressed, everyone's unhappy, everyone loses. 🤷‍♂️

            Also see ACJIRA-2613

            Thanks

            Daniel Franz - JXL added a comment - Just wanted to emphasise again that this is a highly impactful bug. Basically, third-party apps can't be displayed in the iframe macro because of this. Pretty please address with priority, as this blocks important use cases for our customers. They contact us (and other app vendors), it causes lots of support load on our side, we can't do anything else than telling them that this is a bug on the Atlassian side, they get angry because they already suspect that this is not going to get addressed, everyone's unhappy, everyone loses. 🤷‍♂️ Also see ACJIRA-2613 Thanks

              a927362f27e1 Varun Bhargava (Inactive)
              ed2f9d56d345 Szymon Rękawek
              Affected customers:
              24 This affects my team
              Watchers:
              21 Start watching this issue

                Created:
                Updated:
                Resolved: