Confluence keyboard shortcuts are disabled when viewing a knowledge base article in Jira Service Desk.

XMLWordPrintable

    • 1
    • Severity 3 - Minor

      Issue Summary

      When integrating Jira Service Management (JSM) with Confluence on a local machine, users can search for knowledge base articles via the customer portal. Upon opening the knowledge base, the JavaScript console displays the following error.

      Failed to run init function: Failed to read a named property 'AJS' from 'Window': Blocked a frame with origin "http://localhost:21916" from accessing a cross-origin frame. ƒ (){i.debug("confluence-keyboard-shortcuts initialising");if(e.PageGadget||j.parent.AJS&&j.parent.AJS.PageGadget)i.debug("Inside the Page Gadget. Skipping keyboard shortcuts");
      else{a.KeyboardShortcut… DOMException: Failed to read a named property 'AJS' from 'Window': Blocked a frame with origin "http://localhost:21916" from accessing a cross-origin frame.
          at init (http://localhost:21916/c71916/s/f8b28c935acd77e4623fddf8c1db7a03-CDN/vi6gqb/8804/1yuue1v/8477afe84993a7eaf6c31533fa4c22c8/_/download/contextbatch/js/_super,-com.atlassian.plugins.atlassian-plugins-webresource-rest:data-collector-perf-observer/batch.js?locale=en-GB:3643:428)
          at http://localhost:21916/c71916/s/f8b28c935acd77e4623fddf8c1db7a03-CDN/vi6gqb/8804/1yuue1v/8477afe84993a7eaf6c31533fa4c22c8/_/download/contextbatch/js/_super,-com.atlassian.plugins.atlassian-plugins-webresource-rest:data-collector-perf-observer/batch.js?locale=en-GB:2498:1474 Error: Failed to read a named property 'AJS' from 'Window': Blocked a frame with origin "http://localhost:21916" from accessing a cross-origin frame.
          at init (http://localhost:21916/c71916/s/f8b28c935acd77e4623fddf8c1db7a03-CDN/vi6gqb/8804/1yuue1v/8477afe84993a7eaf6c31533fa4c22c8/_/download/contextbatch/js/_super,-com.atlassian.plugins.atlassian-plugins-webresource-rest:data-collector-perf-observer/batch.js?locale=en-GB:3643:428)
          at http://localhost:21916/c71916/s/f8b28c935acd77e4623fddf8c1db7a03-CDN/vi6gqb/8804/1yuue1v/8477afe84993a7eaf6c31533fa4c22c8/_/download/contextbatch/js/_super,-com.atlassian.plugins.atlassian-plugins-webresource-rest:data-collector-perf-observer/batch.js?locale=en-GB:2498:1474
      

      This is reproducible on Data Center: yes

      Steps to Reproduce

      1. Initiate Jira Service Management (JSM) on the local host.
      2. Launch Confluence on the local host and generate a new page.
      3. Establish a connection between JSM and Confluence through the application link.
      4. Link the space from confluence where the page is created to a JSM project by navigating to <JSM Project Nam> -> Project setting -> Knowledge Base
      5. Locate the newly created page in Confluence within the customer portal.
      6. Select the link to the page from the search results.
      7. The selected link will direct you to the page within the customer portal.
      8. Inspect the JavaScript console page where the following ERROR message will be displayed.
        Failed to run init function: Failed to read a named property 'AJS' from 'Window': Blocked a frame with origin "http://localhost:21916" from accessing a cross-origin frame. ƒ (){i.debug("confluence-keyboard-shortcuts initialising");if(e.PageGadget||j.parent.AJS&&j.parent.AJS.PageGadget)i.debug("Inside the Page Gadget. Skipping keyboard shortcuts");
        else{a.KeyboardShortcut… DOMException: Failed to read a named property 'AJS' from 'Window': Blocked a frame with origin "http://localhost:21916" from accessing a cross-origin frame.
            at init (http://localhost:21916/c71916/s/f8b28c935acd77e4623fddf8c1db7a03-CDN/vi6gqb/8804/1yuue1v/8477afe84993a7eaf6c31533fa4c22c8/_/download/contextbatch/js/_super,-com.atlassian.plugins.atlassian-plugins-webresource-rest:data-collector-perf-observer/batch.js?locale=en-GB:3643:428)
            at http://localhost:21916/c71916/s/f8b28c935acd77e4623fddf8c1db7a03-CDN/vi6gqb/8804/1yuue1v/8477afe84993a7eaf6c31533fa4c22c8/_/download/contextbatch/js/_super,-com.atlassian.plugins.atlassian-plugins-webresource-rest:data-collector-perf-observer/batch.js?locale=en-GB:2498:1474 Error: Failed to read a named property 'AJS' from 'Window': Blocked a frame with origin "http://localhost:21916" from accessing a cross-origin frame.
            at init (http://localhost:21916/c71916/s/f8b28c935acd77e4623fddf8c1db7a03-CDN/vi6gqb/8804/1yuue1v/8477afe84993a7eaf6c31533fa4c22c8/_/download/contextbatch/js/_super,-com.atlassian.plugins.atlassian-plugins-webresource-rest:data-collector-perf-observer/batch.js?locale=en-GB:3643:428)
            at http://localhost:21916/c71916/s/f8b28c935acd77e4623fddf8c1db7a03-CDN/vi6gqb/8804/1yuue1v/8477afe84993a7eaf6c31533fa4c22c8/_/download/contextbatch/js/_super,-com.atlassian.plugins.atlassian-plugins-webresource-rest:data-collector-perf-observer/batch.js?locale=en-GB:2498:1474
        

      Expected Results

      We should not get any ERROR in browser console.

      Actual Results

      The below exception is thrown in the browser console logs:

      Failed to run init function: Failed to read a named property 'AJS' from 'Window': Blocked a frame with origin "http://localhost:21916" from accessing a cross-origin frame. ƒ (){i.debug("confluence-keyboard-shortcuts initialising");if(e.PageGadget||j.parent.AJS&&j.parent.AJS.PageGadget)i.debug("Inside the Page Gadget. Skipping keyboard shortcuts");
      else{a.KeyboardShortcut… DOMException: Failed to read a named property 'AJS' from 'Window': Blocked a frame with origin "http://localhost:21916" from accessing a cross-origin frame.
          at init (http://localhost:21916/c71916/s/f8b28c935acd77e4623fddf8c1db7a03-CDN/vi6gqb/8804/1yuue1v/8477afe84993a7eaf6c31533fa4c22c8/_/download/contextbatch/js/_super,-com.atlassian.plugins.atlassian-plugins-webresource-rest:data-collector-perf-observer/batch.js?locale=en-GB:3643:428)
          at http://localhost:21916/c71916/s/f8b28c935acd77e4623fddf8c1db7a03-CDN/vi6gqb/8804/1yuue1v/8477afe84993a7eaf6c31533fa4c22c8/_/download/contextbatch/js/_super,-com.atlassian.plugins.atlassian-plugins-webresource-rest:data-collector-perf-observer/batch.js?locale=en-GB:2498:1474 Error: Failed to read a named property 'AJS' from 'Window': Blocked a frame with origin "http://localhost:21916" from accessing a cross-origin frame.
          at init (http://localhost:21916/c71916/s/f8b28c935acd77e4623fddf8c1db7a03-CDN/vi6gqb/8804/1yuue1v/8477afe84993a7eaf6c31533fa4c22c8/_/download/contextbatch/js/_super,-com.atlassian.plugins.atlassian-plugins-webresource-rest:data-collector-perf-observer/batch.js?locale=en-GB:3643:428)
          at http://localhost:21916/c71916/s/f8b28c935acd77e4623fddf8c1db7a03-CDN/vi6gqb/8804/1yuue1v/8477afe84993a7eaf6c31533fa4c22c8/_/download/contextbatch/js/_super,-com.atlassian.plugins.atlassian-plugins-webresource-rest:data-collector-perf-observer/batch.js?locale=en-GB:2498:1474
      

      Workaround

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

        1. localhostjsmjs.log
          54 kB
        2. localhost.har
          24.56 MB

            Assignee:
            Maxim Leizerovich
            Reporter:
            Durgesh Anaokar
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: