Skip to content
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

fix drag n drop in test viewer #341

Merged
merged 2 commits into from
Nov 22, 2023
Merged

fix drag n drop in test viewer #341

merged 2 commits into from
Nov 22, 2023

Conversation

toloudis
Copy link
Contributor

@toloudis toloudis commented Nov 7, 2023

Problem

Drag and drop with multiple geometry assets was not working in the testbed viewer.

Solution

The test viewer uses a slightly different code path than the simularium-website viewer for loading from drag and drop. It was checking a data structure in the wrong way, assuming it was an array instead of a keyed object. This resulted in it ignoring the provided geometry files.
(As far as I can tell, this code path is unused by the website client so it should be totally safe. It was needed to debug a different issue with meshes)

  • Bug fix (non-breaking change which fixes an issue)

Steps to Verify:

  1. Drag and drop a .simularium file accompanied by its necessary .obj meshes.
  2. In the bug case, the meshes totally fail to load.

@toloudis toloudis requested a review from a team as a code owner November 7, 2023 23:39
@toloudis toloudis requested review from meganrm, interim17 and ascibisz and removed request for a team November 7, 2023 23:39
Copy link

github-actions bot commented Nov 7, 2023

jest coverage report 🧪

Total coverage

Status Category Percentage Covered / Total
🔴 Statements 40.14% 1965/4895
🔴 Branches 43.92% 821/1869
🔴 Functions 37.22% 405/1088
🔴 Lines 40.39% 1882/4659

Status of coverage: 🟢 - ok, 🟡 - slightly more than threshold, 🔴 - under the threshold

@interim17
Copy link
Contributor

LGTM, tested with the examples @mogres provided in the slack thread.

@toloudis toloudis mentioned this pull request Nov 16, 2023
@toloudis toloudis merged commit 7dec37c into main Nov 22, 2023
6 checks passed
@toloudis toloudis deleted the fix/drag-n-drop-testviewer branch November 22, 2023 23:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants