Giter Club home page Giter Club logo

motionlayoutmenua's Introduction

MotionLayout Menu

Dribble menu design https://dribbble.com/shots/2653519-Menu built with Android MotionLayout

Demo

Youtube demo https://www.youtube.com/watch?v=CT0qKL3F278

alt tag

Description

In layout file views v1, v2, v3, v4 are four menus c1, c2, c3, c4 are four background content views and view ic1 is down arrow image. My screen height is 640dp - 24dp = 616dp (24dp is status bar height). If you want to change menu size according to your screen resolution open dimens.xml and change menu height in expanded and collapsed state

menu_expanded_height = 154dp (616dp / 4)
menu_collapsed_height = 80dp

Change top margins of each menu according to your screen height to place menus one after another

v1_expanded_margin_top
v2_expanded_margin_top
v3_expanded_margin_top
v4_expanded_margin_top

MotionScene file in xml/motion_scene.xml contains comments about each Transition and ConstraintSet. MenuActicity only handles click events and run transitions defined in motion_scene file.

motionlayoutmenua's People

Contributors

dev-faob avatar faob-dev avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.