I have done Shiny dashboard with 4 different tabs in the Side panel. It's all working perfectly fine. The only thing is, the fourth tab is a plotly output. When I click the tab, it should display the entire US county map.
It takes nearly 30 seconds to load the map after the tab button is clicked. Until that the screen just displays the empty body background. Is there anyway I could add a buffering/loading message that gets displayed in the body until the map is loaded? So that the user knows that the map is being loaded.. Thanks
Alternate to the progress bar there are few things you can do in this regard.
library(shinycssloaders)
usage:
withSpinner(plotOutput("my_plot"))
plotOutput("my_plot") %>% withSpinner()
If it takes 30 secs you may want to look into the Asynchronous concept in Rshiny Conference. Joe Cheng talk
probably this is still probably work in progress, but you can find alternate options will be available.
Related
Using leaflet, I have created the below pretty map within the shiny context. As shown in the image below, a label within a box (Intelectual Disability) appears around the map. It disappears when I click somewhere on the page, however, I was wondering to know why this happens and how can I avoid this?
Thanks,
Nader
I'm working on a bookshelf project. I'm still new to programming, but i managed to make the Google Books API work so far, but when I receive the search results, my side drawer (side menu) doesn't expand.
Also, if I want to make a "load more results", what would be the best approach?
Video of the problem: https://www.loom.com/share/12ab331cf37f41038f6da294f5e5ea29
Vercel: https://academicshelf.vercel.app/discover
Best regards,
Frederik
So rather than "expanding" the side bar, make it's height: 100vh and position: fixed. That way, as the user scrolls, the side bar scrolls with them.
As for the "load more results" bit, this is dependent upon your implementation. You're either going to want to paginate or do "infinite scrolling". Pagination can take on the look of a bar at the bottom with total results and different pages, or a simplified version of it would literally just add an element to the bottom that says "load more..." and will load the next set of elements by expanding upon the current list. This prevents the client from downloading a lot of content for items they will never see. For performance, I would recommend lazily loading the next set of results so that when the user clicks the button, it loads the next set instantaneously.
In Orange, is there a way for the report viewer to automatically show the visualizations without having to click the report button within the individual widget?
Thanks.
No.
This functionality could be added, but what would trigger adding the report entry? Any change in the widget? Even, for instance, changing transparency in the scatter plot? OK, this would be too extreme - but where's the line? Consider the network widget, where the user zooms in and out... If it is not perfectly clear in what situations is the report generated automatically and when does the user have to click, it's better to have only manual reporting.
Please see this gist to see what I am trying to achieve: https://gist.github.com/d9e22915234e6ea34d20
The code is heavily cut down on the problem I face. As you can see when running the code there is a "miss" detected on the label or the text area (if you miss it by 5em or whatever). Unfortunately this does not work for the Dialog's own buttons OK and Cancel (Please run the code and you will see immediately what i am talking about). If you click near an FX-Node it should detect wheter you missed it or not.
Does anybody know if it is possible to detect clicks in the Dialogs button area?
And if it is possible, how to link them to the node like the label and the area?
Thank you in advance.
From what you're seeing, I would guess that the Dialog consumes click events in the button bar, so they don't make it to the Window (which is where you added the EventHandler). If you really want to do this, you can change addEventHandler to addEventFilter. This works for me.
Read this tutorial if you want to find out why this works:
http://docs.oracle.com/javase/8/javafx/events-tutorial/processing.htm#CEGJAAFD
I have a bit of doubt regarding my application which is being created using Mate framework. The first thing user has to do is to log in, so I created Login.mxml view. After a successful login I need to display the main view with applicationControlBar at the top and a workspace below. At the moment I have two separate views, so if I understand correctly it makes sense using ViewStack.
Thing is, I'd like also to display some kind of panel with buttons on top of the workspace after login - here is screenshot. After clicking on a button the panel should dissapear. To complicate things a little bit more, there is a possibility for this panel to change state. Clicking on a specific button may result in showing progress bar at the bottom of panel.
I feel I should create separate view, MenuDialog.mxml and put there buttons, progress bar and states, but how to display it on the top of the workspace? I hope my problem is clear enough :)
I would make the panel a popUp, with the main application (or the ViewStack's parent container) as the parent of the popUp. You can use the PopUpManager Class to close it based on user actions within the Panel.
Assuming that perhaps you do not want a modal login style panel (which many apps these days eschew) then you should absolutely use states rather than ViewStacks.
States are a much cleaner way to distinguish the various, uh, states that your UI can be in -LOGGED_IN, LOGGED_OUT, etc.
It may take a little to get used to working with states, but once you do, you'll never go back. :-)