{"id":16685949,"url":"https://github.com/danielsaidi/scrollkit","last_synced_at":"2025-05-15T10:01:54.446Z","repository":{"id":65692287,"uuid":"597412276","full_name":"danielsaidi/ScrollKit","owner":"danielsaidi","description":"ScrollKit is a SwiftUI SDK that adds powerful scroll features, like offset tracking and a header view that stretches \u0026 transforms as you pull down, and sticks to the top when you scroll.","archived":false,"fork":false,"pushed_at":"2025-05-02T09:26:09.000Z","size":15331,"stargazers_count":788,"open_issues_count":1,"forks_count":31,"subscribers_count":5,"default_branch":"main","last_synced_at":"2025-05-02T10:34:30.791Z","etag":null,"topics":["ios","macos","scrollview","sticky-header","swiftui","tvos","visionos","watchos"],"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/danielsaidi.png","metadata":{"files":{"readme":"README.md","changelog":null,"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,"zenodo":null},"funding":{"github":["danielsaidi"]}},"created_at":"2023-02-04T13:24:58.000Z","updated_at":"2025-05-02T09:26:13.000Z","dependencies_parsed_at":"2024-03-13T22:30:46.110Z","dependency_job_id":"0dc62e7f-9dc9-4542-916a-4ab5afeaa621","html_url":"https://github.com/danielsaidi/ScrollKit","commit_stats":{"total_commits":84,"total_committers":3,"mean_commits":28.0,"dds":0.04761904761904767,"last_synced_commit":"d1642f705834ca7718458885d838671c51ca2e17"},"previous_names":[],"tags_count":11,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/danielsaidi%2FScrollKit","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/danielsaidi%2FScrollKit/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/danielsaidi%2FScrollKit/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/danielsaidi%2FScrollKit/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/danielsaidi","download_url":"https://codeload.github.com/danielsaidi/ScrollKit/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254319717,"owners_count":22051072,"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":["ios","macos","scrollview","sticky-header","swiftui","tvos","visionos","watchos"],"created_at":"2024-10-12T15:03:57.660Z","updated_at":"2025-05-15T10:01:53.486Z","avatar_url":"https://github.com/danielsaidi.png","language":"Swift","readme":"\u003cp align=\"center\"\u003e\n    \u003cimg src=\"Resources/Icon.png\" alt=\"Project Icon\" width=\"250\" /\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n    \u003cimg src=\"https://img.shields.io/github/v/release/danielsaidi/ScrollKit?color=%2300550\u0026sort=semver\" alt=\"Version\" title=\"Version\" /\u003e\n    \u003cimg src=\"https://img.shields.io/badge/swift-6.0-orange.svg\" alt=\"Swift 6.0\" /\u003e\n    \u003cimg src=\"https://img.shields.io/badge/platform-SwiftUI-blue.svg\" alt=\"Swift UI\" title=\"SwiftUI\" /\u003e\n    \u003ca href=\"https://danielsaidi.github.io/ScrollKit\"\u003e\u003cimg src=\"https://img.shields.io/badge/documentation-web-blue.svg\" alt=\"Documentation\" /\u003e\u003c/a\u003e\n    \u003cimg src=\"https://img.shields.io/github/license/danielsaidi/ScrollKit\" alt=\"MIT License\" title=\"MIT License\" /\u003e\n\u003c/p\u003e\n\n\n\n# ScrollKit\n\nScrollKit is a SwiftUI SDK that adds powerful scroll features, like offset tracking and a header view that stretches \u0026 transforms as you pull down, and sticks to the top when you scroll.\n\n\u003cp align=\"center\" style=\"border-radius: 10px\"\u003e\n    \u003cimg src=\"Resources/Demo.gif\" width=425 /\u003e\n\u003c/p\u003e\n\nScrollKit works on all major Apple platforms and is designed to be easy to use. It doesn't use the new `ScrollView` APIs for backwards compatibility reasons, but will eventually do so.\n\n\n\n## Installation\n\nScrollKit can be installed with the Swift Package Manager:\n\n```\nhttps://github.com/danielsaidi/ScrollKit.git\n```\n\n\n\n## Getting started\n\nScrollKit has a `ScrollViewWithOffsetTracking` that can detect scrolling on all OS versions:\n\n```swift\nScrollViewWithOffsetTracking { offset in\n    print(offset)\n} content: {\n    // Add your scroll content here, e.g. a `LazyVStack`\n}\n```\n\nScrollKit has a `ScrollViewWithStickyHeader` that makes it easy to set up a stretchy, sticky header:\n\n```swift\nimport SwiftUI\nimport ScrollKit\n\nstruct MyView: View {\n\n    @State\n    private var scrollOffset = CGPoint.zero\n\n    @State\n    private var visibleRatio = CGFloat.zero\n\n    var body: some View {\n        ScrollViewWithStickyHeader(\n            header: stickyHeader,   // A header view\n            headerHeight: 250,      // The resting header height\n            headerMinHeight: 150,   // The minimum header height\n            headerStretch: false,   // Disables the stretch effect\n            contentCornerRadius: 20, // An optional corner radius mask\n            onScroll: handleScroll  // An optional scroll handler action\n        ) {\n            // Add your scroll content here, e.g. a `LazyVStack`\n        }\n    }\n\n    func handleScroll(_ offset: CGPoint, visibleHeaderRatio: CGFloat) {\n        self.scrollOffset = offset\n        self.visibleRatio = visibleHeaderRatio\n    }\n\n    func stickyHeader() -\u003e some View {\n        ZStack {\n            Color.red\n            ScrollViewHeaderGradient()  // By default a dark gradient\n            Text(\"Scroll offset: \\(scrollOffset.y)\")\n        }\n    }\n}\n```\n\nFor more information, please see the [getting started guide][Getting-Started].\n\n\n\n## Documentation\n\nThe [online documentation][Documentation] has more information, articles, code examples, etc.\n\n\n\n## Demo Application\n\nThe demo app lets you explore the library. To try it out, just open and run the `Demo` project.\n\n\n\n## Support my work\n\nYou can [sponsor me][Sponsors] on GitHub Sponsors or [reach out][Email] for paid support, to help support my [open-source projects][OpenSource].\n\nYour support makes it possible for me to put more work into these projects and make them the best they can be.\n\n\n\n## Contact\n\nFeel free to reach out if you have questions or want to contribute in any way:\n\n* Website: [danielsaidi.com][Website]\n* E-mail: [daniel.saidi@gmail.com][Email]\n* Bluesky: [@danielsaidi@bsky.social][Bluesky]\n* Mastodon: [@danielsaidi@mastodon.social][Mastodon]\n\n\n\n## License\n\nScrollKit is available under the MIT license. See the [LICENSE][License] file for more info.\n\n\n\n[Email]: mailto:daniel.saidi@gmail.com\n[Website]: https://danielsaidi.com\n[GitHub]: https://github.com/danielsaidi\n[OpenSource]: https://danielsaidi.com/opensource\n[Sponsors]: https://github.com/sponsors/danielsaidi\n\n[Bluesky]: https://bsky.app/profile/danielsaidi.bsky.social\n[Mastodon]: https://mastodon.social/@danielsaidi\n[Twitter]: https://twitter.com/danielsaidi\n\n[Documentation]: https://danielsaidi.github.io/ScrollKit/\n[Getting-Started]: https://danielsaidi.github.io/ScrollKit/documentation/scrollkit/getting-started-article\n[License]: https://github.com/danielsaidi/ScrollKit/blob/master/LICENSE\n","funding_links":["https://github.com/sponsors/danielsaidi"],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdanielsaidi%2Fscrollkit","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdanielsaidi%2Fscrollkit","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdanielsaidi%2Fscrollkit/lists"}