{"id":13396006,"url":"https://github.com/traex/ExpandableLayout","last_synced_at":"2025-03-13T22:31:27.441Z","repository":{"id":20786528,"uuid":"24071596","full_name":"traex/ExpandableLayout","owner":"traex","description":"Implementation of ExpandableListview with custom header and custom content.","archived":false,"fork":false,"pushed_at":"2022-07-20T17:08:04.000Z","size":723,"stargazers_count":1635,"open_issues_count":64,"forks_count":361,"subscribers_count":61,"default_branch":"master","last_synced_at":"2024-07-31T18:16:17.294Z","etag":null,"topics":[],"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/traex.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}},"created_at":"2014-09-15T19:59:54.000Z","updated_at":"2024-07-15T10:08:46.000Z","dependencies_parsed_at":"2022-08-05T09:15:36.419Z","dependency_job_id":null,"html_url":"https://github.com/traex/ExpandableLayout","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/traex%2FExpandableLayout","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/traex%2FExpandableLayout/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/traex%2FExpandableLayout/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/traex%2FExpandableLayout/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/traex","download_url":"https://codeload.github.com/traex/ExpandableLayout/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243493627,"owners_count":20299691,"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":[],"created_at":"2024-07-30T18:00:37.509Z","updated_at":"2025-03-13T22:31:27.057Z","avatar_url":"https://github.com/traex.png","language":"Java","readme":"ExpandableLayout\n================\n\n![ExpandableLayout](https://github.com/traex/ExpandableLayout/blob/master/header.png)\n\nExpandableLayout provides an easy way to create a view called header with an expandable view. Both view are external layout to allow a maximum of customization. [You can find a sample](https://github.com/traex/ExpandableLayout/blob/master/sample/) that how to use an ExpandableLayout to your layout.\n\n![ExpandableLayout GIF](https://github.com/traex/ExpandableLayout/blob/master/demo.gif)\n \n### Integration\nThe lib is available on Maven Central, you can find it with [Gradle, please](http://gradleplease.appspot.com/#expandablelayout)\n\n``` xml\n\ndependencies {\n    compile 'com.github.traex.expandablelayout:library:1.2.2'\n}\n\n``` \n\n### Usage\n\n#### ExpandableLayout\n\nDeclare an ExpandableLayout inside your XML layout file. You also need to other layouts for header and content:\n\n``` xml\n\n  \u003ccom.andexert.expandablelayout.library.ExpandableLayout\n         android:id=\"@+id/expandableLayout\"\n         xmlns:expandable=\"http://schemas.android.com/apk/res-auto\"\n         android:layout_width=\"match_parent\"\n         android:layout_height=\"match_parent\"\n         expandable:headerLayout=\"@layout/view_header\"\n         expandable:contentLayout=\"@layout/view_content\"/\u003e\n         \n```\n\n#### ExpandableLayoutItem \u0026\u0026 ExpandableLayoutItem\n\nYou can use ExapandableLayout in an `ExpandableLayoutListView` with `ExpandableLayoutItem` as row :\n\nExpandableLayoutItem\n``` xml\n\n  \u003ccom.andexert.expandablelayout.library.ExpandableLayoutItem\n         android:id=\"@+id/expandableLayout\"\n         xmlns:expandable=\"http://schemas.android.com/apk/res-auto\"\n         android:layout_width=\"match_parent\"\n         android:layout_height=\"match_parent\"\n         expandable:headerLayout=\"@layout/view_header\"\n         expandable:contentLayout=\"@layout/view_content\"/\u003e\n         \n```\n\nExpandableLayoutListView\n``` xml\n\n  \u003ccom.andexert.expandablelayout.library.ExpandableLayoutListView\n         android:id=\"@+id/expandableLayout\"\n         xmlns:expandable=\"http://schemas.android.com/apk/res-auto\"\n         android:layout_width=\"match_parent\"\n         android:layout_height=\"match_parent\"/\u003e\n         \n```\nIf you want to manage the OnScroll, you have to use `OnExpandableLayoutScrollListener` and don't forget to call super in each method.\n\nYou can call dynamically `open`, `close` and `isOpened` from an ExpandableLayout object.\n\n### Customization\n\nYou can change duration of the animation:\n\n* app:duration [integer def:200] --\u003e Duration of the animation\n\n### Troubleshooting\n\nIf you want to use the `ExpandableLayoutListView` with EditText, you have to set `android:windowSoftInputMode=\"adjustPan\"` to prevent the ListView to redraw itself and close the ExpandableLayoutItem.\n\n### Acknowledgements\n\nThanks to [Google](http://developer.android.com/reference/android/widget/ExpandableListView.html) for its ExpandableListview :)\n\n### MIT License\n\n```\n    The MIT License (MIT)\n    \n    Copyright (c) 2014 Robin Chutaux\n    \n    Permission is hereby granted, free of charge, to any person obtaining a copy\n    of this software and associated documentation files (the \"Software\"), to deal\n    in the Software without restriction, including without limitation the rights\n    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell\n    copies of the Software, and to permit persons to whom the Software is\n    furnished to do so, subject to the following conditions:\n    \n    The above copyright notice and this permission notice shall be included in\n    all copies or substantial portions of the Software.\n    \n    THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\n    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\n    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\n    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\n    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\n    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN\n    THE SOFTWARE.\n```\n","funding_links":[],"categories":["Index `(light-weight pages)`","Java","Index","Libs"],"sub_categories":["\u003cA NAME=\"Widget\"\u003e\u003c/A\u003eWidget"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftraex%2FExpandableLayout","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftraex%2FExpandableLayout","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftraex%2FExpandableLayout/lists"}