{"action":"created","issue":{"url":"https://api.github.com/repos/mozilla/pdf.js/issues/10290","repository_url":"https://api.github.com/repos/mozilla/pdf.js","labels_url":"https://api.github.com/repos/mozilla/pdf.js/issues/10290/labels{/name}","comments_url":"https://api.github.com/repos/mozilla/pdf.js/issues/10290/comments","events_url":"https://api.github.com/repos/mozilla/pdf.js/issues/10290/events","html_url":"https://github.com/mozilla/pdf.js/issues/10290","id":383670280,"node_id":"MDU6SXNzdWUzODM2NzAyODA=","number":10290,"title":"Error: Permission denied to access property 'print'","user":{"login":"dotnetCarpenter","id":43763,"node_id":"MDQ6VXNlcjQzNzYz","avatar_url":"https://avatars2.githubusercontent.com/u/43763?v=4","gravatar_id":"","url":"https://api.github.com/users/dotnetCarpenter","html_url":"https://github.com/dotnetCarpenter","followers_url":"https://api.github.com/users/dotnetCarpenter/followers","following_url":"https://api.github.com/users/dotnetCarpenter/following{/other_user}","gists_url":"https://api.github.com/users/dotnetCarpenter/gists{/gist_id}","starred_url":"https://api.github.com/users/dotnetCarpenter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dotnetCarpenter/subscriptions","organizations_url":"https://api.github.com/users/dotnetCarpenter/orgs","repos_url":"https://api.github.com/users/dotnetCarpenter/repos","events_url":"https://api.github.com/users/dotnetCarpenter/events{/privacy}","received_events_url":"https://api.github.com/users/dotnetCarpenter/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":19,"created_at":"2018-11-22T23:07:40Z","updated_at":"2018-11-23T13:34:41Z","closed_at":null,"author_association":"NONE","body":"Configuration:\r\n- Web browser and its version: all versions of Firefox since PDF.js was included (5+ years)\r\n- Operating system and its version: all\r\n- PDF.js version: all\r\n- Is a browser extension: n/a\r\n\r\nSteps to reproduce the problem:\r\n1. https://bugzilla.mozilla.org/show_bug.cgi?id=911444\r\n\r\nWhat is the expected behaviour?\r\n**That the PDF can print as in every other browser than Firefox**\r\n\r\nWhat went wrong?\r\n**`Error: Permission denied to access property 'print'`**\r\n\r\nPlease fix this as the go to universal print solution of PDF in browser has been broken for 5 years in Firefox since pdf.js was included in Firefox.\r\n\r\nThe web developer community has hundreds of bad solutions to this, because of a single project, **pdf.js**."},"comment":{"url":"https://api.github.com/repos/mozilla/pdf.js/issues/comments/441242619","html_url":"https://github.com/mozilla/pdf.js/issues/10290#issuecomment-441242619","issue_url":"https://api.github.com/repos/mozilla/pdf.js/issues/10290","id":441242619,"node_id":"MDEyOklzc3VlQ29tbWVudDQ0MTI0MjYxOQ==","user":{"login":"dotnetCarpenter","id":43763,"node_id":"MDQ6VXNlcjQzNzYz","avatar_url":"https://avatars2.githubusercontent.com/u/43763?v=4","gravatar_id":"","url":"https://api.github.com/users/dotnetCarpenter","html_url":"https://github.com/dotnetCarpenter","followers_url":"https://api.github.com/users/dotnetCarpenter/followers","following_url":"https://api.github.com/users/dotnetCarpenter/following{/other_user}","gists_url":"https://api.github.com/users/dotnetCarpenter/gists{/gist_id}","starred_url":"https://api.github.com/users/dotnetCarpenter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dotnetCarpenter/subscriptions","organizations_url":"https://api.github.com/users/dotnetCarpenter/orgs","repos_url":"https://api.github.com/users/dotnetCarpenter/repos","events_url":"https://api.github.com/users/dotnetCarpenter/events{/privacy}","received_events_url":"https://api.github.com/users/dotnetCarpenter/received_events","type":"User","site_admin":false},"created_at":"2018-11-23T13:34:41Z","updated_at":"2018-11-23T13:34:41Z","author_association":"NONE","body":"> Embedding pdf.js in a semi-privileged document was a big mistake in the first place, but there's no going back\r\n\r\n@automatedbugreportingfacility  Why is this decision irreversible?\r\n\r\nCouldn't you just create a new blank document with pdf.js and the same origin as the parent window and feed the PDF file to pdf.js?\r\n\r\n```html\r\n<iframe id=\"pdf\" src=\"some-same-origin.pdf\"></iframe>\r\n<script>\r\n  document.getElementById('pdf').print()\r\n</script>\r\n```\r\n\r\nBonus points, if pdf.js listen for `beforeprint`, cancel the event and print the `<canvas>` (PDF document) and not letting FIrefox print the pdf.js UI."}}
{"actor":{"display_login":"dotnetCarpenter"}}