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

Widget Requests #1239

Open
rskabelund opened this issue Mar 29, 2017 · 8 comments
Open

Widget Requests #1239

rskabelund opened this issue Mar 29, 2017 · 8 comments
Milestone

Comments

@rskabelund
Copy link

rskabelund commented Mar 29, 2017

Widget Requests

Not sure where to ask, but I have been making my own custom widgets using cookie cutter template and figured it would be good to at least ask for some of them to be added for all. These may seem trivial, but I have found them to be quite useful.

Widgets using Cookie Cutter:

LinkButton Widget
Pretty straight forward. Could be used as a redirect, or what I prefer a small footprint button click.

BreadCrumbs Widget
Basically a collection of LinkButton Widgets that grow horizontally with a list of values separated by a character. Separator character is an argument with a default of '/'. Would be nice if it rendered HTML unicode characters.

BusyIndicator Widget
Basically an animated gif to indicate something is happening. Visibility is controlled with an enabled property. I hard coded the base-64 image right into the widget.

Improved RadioButtons
I needed to arrange radio buttons horizontally, couldn't seem to accomplish this with existing widget in 5.2.2 so I made my own. Not sure if this has been addressed in 6.0, perhaps I could use the ToggleButtons now.

ListBox - dblclick event
Yes I know there is a Select widget already, but I needed to handle a dbl-click event so I rolled my own for now... Would be nice if the Select widget would expose the dbl-click event.

Widget Classes Made from Existing Widgets:

ListTab
Similar function to a tab container, except the content is selected by a single selected item in a Select widget positioned left of the container. This is useful for views of many items that would be too excessive for the tab control. I currently use this to load up many plotly plots and allow users to "scroll" through them.

SelectTab
Similar to the ListTab but not the same. Uses a dropdown to select the current content, but the dropdown is above the content in a VBox, and it allows space to the right of the dropdown for a toolbar of buttons that can be used to perform action on the content. I use this to look at different views of the same data and the buttons are used to expand the view or save the plot as an image.

Wishlist that I am working on still:

CheckBoxSelect Widget
I have failed to be able to come with this one, but my users would really like to have this ability.

UploadBox
This one is stalled as well. Would add ability to handle a drag drop event for uploading files from within the notebook output. Having to upload files outside the notebook through Jupyter is clunky for my users. Would basically add a drag-over and drop event to whatever children it contains.

Haven't Found a Way to Deploy Cookie Cutter Widgets to Dashboard Server

Some of my motivation for asking for these requests is that we have been unable to get our jupyter hub dashboard server operational due to not being able to load up custom widgets. I do not know all the details of that issue, but I am told it has something to do with the js require not finding the custom widget js. Sounds like we need a jupyter nbextension enable for dashboard servers?

Anyways if the cookie cutter widgets above were part of the ipywidgets library then I wouldn't even need our custom js widgets.

Well, there you go, all my dirty laundry out there for everyone to pick apart why I did it that way. If there are other controls out there readily available, please let me know.

If you got this far, thanks!

Regards,

-Randy

@jasongrout
Copy link
Member

Thanks! We really envision the widgets as a framework for people to publish their own collection of widgets. Have you published these separately in their own package?

@rskabelund
Copy link
Author

So, I do currently have these in a private github repo hosted in-house. It is currently not isolated from other proprietary modules. I will need to looking into getting them on the public git hub. Are there many other collections of widgets in existence already?

@jasongrout
Copy link
Member

pythreejs, ipyleaflet, and bqplot are three major collections of widget libraries that are their own separate packages.

@rskabelund
Copy link
Author

Referencing my motivation for requesting the above cookie cutter widgets be added to the core ipywidgets (as a workaround), creating a standalone public repo would still have the same dashboard server issues. The dashboard server seems to have chosen only to integrate ipywidgets and not cookie cutter widgets. Not sure when that would be addressed.

For such basic widgets like a LinkButton and a BusyIndicator it seems like overkill to create an entire org/repo for them. For the other widgets, I see your point.

@jasongrout
Copy link
Member

I think we should definitely look at including widgets in the core widgets. At the same time, I think we should make it easy to have widgets outside the core widgets work well.

@jasongrout
Copy link
Member

Thanks again for your suggestions. I've opened up a couple of issues for individual enhancement requests.

Improved RadioButtons

This is #1247 now.

ListBox - dblclick event

This is #1248 now.

@jasongrout
Copy link
Member

jasongrout commented Apr 1, 2017

The dashboard server seems to have chosen only to integrate ipywidgets and not cookie cutter widgets. Not sure when that would be addressed.

I don't know how the dashboard server works, but I think the embedded widget manager loads widgets on the fly as needed from a CDN.

By the way, we are going to be working on dashboarding later this year, after JupyterLab comes out of beta. See jupyterlab/jupyterlab#1640 for some discussion on the topic.

@rskabelund
Copy link
Author

@jasongrout thanks for opening those tickets.

@jasongrout jasongrout added this to the Backlog milestone Apr 8, 2017
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

No branches or pull requests

2 participants