[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-6669":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":10,"language":11,"languages":10,"totalLinesOfCode":10,"stars":12,"forks":13,"watchers":14,"openIssues":15,"contributorsCount":16,"subscribersCount":16,"size":16,"stars1d":16,"stars7d":17,"stars30d":18,"stars90d":16,"forks30d":16,"starsTrendScore":16,"compositeScore":19,"rankGlobal":10,"rankLanguage":10,"license":20,"archived":21,"fork":21,"defaultBranch":22,"hasWiki":23,"hasPages":23,"topics":24,"createdAt":10,"pushedAt":10,"updatedAt":42,"readmeContent":43,"aiSummary":44,"trendingCount":16,"starSnapshotCount":16,"syncStatus":45,"lastSyncTime":46,"discoverSource":47},6669,"Hero","HeroTransitions\u002FHero","HeroTransitions","Elegant transition library for iOS & tvOS","https:\u002F\u002FHeroTransitions.github.io\u002FHero\u002F",null,"Swift",22462,1737,357,40,0,3,18,73.02,"MIT License",false,"develop",true,[25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41],"animation","animations","carthage","custom-transitions","hero","ios","ios-animation","ios-framework","ios-lib","ios-swift","ios-transition","layout","material-design","swift","swiftpm","transition-animation","xcode","2026-06-12 04:00:29","\u003Cimg src=\"https:\u002F\u002Fcdn.rawgit.com\u002Flkzhao\u002FHero\u002F427d5f2\u002FResources\u002FHero.svg\" width=\"388\"\u002F>\n\n**Hero** is a library for building iOS view controller transitions. It provides a declarative layer on top of the UIKit's cumbersome transition APIs—making custom transitions an easy task for developers.\n\n[![Carthage compatible](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FCarthage-Compatible-brightgreen.svg?style=flat)](https:\u002F\u002Fgithub.com\u002FCarthage\u002FCarthage)\n[![Accio supported](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FAccio-supported-0A7CF5.svg?style=flat)](https:\u002F\u002Fgithub.com\u002FJamitLabs\u002FAccio)\n[![codecov](https:\u002F\u002Fcodecov.io\u002Fgh\u002FHeroTransitions\u002FHero\u002Fbranch\u002Fdevelop\u002Fgraph\u002Fbadge.svg)](https:\u002F\u002Fcodecov.io\u002Fgh\u002FHeroTransitions\u002FHero)\n[![Version](https:\u002F\u002Fimg.shields.io\u002Fcocoapods\u002Fv\u002FHero.svg?style=flat)](http:\u002F\u002Fcocoapods.org\u002Fpods\u002FHero)\n[![License](https:\u002F\u002Fimg.shields.io\u002Fcocoapods\u002Fl\u002FHero.svg?style=flat)](https:\u002F\u002Fgithub.com\u002Flkzhao\u002FHero\u002Fblob\u002Fmaster\u002FLICENSE?raw=true)\n![Xcode 10.0+](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FXcode-10.0%2B-blue.svg)\n![iOS 10.0+](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FiOS-10.0%2B-blue.svg)\n![Swift 4.0+](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FSwift-4.0%2B-orange.svg)\n[![中文 README](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002F%E4%B8%AD%E6%96%87-README-blue.svg?style=flat)](https:\u002F\u002Fgithub.com\u002Flkzhao\u002FHero\u002Fblob\u002Fmaster\u002FREADME.zh-cn.md)\n[![Donate](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FDonate-PayPal-blue.svg)](https:\u002F\u002Fwww.paypal.com\u002Fcgi-bin\u002Fwebscr?cmd=_s-xclick&hosted_button_id=NT5F7Y2MPV7RE)\n\n[![Unit Test](https:\u002F\u002Fgithub.com\u002FHeroTransitions\u002FHero\u002Factions\u002Fworkflows\u002Ftest.yml\u002Fbadge.svg)](https:\u002F\u002Fgithub.com\u002FHeroTransitions\u002FHero\u002Factions\u002Fworkflows\u002Ftest.yml)\n[![Swift PM](https:\u002F\u002Fgithub.com\u002FHeroTransitions\u002FSwiftPMTest\u002Factions\u002Fworkflows\u002Fspm.yml\u002Fbadge.svg)](https:\u002F\u002Fgithub.com\u002FHeroTransitions\u002FSwiftPMTest\u002Factions\u002Fworkflows\u002Fspm.yml)\n\n\u003Cimg src=\"https:\u002F\u002Fcdn.rawgit.com\u002Flkzhao\u002FHero\u002Febb3f2c\u002FResources\u002Ffeatures.svg\"\u002F>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\n\u003Cimg src=\"https:\u002F\u002Fcdn.rawgit.com\u002Flkzhao\u002FHero\u002Febb3f2c\u002FResources\u002Ffeatures2.svg\"\u002F>\n\nHero is similar to Keynote's **Magic Move**. It checks the `heroID` property on all source and destination views. Every matched view pair is then automatically transitioned from its old state to its new state.\n\nHero can also construct animations for unmatched views. It is easy to define these animations via the `heroModifiers` property. Hero will run these animations alongside the **Magic Move** animations. All of these animations can be **interactively controlled** by user gestures.\n\nAt view controller level, Hero provides several template transitions that you can set through `heroModalAnimationType`, `heroNavigationAnimationType`, and `heroTabBarAnimationType`. These can be used as the foundation of your custom transitions. Combine with `heroID` & `heroModifiers` to make your own unique transitions.\n\n\u003Cimg src=\"https:\u002F\u002Fcdn.rawgit.com\u002Flkzhao\u002FHero\u002Febb3f2c\u002FResources\u002FdefaultAnimations.svg\"\u002F>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\n\u003Cimg src=\"https:\u002F\u002Fcdn.rawgit.com\u002Flkzhao\u002FHero\u002Febb3f2c\u002FResources\u002FdefaultAnimations2.svg\"\u002F>\n\nBy default, Hero provides **dynamic duration** based on the [Material Design Motion Guide](https:\u002F\u002Fmaterial.io\u002Fdesign\u002Fmotion\u002Fspeed.html#easing). Duration is automatically determined by changes to distance and size—saving you the hassle, while providing consistent and delightful animations.\n\nHero doesn't make any assumptions about how the view is built or structured. It won't modify any of your views' states other than hiding them during the animation. This makes it work with **Auto Layout**, **programmatic layout**, **UICollectionView** (without modifying its layout object), **UITableView**, **UINavigationController**, **UITabBarController**, etc...\n\n## Usage Example 1\n\n\u003Cimg src=\"https:\u002F\u002Fcdn.rawgit.com\u002Flkzhao\u002FHero\u002Febb3f2c\u002FResources\u002Fsimple.svg\" \u002F>\n\n### View Controller 1\n\n```swift\nredView.hero.id = \"ironMan\"\nblackView.hero.id = \"batMan\"\n```\n\n### View Controller 2\n\n```swift\nself.hero.isEnabled = true\nredView.hero.id = \"ironMan\"\nblackView.hero.id = \"batMan\"\nwhiteView.hero.modifiers = [.translate(y:100)]\n```\n\n## Usage Example 2\n\n\u003Cimg src=\"https:\u002F\u002Fcdn.rawgit.com\u002Flkzhao\u002FHero\u002Febb3f2c\u002FResources\u002Fadvanced.svg\" \u002F>\n\n### View Controller 1\n\n```swift\ngreyView.hero.id = \"skyWalker\"\n```\n\n### View Controller 2\n\n```swift\nself.hero.isEnabled = true\ngreyView.hero.id = \"skyWalker\"\n\n\u002F\u002F collectionView is the parent view of all red cells\ncollectionView.hero.modifiers = [.cascade]\nfor cell in redCells {\n    cell.hero.modifiers = [.fade, .scale(0.5)]\n}\n```\n\nYou can do these in the **storyboard** too!\n\n\u003Cimg src=\"https:\u002F\u002Fcdn.rawgit.com\u002Flkzhao\u002FHero\u002Fmaster\u002FResources\u002FstoryboardView.png\" width=\"267px\"\u002F>\n\u003Cimg src=\"https:\u002F\u002Fcdn.rawgit.com\u002Flkzhao\u002FHero\u002Fmaster\u002FResources\u002FstoryboardViewController.png\" width=\"267px\"\u002F>\n\n## Installation\n\n### CocoaPods\n\nAdd the following entry to your Podfile:\n\n```rb\npod 'Hero'\n```\n\nThen run `pod install`.\n\nDon't forget to `import Hero` in every file you'd like to use Hero.\n\n### Carthage\n\nAdd the following entry to your `Cartfile`:\n\n```text\ngithub \"HeroTransitions\u002FHero\"\n```\n\nThen run `carthage update`.\n\nIf this is your first time using Carthage in the project, you'll need to go through some additional steps as explained [over at Carthage](https:\u002F\u002Fgithub.com\u002FCarthage\u002FCarthage#adding-frameworks-to-an-application).\n\n### Accio\n\nAdd the following to your `Package.swift`:\n\n```swift\n.package(url: \"https:\u002F\u002Fgithub.com\u002FHeroTransitions\u002FHero.git\", .upToNextMajor(from: \"1.4.0\")),\n```\n\nNext, add `Hero` to your App targets dependencies like so:\n\n```swift\n.target(\n    name: \"App\",\n    dependencies: [\n        \"Hero\",\n    ]\n),\n```\n\nThen run `accio update`.\n\n### Swift Package Manager\n\nTo integrate using Apple's Swift package manager, add the following as a dependency to your `Package.swift`:\n\n```swift\n.package(url: \"https:\u002F\u002Fgithub.com\u002FHeroTransitions\u002FHero.git\", .upToNextMajor(from: \"1.3.0\"))\n```\n\nand then specify `\"Hero\"` as a dependency of the Target in which you wish to use Hero.\nHere's an example `PackageDescription`:\n\n```swift\n\u002F\u002F swift-tools-version:4.0\nimport PackageDescription\n\nlet package = Package(\n    name: \"MyPackage\",\n    products: [\n        .library(\n            name: \"MyPackage\",\n            targets: [\"MyPackage\"]),\n    ],\n    dependencies: [\n        .package(url: \"https:\u002F\u002Fgithub.com\u002FHeroTransitions\u002FHero.git\", .upToNextMajor(from: \"1.6.3\"))\n    ],\n    targets: [\n        .target(\n            name: \"MyPackage\",\n            dependencies: [\"Hero\"])\n    ]\n)\n```\n\n### Manually\n\n- Drag the **Sources** folder anywhere in your project.\n\n## Documentations\n\nCheckout the **[WIKI PAGES (Usage Guide)](https:\u002F\u002Fgithub.com\u002Flkzhao\u002FHero\u002Fwiki\u002FUsage-Guide)** for documentations.\n\nFor more up-to-date ones, please see the header-doc. (use **alt+click** in Xcode)\n\u003Cimg src=\"https:\u002F\u002Fcdn.rawgit.com\u002Flkzhao\u002FHero\u002Fmaster\u002FResources\u002FheaderDoc.png\" width=\"521px\"\u002F>\n\nDash compatible API docs: https:\u002F\u002FHeroTransitions.github.io\u002FHero\u002F\n\n## Interactive Transition Tutorials\n\n[Interactive transitions with Hero (Part 1)](https:\u002F\u002Flkzhao.gitbooks.io\u002Fhero\u002Fcontent\u002Fdocs\u002FInteractiveTransition.html)\n\n## FAQ\n\n### Not able to use Hero transition even when `self.hero.isEnabled` is set to true\n\nMake sure that you have also enabled `self.hero.isEnabled` on the navigation controller if you are doing a push\u002Fpop inside the navigation controller.\n\n### Views being covered by another matched view during the transition\n\nMatched views use global coordinate space while unmatched views use local coordinate space by default. Local coordinate spaced views might be covered by other global coordinate spaced views. To solve this, use the `useGlobalCoordinateSpace` modifier on the views being covered. Checkout [Coordinate Space Wiki page](https:\u002F\u002Fgithub.com\u002Flkzhao\u002FHero\u002Fwiki\u002FCoordinate-Space) for details.\n\n### Push animation is shown along side my custom animation\n\nThis is the default animation for navigation controller provided by Hero. To disable the push animation, set `self.hero.navigationAnimationType` to `.fade` or `.none` on the navigation controller.\n\n### How do I use a different default animation when dismissing\n\nYou can use the animation type `.selectBy(presenting:dismissing)` to specify a different default animation for dismiss.\n\nFor example:\n\n```swift\n    self.hero.modalAnimationType = .selectBy(presenting:.zoom, dismissing:.zoomOut)\n```\n\n## Contribute\n\nWe welcome any contributions. Please read the [Contribution Guide](https:\u002F\u002Fgithub.com\u002Flkzhao\u002FHero\u002Fwiki\u002FContribution-Guide).\n","Hero 是一个用于构建 iOS 和 tvOS 应用中视图控制器过渡效果的优雅动画库。它在 UIKit 复杂的过渡 API 上提供了一个声明式的层，简化了自定义过渡动画的实现过程。其核心功能包括通过 `heroID` 属性自动匹配源视图和目标视图，并平滑地过渡它们的状态；同时支持为未匹配视图定义动画并通过 `heroModifiers` 属性进行调整。此外，Hero 还提供了多种预设的过渡模式，如模态、导航栏及标签栏动画类型，便于开发者快速集成高质量的界面转换效果。此库适用于希望增强应用视觉体验、提升用户交互流畅度的各种iOS开发场景。",2,"2026-06-11 03:08:14","top_language"]