{"id":15036835,"url":"https://github.com/angcyo/dsltablayout","last_synced_at":"2025-05-14T17:02:35.456Z","repository":{"id":39176630,"uuid":"223463340","full_name":"angcyo/DslTabLayout","owner":"angcyo","description":":hearts: Android界最万能的TabLayout(不仅仅是TabLayout), 支持任意类型的item, 支持Drawable类型的指示器,智能开启滚动,支持横竖向布局等","archived":false,"fork":false,"pushed_at":"2025-03-10T07:21:54.000Z","size":32050,"stargazers_count":1651,"open_issues_count":19,"forks_count":152,"subscribers_count":16,"default_branch":"master","last_synced_at":"2025-04-13T01:57:03.598Z","etag":null,"topics":["android","androidx","any-child-type","any-drawable","auto-item-width","auto-scroll","badge","dsl","kotlin","light","tablayout","viewpager","viewpager2"],"latest_commit_sha":null,"homepage":"https://github.com/angcyo/DslAdapter","language":"Kotlin","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/angcyo.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","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":null,"patreon":null,"open_collective":null,"ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"otechie":null,"custom":"https://gitee.com/angcyo/res/raw/master/code/all_in2.jpg"}},"created_at":"2019-11-22T18:36:00.000Z","updated_at":"2025-04-11T09:21:02.000Z","dependencies_parsed_at":"2023-10-20T17:17:12.858Z","dependency_job_id":"6a76cf78-2492-4b44-ac9b-59a06396979d","html_url":"https://github.com/angcyo/DslTabLayout","commit_stats":{"total_commits":259,"total_committers":1,"mean_commits":259.0,"dds":0.0,"last_synced_commit":"97965d979289b6a98df5441871648f4d9b0fd7ed"},"previous_names":[],"tags_count":70,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/angcyo%2FDslTabLayout","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/angcyo%2FDslTabLayout/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/angcyo%2FDslTabLayout/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/angcyo%2FDslTabLayout/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/angcyo","download_url":"https://codeload.github.com/angcyo/DslTabLayout/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248654049,"owners_count":21140235,"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","androidx","any-child-type","any-drawable","auto-item-width","auto-scroll","badge","dsl","kotlin","light","tablayout","viewpager","viewpager2"],"created_at":"2024-09-24T20:32:28.677Z","updated_at":"2025-04-13T01:57:25.307Z","avatar_url":"https://github.com/angcyo.png","language":"Kotlin","funding_links":["https://gitee.com/angcyo/res/raw/master/code/all_in2.jpg"],"categories":[],"sub_categories":[],"readme":"# DslTabLayout\n\n[![API](https://img.shields.io/badge/API-14%2B-brightgreen.svg?style=flat)](https://android-arsenal.com/api?level=14) ![GitHub branch checks state](https://img.shields.io/github/checks-status/angcyo/DslTabLayout/master) ![GitHub](https://img.shields.io/github/license/angcyo/DslTabLayout) [![AndroidX](https://img.shields.io/badge/androidx-100%25-blue)](https://developer.android.google.cn/jetpack/androidx) ![GitHub top language](https://img.shields.io/github/languages/top/angcyo/DslTabLayout) [![](https://jitpack.io/v/angcyo/DslTablayout.svg)](https://jitpack.io/#angcyo/DslTablayout)\n\n![GitHub code size in bytes](https://img.shields.io/github/languages/code-size/angcyo/DslTabLayout) ![GitHub repo size](https://img.shields.io/github/repo-size/angcyo/DslTabLayout) ![GitHub last commit](https://img.shields.io/github/last-commit/angcyo/DslTabLayout) ![GitHub issues](https://img.shields.io/github/issues/angcyo/DslTabLayout) ![GitHub Repo stars](https://img.shields.io/github/stars/angcyo/DslTabLayout?style=social) ![GitHub forks](https://img.shields.io/github/forks/angcyo/DslTabLayout?style=social)\n\n:hearts: Android界最万能的`TabLayout`(不仅仅是`TabLayout`). 高能自绘控件, 继承自`ViewGroup`, 非组合控件.\n\n[Gitee仓库地址](https://gitee.com/angcyo/DslTabLayout)\n\n[文档地址](https://angcyo.gitee.io/doc)\n\n## 特性\n\n1. 支持任意类型的`child`视图.\n2. 支持任意类型`Drawable`的`指示器`.\n3. 支持智能开启`横向滚动`.\n4. 支持智能开启`平分item宽度`(`1.5.4`后).\n5. 支持`高凸模式`, 允许某个`child`高出一节显示.\n6. 支持`滑动选择模式`, 滑动的时候智能选择`上一个`或`下一个`.\n7. 支持`角标`配置.\n8. 支持`ViewPager`和`ViewPager2`\n9. 支持`竖向`(`2.0.0`后)\n10. 支持指示器`居中` `靠左` `靠右`展示(`2.1.0`后)\n11. 支持选中后`突出异形效果`(`2.2.0`后)\n12. 支持`RTL`(`3.0.0`后, `minSdk\u003e=17`)\n13. 支持`指示器颜色滑动渐变效果`(`3.0.1`后)\n14. 支持`指示器闪现效果`(`3.1.0`后)\n15. `3.5.5`前:`compileSdk=33 minSdk\u003e=17` `3.5.5`后:`compileSdk=34 minSdk\u003e=21`\n\n直接当做`横向/竖向`的`LinearLayout`使用方式即可, 无特殊要求.\n\n[入门使用](https://github.com/angcyo/DslTabLayout/wiki/%E5%85%A5%E9%97%A8%E4%BD%BF%E7%94%A8)\n\n[点击查看全部属性](https://github.com/angcyo/DslTabLayout/wiki/%E5%B1%9E%E6%80%A7%E5%A4%A7%E5%85%A8)\n\n[点击查看事件回调](https://github.com/angcyo/DslTabLayout/wiki/Item%E9%80%89%E4%B8%AD%E4%BA%8B%E4%BB%B6)\n\n[点击查看角标使用](https://github.com/angcyo/DslTabLayout/wiki/%E8%A7%92%E6%A0%87)\n\n[关联ViewPager使用(兼容ViewPager2)](https://github.com/angcyo/DslTabLayout/wiki/ViewPager1%E5%92%8CViewPager2)\n\n## 效果\n\n**一个`DSLTabLayout`可实现以下3中效果**\n\n高能自绘控件, 继承自`ViewGroup`, 非组合控件.\n\n无需选择, `xml配置`即可, 还不赶紧收下?\n\n|带滚动效果和角标|\n|:--:|\n|![带滚动效果和角标](png/tab_sliding.gif)|\n\n|普通和高凸效果|\n|:--:|\n|![普通和高凸效果](png/tab_common.gif)|\n\n|带边框,分割线和滑动选择效果|\n|:--:|\n|![分割线和滑动选择效果](png/tab_segment.gif)|\n\n## 竖向效果\n\n![竖向效果](png/tab_sliding_vertical.png)\n\n![竖向效果](png/tab_common_vertical.png)\n\n![竖向效果](png/tab_segment_vertical.png)\n\n## 突出效果\n\n![突出效果](png/tab_highlight_vertical.png)\n\n![突出效果](png/tab_highlight_horizontal.png)\n\n## 闪现效果\n\n![闪现效果](png/flash.gif)\n\n# 使用`JitPack`的方式, 引入库.\n\n## `AGP 8.+` 根目录中的 `settings.gradle`\n\n```groovy\ndependencyResolutionManagement {\n    ...\n    repositories {\n        ...\n        maven { url 'https://jitpack.io' }\n    }\n}\n```\n\n## `AGP 8.-` 根目录中的 `build.gradle`\n\n```groovy\nallprojects {\n    repositories {\n        ...\n        maven { url 'https://jitpack.io' }\n    }\n}\n```\n\n## APP目录中的 `build.gradle`\n\n```kotlin\ndependencies {\n    implementation 'com.github.angcyo.DslTablayout:TabLayout:3.7.1'\n\n    //可选\n    implementation 'com.github.angcyo.DslTablayout:ViewPager1Delegate:3.7.1'\n    //可选\n    implementation 'com.github.angcyo.DslTablayout:ViewPager2Delegate:3.7.1'\n}\n```\n\n如果无法从`jitpack`获取库可以尝试使用`group`:`com.github.angcyo.DslTabLayout:xxx`\n\n\n[更新日志](https://github.com/angcyo/DslTabLayout/blob/master/CHANGELOG.md)\n\n# 下载体验\n\n扫码安装\n\n![扫码安装](png/qrcode.png)\n\n# License\n\n[![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2Fangcyo%2FDslTabLayout.svg?type=large)](https://app.fossa.com/projects/git%2Bgithub.com%2Fangcyo%2FDslTabLayout?ref=badge_large)\n\n---\n**群内有`各(pian)种(ni)各(jin)样(qun)`的大佬,等你来撩.**\n\n# 联系作者\n\n[点此QQ对话](http://wpa.qq.com/msgrd?v=3\u0026uin=664738095\u0026site=qq\u0026menu=yes)  `该死的空格`    [点此快速加群](https://shang.qq.com/wpa/qunwpa?idkey=cbcf9a42faf2fe730b51004d33ac70863617e6999fce7daf43231f3cf2997460)\n\n[开源地址](https://github.com/angcyo/DslTabLayout)\n\n![扫码进群](https://raw.githubusercontent.com/angcyo/res/master/code/all_in1.jpg)\n\n![给点鼓励](https://raw.githubusercontent.com/angcyo/res/master/code/all_in2.jpg)\n\n# 趋势\n\n[![Stargazers over time](https://starchart.cc/angcyo/DslTabLayout.svg)](https://starchart.cc/angcyo/DslTabLayout)\n\n# 👏 感谢\n\n[![angcyo/DslTabLayout](https://reporoster.com/stars/angcyo/DslTabLayout)](https://github.com/angcyo/DslTabLayout/stargazers)\n\n## 访问统计\n\u003cimg height=\"30px\" src = \"https://profile-counter.glitch.me/DslTabLayout/count.svg\" alt =\"Loading\"\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fangcyo%2Fdsltablayout","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fangcyo%2Fdsltablayout","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fangcyo%2Fdsltablayout/lists"}