{"id":13714710,"url":"https://github.com/DianQK/TrelloNavigation","last_synced_at":"2025-05-07T03:30:51.101Z","repository":{"id":56924548,"uuid":"45976020","full_name":"dianqk/TrelloNavigation","owner":"dianqk","description":"https://dribbble.com/shots/2114816-Trello-Navigation","archived":true,"fork":false,"pushed_at":"2020-04-03T11:18:04.000Z","size":28758,"stargazers_count":118,"open_issues_count":1,"forks_count":20,"subscribers_count":6,"default_branch":"master","last_synced_at":"2025-05-04T06:27:26.637Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Swift","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/dianqk.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-11-11T10:49:25.000Z","updated_at":"2024-03-04T04:51:24.000Z","dependencies_parsed_at":"2022-08-20T22:10:05.680Z","dependency_job_id":null,"html_url":"https://github.com/dianqk/TrelloNavigation","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dianqk%2FTrelloNavigation","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dianqk%2FTrelloNavigation/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dianqk%2FTrelloNavigation/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dianqk%2FTrelloNavigation/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dianqk","download_url":"https://codeload.github.com/dianqk/TrelloNavigation/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252806371,"owners_count":21807193,"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-08-03T00:00:39.572Z","updated_at":"2025-05-07T03:30:50.336Z","avatar_url":"https://github.com/dianqk.png","language":"Swift","funding_links":[],"categories":["Project List"],"sub_categories":["TrelloNavigation"],"readme":"# TrelloNavigation\n\n[https://dribbble.com/shots/2114816-Trello-Navigation](https://dribbble.com/shots/2114816-Trello-Navigation)\n\n\u003e 很喜欢 [SergioChan](https://github.com/SergioChan) 用 Objective-C 写的 [SCTrelloNavigation](https://github.com/SergioChan/SCTrelloNavigation) ，所以我尝试着用 Swift 写了一遍。\n\n## Preview\n\n![](https://raw.githubusercontent.com/DianQK/TrelloNavigation/master/Preview/demo.gif)\n\n## Environment\n\n* Xcode 10 +\n* iOS 8 +\n\n## Intro \u0026 Usage\n\nAPI 和 代码结构和 SCTrelloNavigation 有一定区别，定制化好一些，所以使用的时候代码写的会多一些~但使用起来仍然是 Easy Easy Easy，就像使用 UITableView 。\n\n### CocoaPods\n\n```\nsource 'https://github.com/CocoaPods/Specs.git'\nplatform :ios, '8.0'\nuse_frameworks!\n\npod 'TrelloNavigation', '~\u003e 0.10.0'\n```\n\n### 初始化\n\n```swift\ntrelloView = TrelloView(frame: CGRect(x: 0, y: 0, width: ScreenWidth, height: ScreenHeight), tabCount: 5, trelloTabCells: { () -\u003e [UIView] in\n    return [\n        TrelloListTabViewModel.tabView(title: \"BACKLOG\", level: 3),\n        TrelloListTabViewModel.tabView(title: \"BRIEFS\", level: 5),\n        TrelloListTabViewModel.tabView(title: \"DESIGN\", level: 2),\n        TrelloListTabViewModel.tabView(title: \"USER TESTING\", level: 4),\n        TrelloListTabViewModel.tabView(title: \"USER TESTIN\", level: 1)\n    ]\n})\n```\n\n只需要多设置 tab 的数量和对应 tab 的 view 。\n\n\u003e 注意：tabCount 要和 tabCell 数量一致。\n\n### 设置 delegate 和 dataSource\n\n```Swift\ntrelloView.delegate = self\ntrelloView.dataSource = self\n```\n\n就和使用 UITableView 一样，和 UITableView 一样实现对应的协议即可~\n\n### 将数据挂在 tableView 上\n\n因为用了多个 tableView ，所以为了区别不同 tab 的数据，我这里将数据放在了对应的 tableView 上。当然，你也可以用自己喜欢的其他方法，如果有更好的想法，欢迎给我提 PR 。\n\n## Tips\n\n项目中 TrelloAnimate 、 TrelloDefine 、 TrelloFunction 、 TrelloListTableView 、 TrelloListTabView 、TrelloListView 、 TrelloView 、 UIViewExt 是必要文件。\n\n为了安全性，挂在 tableView 的数据必须声明数组中的类型，最好不要直接改为 AnyObject 。:]\n\n如果你对 Swift 或者函数式编程很感兴趣，欢迎阅读源码一起学习。:]\n\n## License\n\nMIT","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FDianQK%2FTrelloNavigation","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FDianQK%2FTrelloNavigation","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FDianQK%2FTrelloNavigation/lists"}