{"id":18424650,"url":"https://github.com/janheinrichmerker/material-drawer","last_synced_at":"2026-03-14T01:45:46.871Z","repository":{"id":23157890,"uuid":"26513427","full_name":"janheinrichmerker/material-drawer","owner":"janheinrichmerker","description":"Custom drawer implementation for Material design apps.","archived":false,"fork":false,"pushed_at":"2024-10-14T13:27:30.000Z","size":17418,"stargazers_count":596,"open_issues_count":7,"forks_count":133,"subscribers_count":38,"default_branch":"master","last_synced_at":"2025-04-07T04:17:18.160Z","etag":null,"topics":["android","android-library","custom-drawer","java","jitpack","material-components","material-design","material-drawer"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/janheinrichmerker.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"github":"heinrichreimer","custom":null}},"created_at":"2014-11-12T01:28:05.000Z","updated_at":"2024-12-10T11:31:36.000Z","dependencies_parsed_at":"2025-03-24T02:13:47.429Z","dependency_job_id":"27495916-2804-4043-8e4f-142024cd2fc1","html_url":"https://github.com/janheinrichmerker/material-drawer","commit_stats":null,"previous_names":["janheinrichmerker/material-drawer"],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/janheinrichmerker%2Fmaterial-drawer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/janheinrichmerker%2Fmaterial-drawer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/janheinrichmerker%2Fmaterial-drawer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/janheinrichmerker%2Fmaterial-drawer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/janheinrichmerker","download_url":"https://codeload.github.com/janheinrichmerker/material-drawer/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248909211,"owners_count":21181666,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["android","android-library","custom-drawer","java","jitpack","material-components","material-design","material-drawer"],"created_at":"2024-11-06T04:43:32.213Z","updated_at":"2025-12-18T11:03:33.862Z","avatar_url":"https://github.com/janheinrichmerker.png","language":"Java","funding_links":["https://github.com/sponsors/heinrichreimer"],"categories":[],"sub_categories":[],"readme":"![Icon](http://i.imgur.com/Dog6Eim.png)\n\nmaterial-drawer\n===============\n\n[![Android Arsenal](https://img.shields.io/badge/Android%20Arsenal-material--drawer-brightgreen.svg?style=flat)](http://android-arsenal.com/details/1/1162)\n[![JitPack](https://jitpack.io/v/com.heinrichreimersoftware/material-drawer.svg)](https://jitpack.io/#com.heinrichreimersoftware/material-drawer)\n[![Build Status](https://travis-ci.org/janheinrichmerker/material-drawer.svg?branch=master)](https://travis-ci.org/janheinrichmerker/material-drawer)\n[![License](https://img.shields.io/github/license/janheinrichmerker/material-drawer.svg)](https://github.com/janheinrichmerker/material-drawer/blob/master/LICENSE.txt)\n\n\nCustom drawer implementation for Material design apps.\n\nDemo\n----\nA demo app is available on Google Play:\n\n\u003ca href=\"https://play.google.com/store/apps/details?id=com.heinrichreimersoftware.materialdrawerdemo\"\u003e\n\t\u003cimg alt=\"Get it on Google Play\" src=\"https://play.google.com/intl/en_us/badges/images/generic/en-play-badge.png\" height=\"60\" /\u003e\n\u003c/a\u003e\n\nScreenshots\n-----------\n\n| ![material-drawer](http://i.imgur.com/XHgbWaE.png) | ![material-drawer](http://i.imgur.com/uHW9oOh.png) | ![material-drawer](http://i.imgur.com/WXmmc7a.png) |\n|:-:|:-:|:-:|\n| Fixed items | Select profile | Custom theme |\n\nDependency\n----------\n\n*material-drawer* is available on [**jitpack.io**][J]\n\n**Gradle dependency:**\n````gradle\nrepositories {\n    // ...\n    maven { url 'https://jitpack.io' }\n}\n````\n````gradle\ndependencies {\n    compile 'com.heinrichreimersoftware:material-drawer:2.3.3'\n}\n````\n\nGet the latest dependency at [jitpack.io][J].\n\nHow-To-Use\n----------\n**Step 1:** Let your [`Activity`][ABA] extend [`DrawerActivity`][DA]:\n\n````java\npublic class MainActivity extends DrawerActivity {}\n````\n\n**Step 2:** Set your content:\n\n````java\nsetContentView(R.layout.activity_main);\n````\n\n**Step 3:** Add a profile:\n\n````java\naddProfile(\n        new DrawerProfile()\n                .setRoundedAvatar((BitmapDrawable)getResources().getDrawable(R.drawable.profile_avatar))\n                .setBackground(getResources().getDrawable(R.drawable.profile_cover))\n                .setName(getString(R.string.profile_name))\n                .setDescription(getString(R.string.profile_description))\n                .setOnProfileClickListener(new DrawerProfile.OnProfileClickListener() {\n                    @Override\n                    public void onClick(DrawerProfile drawerProfile, long id) {\n                        Toast.makeText(MainActivity.this, \"Clicked profile #\" + id, Toast.LENGTH_SHORT).show();\n                    }\n                })\n        );\n````\n\n**Step 4:** Populate your drawer list:\n\n````java\naddItem(\n        new DrawerItem()\n                .setImage(getResources().getDrawable(R.drawable.ic_first_item))\n                .setTextPrimary(getString(R.string.title_first_item))\n                .setTextSecondary(getString(R.string.description_first_item))\n                .setOnItemClickListener(new DrawerItem.OnItemClickListener() {\n                    @Override\n                    public void onClick(DrawerItem drawerItem, long id, int position) {\n                        Toast.makeText(MainActivity.this, \"Clicked first item #\" + id, Toast.LENGTH_SHORT).show();\n                    }\n                })\n        );\naddDivider();\naddItem(\n        new DrawerItem()\n                .setImage(getResources().getDrawable(R.drawable.ic_second_item))\n                .setTextPrimary(getString(R.string.title_second_item))\n                .setOnItemClickListener(new DrawerItem.OnItemClickListener() {\n                    @Override\n                    public void onClick(DrawerItem drawerItem, long id, int position) {\n                        Toast.makeText(MainActivity.this, \"Clicked second item #\" + id, Toast.LENGTH_SHORT).show();\n                    }\n                })\n        );\n````\n\n**Step 5:** Add `actionBarStyle` to your theme:\n\n````xml\n\u003cstyle name=\"AppTheme\" parent=\"Theme.AppCompat.Light.NoActionBar\"\u003e\n    \u003citem name=\"colorPrimary\"\u003e@color/color_primary\u003c/item\u003e\n    \u003citem name=\"colorPrimaryDark\"\u003e@color/color_primary_dark\u003c/item\u003e\n    \u003citem name=\"colorAccent\"\u003e@color/color_accent\u003c/item\u003e\n    \u003citem name=\"actionBarStyle\"\u003e@style/ThemeOverlay.AppCompat.Dark.ActionBar\u003c/item\u003e\n\u003c/style\u003e\n````\n\n**Step 6 (Optional):** Change the drawer theme:\n\nThe drawer gets themed based on your selected app theme but you can also modify it.\n\n````java\nsetDrawerTheme(\n        new DrawerTheme(this)\n                .setBackgroundColorRes(R.color.background)\n                .setTextColorPrimaryRes(R.color.primary_text)\n                .setTextColorSecondaryRes(R.color.secondary_text)\n                .setTextColorPrimaryInverseRes(R.color.primary_text_inverse)\n                .setTextColorSecondaryInverseRes(R.color.secondary_text_inverse)\n                .setHighlightColorRes(R.color.highlight)\n);\n````\n\n**Step 7 (Optional):** Set your own [`Toolbar`][T]:\n\nYou can set your own [`Toolbar`][T] as you do with [`ActionBarActivity`][ABA].\n\n````java\nsetSupportActionBar(toolbar);\n````\n\nPro Tip: Lollipop status bar\n----------------------------\n\n**Step 1:** Make your status bar transparent:\n\n````xml\n\u003cstyle name=\"AppTheme\" parent=\"Theme.AppCompat.Light.NoActionBar\"\u003e\n    \u003citem name=\"android:windowDrawsSystemBarBackgrounds\"\u003etrue\u003c/item\u003e\n    \u003citem name=\"android:statusBarColor\"\u003e@android:color/transparent\u003c/item\u003e\n\u003c/style\u003e\n````\n\n**That's it!** *material-drawer* takes care of the rest.\n\nInfo: [`DrawerFrameLayout`][DFL] \u0026 [`DrawerView`][DV]\n----------------------------\n\nOf course you can use [`DrawerFrameLayout`][DFL] and [`DrawerView`][DV] alone too. See the comments in the Java files for further information.\n\nOpen source libraries\n-------\n\n_material-drawer_ uses the following open source libraries or files:\n\n* [LinearListView][1] by [@frankiesardo][2] (Apache License 2.0)\n* [ScrimInsetsScrollView][3] from the Google IO app 2014 by [@google][4] (Apache License 2.0)\n* [ImageLoadingPattern][5] by [@Emanuel Vecchio][6] (Apache License 2.0)\n* [RoundedAvatarDrawable][7] by [@Evelio Tarazona Cáceres][8] (Apache License 2.0)\n\nLicense\n-------\n\n    Copyright 2015 Heinrich Reimer\n\n    Licensed under the Apache License, Version 2.0 (the \"License\");\n    you may not use this file except in compliance with the License.\n    You may obtain a copy of the License at\n\n       http://www.apache.org/licenses/LICENSE-2.0\n\n    Unless required by applicable law or agreed to in writing, software\n    distributed under the License is distributed on an \"AS IS\" BASIS,\n    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n    See the License for the specific language governing permissions and\n    limitations under the License.\n\n[1]: https://github.com/frankiesardo/LinearListView\n[2]: https://github.com/frankiesardo\n[3]: https://github.com/google/iosched/blob/master/android/src/main/java/com/google/samples/apps/iosched/ui/widget/ScrimInsetsScrollView.java\n[4]: https://github.com/google\n[5]: https://github.com/rnrneverdies/ImageLoadingPattern\n[6]: https://github.com/rnrneverdies\n[7]: https://gist.github.com/eveliotc/6051367\n[8]: https://github.com/eveliotc\n\n[J]: https://jitpack.io/#com.heinrichreimersoftware/material-drawer\n[ABA]: http://developer.android.com/reference/android/support/v7/app/ActionBarActivity.html\n[DA]: https://github.com/janheinrichmerker/material-drawer/blob/master/library/src/main/java/com/heinrichreimersoftware/materialdrawer/DrawerActivity.java\n[T]: http://developer.android.com/reference/android/support/v7/widget/Toolbar.html\n[DFL]: https://github.com/janheinrichmerker/material-drawer/blob/master/library/src/main/java/com/heinrichreimersoftware/materialdrawer/DrawerFrameLayout.java\n[DV]: https://github.com/janheinrichmerker/material-drawer/blob/master/library/src/main/java/com/heinrichreimersoftware/materialdrawer/DrawerView.java\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjanheinrichmerker%2Fmaterial-drawer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjanheinrichmerker%2Fmaterial-drawer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjanheinrichmerker%2Fmaterial-drawer/lists"}