How to convert FAB to popup menu?

According to the material development guide, β€œA floating action button can be transformed into a single sheet of material that contains all the actions.”

I want to create the following animation without using third-party libraries.

enter image description here

+4
source share
1 answer

First you need to cut this animation in small pieces. In this example, I can output 3 steps:

  • The ripple effect on the FAB, triggered by a click event.
  • the left margin applies to FAB.
  • Added a Circular Reveal animation to the map.

, FAB (visible) (invisible). FAB . , FAB ( 1) FAB ( 2), FAB Reveal ( 3).

, ViewAnimationUtils.createCircularReveal. , X, Y, ! , , , / , .

, fooobar.com/questions/1663313/.... , . ( ).

GitHub

https://github.com/fbourlieux/android-material-circular_reveal_animation

!

:

+3

Source: https://habr.com/ru/post/1663312/


All Articles