-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
lib-classifier: refactor single image viewer with VisXZoom #6390
base: master
Are you sure you want to change the base?
Conversation
… to SingleImageViewerContainer
I just tried a few different browsers. Scaling and dragging seems to be ok in Chrome or Safari, but broken in Firefox. |
This might be relevant. Dragging interactions get the current transformation matrix from a Line 51 in 1862ade
Creating a mark here gets the CTM from the Line 88 in 1862ade
These refs don’t point to the same element, so that could account for differences in behaviour between creating a mark and dragging a mark. They probably should be using the same element and transformation matrix. I don't think I've noticed this before. At least, I can't find an issue for it, and I'm sure I would have opened an issue for something like this. |
Update: dragging a zoomed-in mark is broken in Firefox on the production release. I'll open an issue. It's not a bug that's been introduced on this branch. The reason is that the Update to the update:
|
...onents/Classifier/components/SubjectViewer/components/SingleImageViewer/SingleImageCanvas.js
Outdated
Show resolved
Hide resolved
...lassifier/components/SubjectViewer/components/SingleImageViewer/components/PlaceholderSVG.js
Outdated
Show resolved
Hide resolved
A brief update on a few issues previously noted:
|
I think this is ready for another review 😵💫 ! I've been using https://local.zooniverse.org:3000/projects/markb-panoptes/test-project-1-mb-fem-lab?env=staging&demo=true to test various workflows, image sizes, and drawing tools (see workflow descriptions). |
I did a first-pass review using Brave Browser on a Macbook Pro and want to jot down three things for now. I plan to test on another macbook and my phone later on!
Will continue testing on more devices by end of the week! |
#6697 should remove the image scaling calculation from this PR. It removes the |
If it's any help, I'm seeing this bug in #6697 too. It appears to be a bug in the current
front-end-monorepo/packages/lib-classifier/src/store/SubjectViewerStore/SubjectViewerStore.js Lines 118 to 129 in 9c6bfa8
I did a quick check of #6581, which refactors the image handlers to use standard DOM interfaces, and that branch has the same bug too. EDIT: I've updated #6581 to include a fix for this, by adding the image frame index to |
This works when every frame has the same dimensions, but Squirrel Mapper (which has odd subjects) has subjects where each frame has different dimensions, including subjects where the frames are a mixture of portrait and landscape orientations. There's also a potential bug when Should subject loading success be 'one frame has loaded' or 'all frames have loaded'? |
Package
Linked Issue and/or Talk Post
Describe your changes
review mobile/pinch handlingnew functionality will be investigated and potentially a separate PRNotes
How to Review
Helpful explanations that will make your reviewer happy:
+
to zoom in) doesn't work, but it does in the linked test project, not sure whyChecklist
PR Creator - Please cater the checklist to fit the review needed for your code changes.
PR Reviewer - Use the checklist during your review. Each point should be checkmarked or discussed before PR approval.
General
yarn panic && yarn bootstrap
ordocker-compose up --build
and FEM works as expectedGeneral UX
Example Staging Project: i-fancy-cats
New Feature
Refactoring