Repository navigation
Add Image Convert: HEIC, AVIF, TIFF and BMP attachments as JPEG/PNG - #6
Merged
Merged
Conversation
A content script converts these attachments with macOS sips before BB uploads them, and steps aside per format once BB converts it itself (get-bb/bb#1670, get-bb/bb#8349). Co-Authored-By: Claude Opus 5.5 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
New plugin Image Convert (0.1.0).
BB rejects HEIC attachments and keeps AVIF, TIFF and BMP as they are. A content script wraps
window.fetchforPOST /api/v1/projects/<id>/attachments, sends these files to the plugin's/convertroute, and macOSsipsreturns a JPEG (PNG when the image has an alpha channel). For each format the first upload goes to BB unchanged: once BB answers with a provider-readable type, the plugin steps aside for that format for good, logs it, andbb image-convert statusreports it. This is a stopgap until get-bb/bb#8349 (fixes get-bb/bb#1670) ships.Verified:
npm test(20: the shim's routing, fallbacks and step-aside, plus sips conversions of HEIC/AVIF/TIFF/BMP fixtures) andnpm run typecheckpass. Agit archivebuild passes too./convertroute turned a 4032×3024 HEIC into a JPEG. From a bb web tab, animage/heicupload through the page'sfetchcame back201asIMG_TEST.jpg,image/jpeg.marketplace.jsonvalidates against marketplace-v2.🤖 Generated with Claude Code