We are trying to Embed a Power BI report layout to our application using below JavaScript libraries powerbi-client v2.19.1 and powerbi-report-authoring v1.1.1 from below reference
The layout is rendering fine in chrome but in safari it is not rendering the report. I used the code which is mentioned in the github and updated the above powerbi libraries to its latest version also but still the same issue.
I can see the below line is not even triggering(Automatically/manually) in safari
report.layoutReport.render();
The code inside the below method is executing properly but after that this render method is not triggering.
report.layoutReport.on("loaded", async function () {
await report.layoutReport.addPage("story_pinned_" + currentStoryIdPin);
const pages = await report.layoutReport.getPages();
let activePage = jQuery.grep(pages, function (page) { return page.isActive; })[0];
report.layoutPage = activePage;
report.layoutPage.setActive();
// Set layoutPageName to active page name
report.layoutPageName = activePage.name;
//remaining code
report.layoutReport.render();
});
I can see in safari it is hitting in to the on.error method and throwing this issue
isTrusted: false
Can we make this works in safari
NOTE: normal report embeding is working fine in safari only layout report embeding is not rendering
let report = powerbi.embed(visualContainer, visualConfig); - this is working in both
report.layoutReport = powerbi.load(reportContainerpin, config); - not working in safari