Implement FileLink WebExtensions API
Categories
(Thunderbird :: Add-Ons: Extensions API, enhancement)
Tracking
(thunderbird_esr6064+ fixed, thunderbird64 fixed, thunderbird65 fixed)
People
(Reporter: Fallen, Assigned: darktrojan)
References
Details
Attachments
(3 files, 8 obsolete files)
53.41 KB,
patch
|
darktrojan
:
review+
jorgk-bmo
:
approval-comm-beta+
|
Details | Diff | Splinter Review |
17.39 KB,
patch
|
Fallen
:
feedback+
|
Details | Diff | Splinter Review |
55.07 KB,
patch
|
darktrojan
:
review+
jorgk-bmo
:
approval-comm-esr60+
|
Details | Diff | Splinter Review |
Assignee | ||
Comment 1•6 years ago
|
||
Reporter | ||
Comment 2•6 years ago
|
||
Assignee | ||
Comment 3•6 years ago
|
||
Reporter | ||
Comment 4•6 years ago
|
||
Comment 5•6 years ago
|
||
Assignee | ||
Comment 6•6 years ago
|
||
Updated•6 years ago
|
Reporter | ||
Comment 7•6 years ago
|
||
Assignee | ||
Comment 8•6 years ago
|
||
Reporter | ||
Comment 9•6 years ago
|
||
Assignee | ||
Comment 10•6 years ago
|
||
Assignee | ||
Comment 11•6 years ago
|
||
Reporter | ||
Comment 12•6 years ago
|
||
Reporter | ||
Comment 13•6 years ago
|
||
Reporter | ||
Comment 14•6 years ago
|
||
Comment 15•6 years ago
|
||
Assignee | ||
Comment 16•6 years ago
|
||
Reporter | ||
Comment 17•6 years ago
|
||
Reporter | ||
Comment 18•6 years ago
|
||
Reporter | ||
Comment 19•6 years ago
|
||
Assignee | ||
Comment 20•6 years ago
|
||
Assignee | ||
Comment 21•6 years ago
|
||
Comment 22•6 years ago
|
||
Comment 23•6 years ago
|
||
Reporter | ||
Comment 24•6 years ago
|
||
Assignee | ||
Comment 25•6 years ago
|
||
Reporter | ||
Comment 26•6 years ago
|
||
Assignee | ||
Comment 27•6 years ago
|
||
Reporter | ||
Comment 28•6 years ago
|
||
Assignee | ||
Comment 29•6 years ago
|
||
Assignee | ||
Comment 30•6 years ago
|
||
Assignee | ||
Comment 31•6 years ago
|
||
Reporter | ||
Updated•6 years ago
|
Comment 32•6 years ago
|
||
Assignee | ||
Updated•6 years ago
|
Comment 33•6 years ago
|
||
Comment 34•6 years ago
|
||
Comment 35•6 years ago
|
||
Comment 36•6 years ago
|
||
Comment 37•6 years ago
|
||
Assignee | ||
Comment 38•6 years ago
|
||
Assignee | ||
Comment 39•6 years ago
|
||
Reporter | ||
Comment 40•6 years ago
|
||
Assignee | ||
Comment 41•6 years ago
|
||
Assignee | ||
Updated•6 years ago
|
Assignee | ||
Comment 42•6 years ago
|
||
Comment 43•6 years ago
|
||
Comment 44•6 years ago
|
||
Comment 45•6 years ago
|
||
Assignee | ||
Comment 46•6 years ago
|
||
Comment 47•6 years ago
|
||
Comment 48•6 years ago
|
||
Comment 49•6 years ago
|
||
Comment 50•6 years ago
|
||
Comment 51•6 years ago
|
||
Comment 52•6 years ago
|
||
Comment 53•6 years ago
|
||
Comment 54•6 years ago
|
||
Comment 55•6 years ago
|
||
Comment 56•6 years ago
|
||
Comment 57•6 years ago
|
||
Comment 58•6 years ago
|
||
Comment 59•6 years ago
|
||
Assignee | ||
Updated•6 years ago
|
Comment 60•6 years ago
|
||
So I'm giving a stab at updating the addon to the webext API.
In the "settings" page which is used to setup an account, I don't see a way to perform validation before the account is added.
The onAccountAdded event is emitted too late.
Form validation seems to be somewhat working as required fields seem to prevent submission, but I don't want to perform account validation at each onchange event. Hooking up to onsubmit doesn't work, and returning false doesn't prevent submission.
Ideas?
Assignee | ||
Comment 61•6 years ago
|
||
The simple answer, and not really what you want, is that the settings page is about to be removed completely. In hindsight we shouldn't have even put it in the API, but we didn't realise that at the time.
What you should do instead, is put all your configuration in the "management" page, and set the "configured" flag on the account when you're ready. Thunderbird 60 doesn't currently do anything with the flag, but I will change that in an upcoming release.
I'm going to update the docs now, as they don't reflect what I've just said.
Comment 62•6 years ago
|
||
The "Box" provider though does prevent submission until authentication is provided (cannot say what happens next, as I don't have a box account).
I guess I shouldn't even attempt this if the page is going to be removed? In this case, should I just put an empty page?
When will the single-instance limit be lifted? I have several cases where I'd like to select which server I want to use.
Assignee | ||
Comment 63•6 years ago
|
||
I guess I shouldn't even attempt this if the page is going to be removed? In this case, should I just put an empty page?
That's what I've been doing. For up-to-date Thunderbird versions you don't even need to do that.
When will the single-instance limit be lifted? I have several cases where I'd like to select which server I want to use.
Thunderbird 68. You could test in a beta version already. Technically it should be possible in TB60, but the UI is horribly broken, so don't even try it.
Comment 64•5 years ago
|
||
This new API is really limited.
While it's very handy just providing the whole file loaded into memory as an ArrayBuffer
, this is at least causing two issues:
- Providers will be unable to let users upload files of GBs...
- Some providers (such as MEGA) does need the file modification time.
Also, the way the file is loaded into memory is bogus:
+++ b/mail/components/extensions/parent/ext-cloudFile.js
@@ -0,0 +1,353 @@
+...
+async function promiseFileRead(nsifile) {
+ let blob = await File.createFromNsIFile(nsifile);
+
+ return new Promise((resolve, reject) => {
+ let reader = new FileReader();
+ reader.addEventListener("loadend", () => {
+ resolve(reader.result);
+ });
+ reader.addEventListener("onerror", reject);
I.e. any error loading the file won't be handled properly.
So, I would strongly advise to improve this further, e.g. by providing a File
instance to the Filelink extension...
Comment 65•5 years ago
|
||
Regrettably this won't fix the DL FileLink extension as per previous comments here and elsewhere.
https://addons.thunderbird.net/en-US/thunderbird/addon/dl-for-thunderbird/
Still stuck on 52.9.x and will be until we decide to change email program (and I can see why many have dumped things like Thunderbird and gone with web mail etc - none of this nonsense) or I can get someone to update the extension. I have offered money but even that doesn't seem an incentive.
Sometimes I despair.
Assignee | ||
Updated•5 years ago
|
Description
•