[TIMOB-19949] Android: Implement Snackbar widget
GitHub Issue | n/a |
---|---|
Type | New Feature |
Priority | Medium |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2017-05-01T14:59:21.000+0000 |
Affected Version/s | n/a |
Fix Version/s | Backlog |
Components | Android |
Labels | Community, hyperloop |
Reporter | Tim Poulsen |
Assignee | Hans Knöchel |
Created | 2015-11-12T20:33:58.000+0000 |
Updated | 2018-08-06T17:49:29.000+0000 |
Description
As part of their Material Design, Android has introduced the Snackbar. It is a new type of toast message that can display one or two short lines of text and a single button in a slide-up view displayed at the bottom of the screen.
See these links for reference:
* https://www.google.com/design/spec/components/snackbars-toasts.html
* http://developer.android.com/reference/android/support/design/widget/Snackbar.html
* http://www.materialdoc.com/snackbar/
I would like to implement this aspect of material design in my app. At this point, I'm stuck writing an Alloy widget that won't be able to implement native behavior, such as automatically pushing up the floating action button.
To be considered for implementation via hyperloop
Moved our Hyperloop-Examples code of the Snackbar into an own Hyperloop module: https://github.com/hyperloop-modules/ti.snackbar Resolving as
Fixed
.I think we should reconsider adding this to Titanium's core. It's easy to add, popular amongst native Android developers, and should support all Android OS versions via Google's "design" support library. It can be added as:
Ti.UI.Android.SnackBar
And it can work similar to an alert/option dialog, except it only supports 1 button. I suppose the closest equivalent on iOS is our OptionDialog with 1 button, but the dialog eats up much more vertical space compared to Android. An AndroidSnackBar
is more like a toolbar with a message and a button which slides in.Cleaning up older fixed issues. If this issue should not have been closed as fixed, please reopen.