{"id":2854,"url":"https://github.com/marty-suzuki/SAInboxViewController","last_synced_at":"2025-08-03T12:31:25.864Z","repository":{"id":36036345,"uuid":"40333171","full_name":"marty-suzuki/SAInboxViewController","owner":"marty-suzuki","description":"UIViewController subclass inspired by \"Inbox by google\" animated transitioning.","archived":true,"fork":false,"pushed_at":"2017-05-07T16:51:22.000Z","size":12020,"stargazers_count":297,"open_issues_count":4,"forks_count":23,"subscribers_count":8,"default_branch":"master","last_synced_at":"2024-04-29T22:07:21.845Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","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/marty-suzuki.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-08-07T00:36:27.000Z","updated_at":"2024-02-23T05:58:00.000Z","dependencies_parsed_at":"2022-08-27T03:15:56.357Z","dependency_job_id":null,"html_url":"https://github.com/marty-suzuki/SAInboxViewController","commit_stats":null,"previous_names":[],"tags_count":8,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marty-suzuki%2FSAInboxViewController","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marty-suzuki%2FSAInboxViewController/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marty-suzuki%2FSAInboxViewController/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marty-suzuki%2FSAInboxViewController/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/marty-suzuki","download_url":"https://codeload.github.com/marty-suzuki/SAInboxViewController/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":228543156,"owners_count":17934433,"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-01-05T20:16:24.579Z","updated_at":"2024-12-07T00:31:01.759Z","avatar_url":"https://github.com/marty-suzuki.png","language":"Swift","funding_links":[],"categories":["UI"],"sub_categories":["Table View / Collection View","Other free courses"],"readme":"# SAInboxViewController\n\n[![Platform](http://img.shields.io/badge/platform-ios-blue.svg?style=flat\n)](https://developer.apple.com/iphone/index.action)\n[![Language](http://img.shields.io/badge/language-swift-brightgreen.svg?style=flat\n)](https://developer.apple.com/swift)\n[![Version](https://img.shields.io/cocoapods/v/SAInboxViewController.svg?style=flat)](http://cocoapods.org/pods/SAInboxViewController)\n[![License](https://img.shields.io/cocoapods/l/SAInboxViewController.svg?style=flat)](http://cocoapods.org/pods/SAInboxViewController)\n\n![](./SampleImage/sample.gif)\n\nSAInboxViewController realizes Inbox like view transitioning.\n\nYou can launch sample project on web browser from [here](https://appetize.io/app/gxu9drpm7cqbe60mjqf2nv59t4?device=iphone5s\u0026scale=75\u0026orientation=portrait).\n\n## Features\n\n- [x] Inbox like view transitioning\n- [x] Scrolling up to begining of contents transitioning\n- [x] Scrolling down to end of contents transitioning\n- [x] Header dragging transitioning\n- [x] Left edge swiping transitioning\n- [x] HeaderView hide animation\n- [ ] Change StatusBar color with scrolling\n- [x] Support Swift3\n- [x] Support Siwft3.1\n\n## Installation\n\n#### CocoaPods\n\nSAHistoryNavigationViewController is available through [CocoaPods](http://cocoapods.org). If you have cocoapods 1.2.0 or greater, you can install\nit, simply add the following line to your Podfile:\n\n\tpod \"SAInboxViewController\"\n\n\n#### Manually\n\nAdd the [SAInboxViewController](./SAInboxViewController) directory to your project.\n\n## Usage\n\nIf you install from cocoapods, you have to write `import SAInboxViewController`.\n\nFirst of all, please use `SAInboxViewController` with `UINavigationController`.\n\nThere are two ViewControllers to realize Inbox transitioning. Please extend those ViewControllers.\n\n1. `SAInboxViewController`... using as rootViewController\n2. `SAInboxDetailViewController`... using as second ViewController\n\nThose ViewControllers have `UITableView`, so implement ordinary `UITableView` behavior with that tableView.\n\nIf you use `UITableViewDelegate` in ViewController which extends `SAInboxDetailViewController`, please call super methods for below two methods.\n\n```swift\noverride func scrollViewDidEndDragging(scrollView: UIScrollView, willDecelerate decelerate: Bool) {\n    super.scrollViewDidEndDragging(scrollView, willDecelerate: decelerate)\n}\n\noverride func scrollViewDidScroll(scrollView: UIScrollView) {\n\tsuper.scrollViewDidScroll(scrollView)\n}\n```\n\nIf you want to present ViewController from rootViewController, implement `func tableView(tableView: UITableView, didSelectRowAtIndexPath indexPath: NSIndexPath)` like this.\n\n```swift\n@objc(tableView:didSelectRowAtIndexPath:)\nfunc tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {\n    let viewController = SAInboxDetailViewController()\n    if let cell = tableView.cellForRow(at: indexPath), let image = headerView.screenshotImage() {\n        SAInboxAnimatedTransitioningController.shared.configureCotainerView(self, cell: cell, cells: tableView.visibleCells, headerImage: image)\n    }\n    navigationController?.pushViewController(viewController, animated: true)\n}\n```\n\nImplement `UINavigationControllerDelegate` methods, like this.\n\n```swift\nfunc navigationController(_ navigationController: UINavigationController, animationControllerFor operation: UINavigationControllerOperation, from fromVC: UIViewController, to toVC: UIViewController) -\u003e UIViewControllerAnimatedTransitioning? {\n    return SAInboxAnimatedTransitioningController.shared.setOperation(operation)\n}\n```\n\n## Customize\nYou can change HeaderView `barTintColor`, `tintColor` and `titleTextAttributes`.  \nThere are 2 ways to change HeaderView Appearance.\n\n#### Application Base Appearance\nSAInboxViewController class has Appearance property\n\n```swift\nSAInboxViewController.appearance.barTintColor = .black\nSAInboxViewController.appearance.tintColor = .white\nSAInboxViewController.appearance.titleTextAttributes = [NSForegroundColorAttributeName : UIColor.white]\n```\n\n#### ViewController Base Appearance\nSAInboxViewController instance has Appearance property.\n\n```swift\noverride func viewDidLoad() {\n    super.viewDidLoad()\n    appearance.barTintColor = .white\n    appearance.tintColor = .black\n    appearance.titleTextAttributes = [NSForegroundColorAttributeName : UIColor.black]\n\n    //Do not forget to set true\n    enabledViewControllerBasedAppearance = true\n}\n```\n\n## Requirements\n\n- Xcode 8.0 or greater\n- iOS 8.0 or greater\n- [MisterFusion](https://github.com/szk-atmosphere/MisterFusion) (Swift DSL for AutoLayout)\n\n## Author\n\nTaiki Suzuki, s1180183@gmail.com\n\n## License\n\nSAInboxViewController is available under the MIT license. See the LICENSE file for more info.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmarty-suzuki%2FSAInboxViewController","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmarty-suzuki%2FSAInboxViewController","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmarty-suzuki%2FSAInboxViewController/lists"}