PlutoSliderServer.jl icon indicating copy to clipboard operation
PlutoSliderServer.jl copied to clipboard

Support "more" button for table viewer

Open lungben opened this issue 3 years ago • 6 comments

It would be great if the "more" button in the Pluto Table View also works in PlutoSliderServer (both for rows and columns):

image

Currently, only the data needed for display are fetched from the server. Thus, when pressing "more" the frontend would need to request additional rows/ columns from the backend.

lungben avatar Mar 31 '22 14:03 lungben

After fixing fonsp/Pluto.jl#2619 I thought the more button would work in PlutoSliderServer, just to find out (on the first day of the semester) that it doesn't :-( What would be needed to have this feature? Happy to help, if you can give me a pointer to the relevant code.

jbrea avatar Sep 21 '23 07:09 jbrea

Also pinging @Pangoraw and @disberd, who pointed me in the right direction for fonsp/Pluto.jl#2619.

jbrea avatar Sep 21 '23 09:09 jbrea

Hey! This is not a bug, but a missing feature that we need to implement: PSS is not a restricted verison of thr Pluto server, but a new server that can only serve static content and compute bind value.

For "more", we need to add an HTTP endpoint to PSS and then call that from the frontend when clicking more.

Did you already figure out how "more" currently works in Pluto? (Please ask questions!) Do you know the behind-the-scenes difference between Pluto and PSS? Would you be able to get started with the PSS feature?

fonsp avatar Sep 21 '23 10:09 fonsp

I could also give some pointers for how to show more rows by default if that helps for your class?

fonsp avatar Sep 21 '23 10:09 fonsp

Thanks for the prompt response, @fonsp!

Did you already figure out how "more" currently works in Pluto?

I don't understand the details of the "more" button in Pluto. The fix fonsp/Pluto.jl#2632 was surprisingly simple and involved only changing one line in PlutoRunner.jl. Therefore I didn't dive deeper.

Do you know the behind-the-scenes difference between Pluto and PSS?

No. My knowledge doesn't go much further than what is in the README of PSS :)

Would you be able to get started with the PSS feature?

If I get some pointers to the relevant pieces of code and if it doesn't look like a lot of work, I could give it a try.

I could also give some pointers for how to show more rows by default if that helps for your class?

I think that wouldn't be great. The notebooks are already pretty long (https://bio322.epfl.ch; I'm basically abusing Pluto to create a multilang interactive website; sorry, I know this is not the indented usage of Pluto :))

jbrea avatar Sep 21 '23 11:09 jbrea

For "more", we need to add an HTTP endpoint to PSS and then call that from the frontend when clicking more.

Wouldn't it be possible to write the data to some javascript variable when the site is generated and load the data from there, when "more" is clicked? Or is this more complicated than writing an HTTP endpoint to PSS?

jbrea avatar Sep 21 '23 11:09 jbrea