Attach (recommended) or Link to PDF file
Not a pdf file related bug
Web browser and its version
Chromium 142.0.7444.162
Operating system and its version
macOS Sequoia 15.6.1
PDF.js version
5.4.149
Is the bug present in the latest PDF.js version?
Not tested
Is a browser extension
No
Steps to reproduce the problem
- Copy & Paste entire viewer html into iframe
- Warning message occurs
What is the expected behavior?
Warning message not occurs
What went wrong?
in iframe's srcdoc, windows.location is always about:srcdoc.
then api.js decides it has different origin.
and then, api.js tries to create a URL object, but it fails. Then pdf.js always setup fake worker.js
Link to a viewer
No response
Additional context
No response