AllenInstitute / ACE

R Shiny app for comparison of annotations (e.g., cell type assignments)
Other
1 stars 1 forks source link

Fix bookmarking #1

Open jeremymiller opened 6 months ago

jeremymiller commented 6 months ago

I have pasted back most of the bookmarking text from earlier versions of the app from the files below; however, this still does not work.

To fix this one of two things will need to happen:

  1. Figure out why Lucas' bookmark workaround code isn't working
  2. Get the actual bookmarking method implemented by RShiny working, in which case I should be able to remove the bookmark_function.R file.

This is important because it lets folks save specific states of the app.

File location is here: https://github.com/AllenInstitute/annotation_comparison/blob/2def60e88164ba4f8c5ebe0df06bbe07554b31f9/R/bookmark_functions.R Bookmarking code in this server file: https://github.com/AllenInstitute/annotation_comparison/blob/2def60e88164ba4f8c5ebe0df06bbe07554b31f9/R/server.R

jeremymiller commented 3 months ago

Update: I've tried a bunch of things, and ALMOST got it working with several caveats.

  1. My hack only almost works when put all of the prepopulated data sets into a single nested list rather than into separate categories (e.g., 1 dropdown rather than 2 dropdowns). Since it's still not working properly, I've gone back to the two dropdowns, which I like better.
  2. The solution is to build a long URL, which can then be pasted back in to restore the state. This works for MOST of the content, but does NOT work for selectizeInput boxes when multiple = TRUE. Since this is a primary use case for bookmarks (e.g., to define a SEA-AD version of the app with all other cell types selected, this is a major issue).
  3. I'd like to use bookmarks properly with enableBookmarking("state"), but this has never worked and I have no idea why.

If anyone would like to contribute to this app and solve the bookmarking issue, it would be greatly appreciated!

It is worth noting that in every internet forum I have checked, these scripts should work. There are also other examples of identical code with working bookmarks.