thunderbird-conversations
thunderbird-conversations copied to clipboard
webextension contact photo
It appears that the photoURI of a contact may reference the absolute path of a file on disk. I haven't tested yet, but I'm guessing the webextension permissions won't let <img> tags display files directly from disk, so we'll need some abstraction...Has this already been dealt with in firefox somehow?
I just had a look at this and you're right. We would be able to display the img tags at the moment (because we're not a full extension), but not in future.
I've just filed https://bugzilla.mozilla.org/show_bug.cgi?id=1642085 on this, though I doubt it'll be fixed in the short term (certainly not for 78).
How about we create an API in contactsAPI.js that is something like getPhoto(id) and returns either a data url or a blob? I suspect that might be similar to what we end up with anyway.
I think we fixed this along the way somewhere, but I've also just landed 9d1884bf411273bfcffeb3e4107aeb73b3be1392 which switches to an official WebExtension API: 9d1884bf411273bfcffeb3e4107aeb73b3be1392