Skip to content
Snippets Groups Projects

Adding the Neuroglancer button

Merged Guillaume Gaisne requested to merge Neuroglancer-button into main
All threads resolved!

Test to integrate a button in the dataset page to view it with Neuroglancer. For now, the information needed for Neuroglancer is extracted from a local JSON file but I try to mimick as much as possible the code structure for the incoming API calls through IDS

It seems to work correctly, however, I am uncertain of the way I do it. It seems really heavy to me the way I did but I don't know how to do it differently

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • Seems great to me! Just that SWR issue that would be good to look at together.

    Oh yes, one thing: you should start writing some TypeScript! :grin: The more JS files you add, the more difficult it will be to move to it. We can talk about it on Monday as well :wink:

  • added 1 commit

    • fddda8cd - Adding the Neuroglancer button

    Compare with previous version

  • Axel Bocciarelli marked this merge request as ready

    marked this merge request as ready

  • I've pushed some changes:

    • I'm now fetching the Neuroglancer JSON file with useSWRImmutable, so I've removed the local state in the NeuroLink component.
    • I've tweaked the style of the Neuroglancer link so it looks the same as the Globus download link (except for the icon of course), and I've moved the button to the top, as I think they'll want to advertise this feature as much as possible.
    • I've made sure that the mock JSON file is only added to the relevant dataset, 26.38um_complete_upper-lobe, and only when fetching the dataset along with its files (i.e. when rendering DatasetPage).
    • I've added tracking to the Neuroglancer link for good measure.

    So basically, this is now deployable to production. I do recommend you give it another look before merging, though.

  • Axel Bocciarelli approved this merge request

    approved this merge request

  • Guillaume Gaisne added 2 commits

    added 2 commits

    • d98ddd55 - Adding the Neuroglancer button
    • 5cf78349 - Merge branch 'Neuroglancer-button' of...

    Compare with previous version

  • added 1 commit

    • d8308da8 - Hiding the Neuroglancer button for now.

    Compare with previous version

  • added 1 commit

    • 31723ce8 - Hiding the Neuroglancer button for now.

    Compare with previous version

  • Guillaume Gaisne resolved all threads

    resolved all threads

  • Guillaume Gaisne approved this merge request

    approved this merge request

  • reopened

  • Guillaume Gaisne mentioned in commit 24fc4f57

    mentioned in commit 24fc4f57

  • Please register or sign in to reply
    Loading