- Addressed the issue where remote image URLs failed to be processed due to local file handling restrictions.
- Introduced `FetchAndStoreRemoteImage` to download and save remote images to a temporary file, enabling compatibility with existing processing functions.
- Split the main image handling logic into smaller functions (`OpenAndDecodeImage`, `AdjustImage`) for better modularity and maintainability.
- Updated `OpenAndAdjustImage` to use these new functions, ensuring a streamlined flow for both local and remote images.
- Added cleanup steps for temporary files to prevent resource leaks.
resolves: #15691
This commit adds support for unfurling static image URLs (not GIFs, not animated WebPs), such as https://placehold.co/600x400@2x.png. It also compresses images before returning them as data URIs to clients.
About compression: the compression strategy leverages the existing function images.CompressToFileLimits. A more comprehensive logic to consider the possibility of multiple image URLs being unfurled simultaneously is yet to be implemented.
Closes#3761