Improve popup performance (#1487)
* batch media lookups, eliminate base64ing
* properly abort if lookup is interrupted
* Begin to add performance marks
* batch media lookups, eliminate base64ing
* [WIP] attempt to use OffscreenCanvas
* Add worker to offload some stuff off the main thread (except SVG rasterization, because that needs to be on the main thread...)
* swap to rendering SVGs on worker thread using resvg-js/wasm
* further tweaking, add more debug logging
* remove some unnecessary asyncification done earlier in the PR, and add more logging
* remove some dead code and add more logging
* make SW instruct offscreen to create port if non-existent
* make SW instruct offscreen to create port when SW restarts
* Add typed interfaces for most of the new message passing. Remove a bit of dead code
* fix image rendering in Anki, more performance marks
* redo all message passing to make it work on both Chrome and FF
* begin cleanup
* cleanup
* make it work on FF133 which implements ImageDecoder but doesn't have cross-process transferrable VideoFrames
* remove console.logs
* remove unused alt constant
* fix no-undef errors
* fix ts errors
* clean up css, make tests pass
* fix benches
* fix remaining test by doing some upgrades
* cleanup, improve clarity in some places
* Replace performance with safePerformance
* Cleanup to resolve some PR comments
* fix issues discovered by Kuuuube
---------
Co-authored-by: kuuuube <hexagonisalie@gmail.com>
authored by
This is a binary file and will not be displayed.