Comments (7)
Found this so far: https://bugzilla.mozilla.org/show_bug.cgi?id=1759835
from threema-web.
Happens on a lot of pages, so I'm not even sure we should do anything about it. Agree it's annoying though. Maybe there's a bugzilla bug?
from threema-web.
A potential workaround is downloading PDF files using the media type application/octet-stream
, one of our support staff said that this seems to help. It's a ugly hack for a problem in Firefox, but if it works it might be a valid workaround. Opening PDFs is probably quite a common use case for Threema Web, so this should not break (it logs you out of the current session).
I'll take a closer look this afternoon. We're using a method that should always result in a download, so I suspect that Firefox is doing something wrong here. If I can confirm that, I'll comment on the Bugzilla ticket.
from threema-web.
Found another longer discussion we might want to chime in: https://bugzilla.mozilla.org/show_bug.cgi?id=1756980#c5 (sigh, blaming bad UX while not even knowing the use case, like SPA with state in memory... come on)
We're using file-saver
which uses target=_blank
, so this would be the most fitting bug I guess: https://bugzilla.mozilla.org/show_bug.cgi?id=1759916
from threema-web.
Ugh, so they intentionally ignore the download
attribute and Content-Disposition: attachment
? https://bugzilla.mozilla.org/show_bug.cgi?id=1756980#c7
from threema-web.
We're using
file-saver
which usestarget=_blank
, so this would be the most fitting bug I guess: https://bugzilla.mozilla.org/show_bug.cgi?id=1759916
file-saver uses a lot of different approaches depending on the browser: https://github.com/eligrey/FileSaver.js/blob/master/src/FileSaver.js In our case (Firefox) an approach with a.href = URL.createObjectURL(blob)
followed by click(a)
is used.
Fun fact from bugzilla 1756980:
This also happens on WhatsApp web now. PDF files are opened in the same tab, although pressing the back button does re-logins the users. But I think this shows that this behavior is not expected.
For now, I'll add the ugly application/octet-stream
workaround hack for Firefox, which does seem to work.
from threema-web.
For the record, the change was finally reverted in Firefox 103: https://bugzilla.mozilla.org/show_bug.cgi?id=1756980#c71
from threema-web.
Related Issues (20)
- Wrong trailing semicolon on URL HOT 3
- Build Instructions Don't Work for Windows 10 HOT 4
- "Uncaught ReferenceError: WebAssembly is not defined" in Microsoft Edge HOT 2
- Chats scrolls down when trying to scroll up and older content loads in HOT 3
- Chrome: Password filling doesn't work anymore
- Threema desktop preventing standby on Windows HOT 6
- User Interface: Could not switch to "Minimal" user interface HOT 3
- CI feature: integrate pull request preview environments HOT 1
- Image quality is bad HOT 1
- App does not start/install anymore (on W7) - says instead "GetpackageFamilyName()" in "KERNEL32.dll" couldn't be found HOT 1
- Big files won't upload HOT 3
- Editing of posts HOT 1
- Agree/disagree feature HOT 1
- Replace cryptography with something better
- Please document the required node version HOT 2
- Version 2.5.3's marking of read messages is incompatible with non-current Firefox versions HOT 3
- Strange linkification for path to python script
- Compose area with multiple lines cannot be scrolled fully to the top
- Missing placeholder text in compose area when deleting multiple lines HOT 1
- Latest update not released, getting annoyed by update pop-up HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from threema-web.