Page MenuHomePhabricator

Use FloatingActionButton for deleting recent searches.
Closed, DuplicatePublic

Description

A floating action button has been added to the design support library, and we should try incorporating it in one or two places. The "delete recent searches" interaction seems like a good place to start.

http://developer.android.com/reference/android/support/design/widget/FloatingActionButton.html

Event Timeline

Dbrant raised the priority of this task from to Needs Triage.
Dbrant updated the task description. (Show Details)
Dbrant subscribed.

It seems strange to have the delete all recent searches action be the primary call to action on that screen.
But I see the advantage of having the button farther away from the clear search text button.

This may require also using CoordinatorLayout. Not sure if the keyboard could hide the FAB also. That would make this more complicated.

Change 219829 had a related patch set uploaded (by Dbrant):
[WIP] Experiments with FloatingActionButton.

https://gerrit.wikimedia.org/r/219829

Change 223898 had a related patch set uploaded (by Mholloway):
Replace 'delete all searches' button on search bar with floating action button

https://gerrit.wikimedia.org/r/223898

Change 219829 abandoned by Dbrant:
[WIP] Experiments with FloatingActionButton.

Reason:
superseded by https://gerrit.wikimedia.org/r/223566

https://gerrit.wikimedia.org/r/219829

Change 223898 merged by jenkins-bot:
Replace 'delete all searches' button on search bar with floating action button

https://gerrit.wikimedia.org/r/223898

I don't think this is the correct usage of the floating action button. A floating action button represents the primary action in an application (note - application, not per screen)

They clearly recommend against usage for for minor / destructive actions.

Also, the mini size is not for less critical or destructive actions. It is used to create visual continuity with other screen elements such as having other circles (contact list for example)

I know it hurts to rip something you guys just built.

  1. We could use it to test engagement with the stated action ( if it is instrumented )
  2. Replace it with an inline button, if we consider 'Delete Saved Searches' to be critical.

https://www.google.com/design/spec/components/buttons.html#buttons-usage

Where would you suggest we place it?
(we could also just revert to the way we had it)

What is the primary action in the Wikipedia mobile app?

Actually, the FAB would be perfect for 'edit' (or, more specifically, 'edit current section'), if it were an editing-focused app...

While it's a reading-focused app, though, navigation (via TOC) seems like a sensible candidate for primary action. Are there others?

(I agree with @Vibhabamba that using another FAB for 'delete recent searches' does feel a bit odd.)