{"id":15066944,"url":"https://github.com/wiedem/fullscreen-cover","last_synced_at":"2026-03-10T23:19:29.787Z","repository":{"id":256470649,"uuid":"850789523","full_name":"wiedem/fullscreen-cover","owner":"wiedem","description":"Custom full-screen modal transitions for SwiftUI with async present/dismiss coordination","archived":false,"fork":false,"pushed_at":"2026-02-28T02:14:49.000Z","size":154,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-02-28T10:24:30.557Z","etag":null,"topics":["animations","fullscreen","ios","modals","swift","swift-package-manager","swiftui","transitions"],"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/wiedem.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2024-09-01T19:27:36.000Z","updated_at":"2026-02-28T02:14:52.000Z","dependencies_parsed_at":"2025-01-22T16:13:06.979Z","dependency_job_id":"8078d18a-eff2-4c28-9ae8-819653a21583","html_url":"https://github.com/wiedem/fullscreen-cover","commit_stats":null,"previous_names":["wiedem/fullscreen-cover"],"tags_count":10,"template":false,"template_full_name":null,"purl":"pkg:github/wiedem/fullscreen-cover","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wiedem%2Ffullscreen-cover","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wiedem%2Ffullscreen-cover/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wiedem%2Ffullscreen-cover/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wiedem%2Ffullscreen-cover/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/wiedem","download_url":"https://codeload.github.com/wiedem/fullscreen-cover/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wiedem%2Ffullscreen-cover/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30361462,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-10T21:41:54.280Z","status":"ssl_error","status_checked_at":"2026-03-10T21:40:59.357Z","response_time":106,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["animations","fullscreen","ios","modals","swift","swift-package-manager","swiftui","transitions"],"created_at":"2024-09-25T01:14:08.716Z","updated_at":"2026-03-10T23:19:29.781Z","avatar_url":"https://github.com/wiedem.png","language":"Swift","funding_links":[],"categories":[],"sub_categories":[],"readme":"# FullScreenCover\n\n![Swift 6.1](https://img.shields.io/badge/Swift-6.1-orange)\n![iOS 16.4+](https://img.shields.io/badge/iOS-16.4%2B-blue)\n![Swift Package Manager](https://img.shields.io/badge/SPM-compatible-brightgreen)\n![MIT License](https://img.shields.io/badge/License-MIT-yellow)\n\n**FullScreenCover** presents full-screen modal views in SwiftUI, building on [`.fullScreenCover`](https://developer.apple.com/documentation/swiftui/view/fullscreencover(ispresented:ondismiss:content:)) and adding what's missing:\n\n- Use any SwiftUI transition instead of the fixed slide-up animation\n- `await present()` and `await dismiss()` to safely chain sequential operations without callback workarounds\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"https://raw.githubusercontent.com/wiedem/fullscreen-cover/assets/custom_transition.gif\" alt=\"Custom Transition Demo\" width=\"280\"\u003e\u0026nbsp;\u0026nbsp;\u0026nbsp;\u0026nbsp;\n  \u003cimg src=\"https://raw.githubusercontent.com/wiedem/fullscreen-cover/assets/async_coordination.gif\" alt=\"Async Coordination Demo\" width=\"280\"\u003e\n\u003c/p\u003e\n\n## Usage\n\nAdd `import FullScreenCover` to your source code. Wrap your view with a `PresentationCoordinator` and pass its proxy to the `fullScreenCover(presentation:animation:content:)` modifier.\n\n### Custom Transition Animations\n\nUse **any SwiftUI transition**:\n\n```swift\nimport FullScreenCover\nimport SwiftUI\n\nstruct DemoView: View {\n    var body: some View {\n        PresentationCoordinator { proxy in\n            Button(\"Present Modal\") {\n                Task { try await proxy.present() }\n            }\n            .fullScreenCover(presentation: proxy, animation: .spring(duration: 0.5)) {\n                ZStack {\n                    Color.black.opacity(0.5)\n                        .ignoresSafeArea()\n\n                    VStack(spacing: 16) {\n                        Text(\"Custom modal content\")\n                            .font(.title)\n\n                        Button(\"Dismiss\") {\n                            Task { try await proxy.dismiss() }\n                        }\n                    }\n                }\n                .transition(.scale(scale: 0.8).combined(with: .opacity))\n            }\n        }\n    }\n}\n```\n\nUse the [transition(_:)](https://developer.apple.com/documentation/swiftui/view/transition%28_%3A%29-5h5h0) modifier on your modal content to define your custom animation. The `animation` parameter on `fullScreenCover` controls the timing.\n\nThe presentation background is automatically set to transparent so that custom transitions render correctly. You can override it by applying `.presentationBackground(_:)` to your modal content.\n\n### Async Coordination\n\nBoth `present()` and `dismiss()` are `async` and return only after the transition has completed. This makes it safe to **chain sequential operations**:\n\n```swift\nButton(\"Show Confirmation\") {\n    Task {\n        // present() returns once the modal content has appeared.\n        try await proxy.present()\n\n        // Do some work while the modal is visible...\n        try await performNetworkRequest()\n\n        // dismiss() returns after the dismiss animation finishes.\n        try await proxy.dismiss()\n\n        // Safe to continue, e.g. navigate or show another modal.\n        navigateToNextScreen()\n    }\n}\n```\n\nBoth methods throw `CancellationError` if the calling task is cancelled. The transition itself continues unaffected - only the caller stops waiting.\n\n### Presentation Phase\n\nThe proxy exposes a `phase` property of type `PresentationPhase` that tracks the current lifecycle state: `idle`, `presenting`, `presented`, or `dismissing`. Use it to adapt your UI during transitions:\n\n```swift\nPresentationCoordinator { proxy in\n    Button(\"Present\") {\n        Task { try await proxy.present() }\n    }\n    .disabled(proxy.phase != .idle)\n}\n```\n\n### Accessing the Proxy in Child Views\n\nThe `PresentationProxy` is automatically injected as an `EnvironmentObject`. Child views can access it without passing it through manually:\n\n```swift\nstruct DismissButton: View {\n    @EnvironmentObject private var proxy: PresentationProxy\n\n    var body: some View {\n        Button(\"Close\") {\n            Task { try await proxy.dismiss() }\n        }\n    }\n}\n```\n\n## Installation\n\nAdd the package to the dependencies in your `Package.swift` file:\n\n```swift\n.package(url: \"https://github.com/wiedem/fullscreen-cover\", .upToNextMajor(from: \"2.0.0\")),\n```\n\nThen include `\"FullScreenCover\"` as a dependency for your target:\n\n```swift\ndependencies: [\n    .product(name: \"FullScreenCover\", package: \"fullscreen-cover\"),\n]\n```\n\n### Requirements\n\n- iOS 16.4+\n- Swift 6.1+\n- Xcode 16.3+\n\n## Contributing\n\nContributions are welcome! Please feel free to:\n\n- Report bugs or request features via [GitHub Issues](https://github.com/wiedem/fullscreen-cover/issues)\n- Submit pull requests with improvements\n- Improve documentation or add examples\n- Share feedback on API design\n\n## License\n\nFullScreenCover is available under the MIT License. See [LICENSE.txt](LICENSE.txt) for more information.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwiedem%2Ffullscreen-cover","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwiedem%2Ffullscreen-cover","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwiedem%2Ffullscreen-cover/lists"}