forked from jupyterlab/jupyterlab-git
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adding support for standalone diffs of images (jupyterlab#1223)
* add ImageDiff component with stub methods * register image diff and add git widget * handle image files in the backend * convert binary file to base64 * return content from binary file condition * Load image from git db * add react-compare-image widget for viewing image diff * remove commented out diff images * fix formatting * migrate to react-image-diff (not working) * basic image diff view logic * use mui tabs/tab components for diff modes * change switch image diff mode logic * add image size constraints in 2-up image diff mode * finish minimum working onion skin image diff view * add image width and height to the 2-up image diff view * add file sizes to 2-up image diff view * fix label and image border colours * finish working swipe image diff view * add reference and challenger indicators to the slider component, and fix styling for image and MUI components * make sliders have the same width as the image for the swipe and onion skin image diff views * fix order of slider labels for swipe image diff view * fix git.py formatting * fix ref and chall having different aspect ratios styling and behaviour, and match slider and image widths responsively * add support for jpg and jpeg images * fix 3 failing tests to reflect binary file support * fix test_content_binary to reflect support for binary files * handle empty base64 image with placeholder * remove react-compare-image and react-image-diff dependencies * fix image diffs from the initial commit * Some clean ups * Add integration test * Lint the code * Fix tests --------- Co-authored-by: Damans227 <[email protected]> Co-authored-by: Frédéric Collonval <[email protected]> Co-authored-by: Frédéric Collonval <[email protected]>
- Loading branch information
1 parent
8666a36
commit a402291
Showing
12 changed files
with
863 additions
and
21 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
Oops, something went wrong.