{"id":32520724,"url":"https://github.com/marinofaggiana/lucidbanner","last_synced_at":"2026-07-02T20:31:15.796Z","repository":{"id":321069144,"uuid":"1084349792","full_name":"marinofaggiana/LucidBanner","owner":"marinofaggiana","description":"Elegant and fully async SwiftUI banner system for iOS — lightweight, customizable, and concurrency-safe.","archived":false,"fork":false,"pushed_at":"2026-03-26T14:45:02.000Z","size":855,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-03-27T04:27:43.187Z","etag":null,"topics":["animation","banner","glassmorphism","hud","ios","ios-development","message","notifications","open-source","swift","swift-package","swiftui","swiftui-animation","swiftui-components","toast","ui-component","uikit"],"latest_commit_sha":null,"homepage":"https://github.com/marinofaggiana/LucidBanner","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/marinofaggiana.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,"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":"2025-10-27T15:05:12.000Z","updated_at":"2026-03-15T00:04:23.000Z","dependencies_parsed_at":"2025-12-07T12:02:03.152Z","dependency_job_id":null,"html_url":"https://github.com/marinofaggiana/LucidBanner","commit_stats":null,"previous_names":["marinofaggiana/lucidbanner"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/marinofaggiana/LucidBanner","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marinofaggiana%2FLucidBanner","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marinofaggiana%2FLucidBanner/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marinofaggiana%2FLucidBanner/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marinofaggiana%2FLucidBanner/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/marinofaggiana","download_url":"https://codeload.github.com/marinofaggiana/LucidBanner/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/marinofaggiana%2FLucidBanner/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":35062686,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-07-02T02:00:06.368Z","response_time":173,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":["animation","banner","glassmorphism","hud","ios","ios-development","message","notifications","open-source","swift","swift-package","swiftui","swiftui-animation","swiftui-components","toast","ui-component","uikit"],"created_at":"2025-10-28T05:48:38.117Z","updated_at":"2026-07-02T20:31:15.789Z","avatar_url":"https://github.com/marinofaggiana.png","language":"Swift","funding_links":[],"categories":[],"sub_categories":[],"readme":"![Swift](https://img.shields.io/badge/Swift-6.0-orange.svg)\n![Platform](https://img.shields.io/badge/platform-iOS_17+-lightgrey.svg)\n![License](https://img.shields.io/badge/license-MIT-green.svg)\n\n\u003cdiv align=\"center\"\u003e\n    \u003cimg src=\"LucidBanner.png\" alt=\"Logo of LucidBanner\" width=\"256\" height=\"256\" /\u003e\n\u003c/div\u003e\n\nSwiftUI-based transient banners rendered in their own `UIWindow` above the status bar.\n\n- No intrusive HUDs\n- Scene-aware (iPad / multi-window)\n- Queueable, updatable, dismissable\n\nOriginally developed for the **Nextcloud iOS** app.  \nAuthor: **Marino Faggiana** • License: **MIT** • Version: **0.0.1**\n\n---\n\n### 🚧 Work in Progress\n\nLucidBanner is currently under **active development**.  \nWhile functional, the library should be considered **experimental**, and its APIs may change as development continues.  \nProduction use is not recommended until a stable 1.0 release.\n\n---\n\n## Features\n\n- **One-at-a-time display** with queueing policies:\n  - `.enqueue` – queue new banners\n  - `.replace` – dismiss current and show the new one\n  - `.drop` – ignore the new request if something is already visible\n- **Flexible layout**\n  - Vertical: `.top`, `.center`, `.bottom`\n  - Horizontal: `.left`, `.center`, `.right`\n  - Safe-area aware margins\n- **Interaction**\n  - Swipe-to-dismiss (direction-aware based on position)\n  - Optional scrim that blocks touches behind the banner\n  - Tap callback: `onTap(token, stage)`\n- **Live updates**\n  - `update(...)` for title / subtitle / footnote / icon / animation / progress / stage\n- **Lifecycle**\n  - Optional auto-dismiss timer\n  - Simple `isAlive(token)` check\n  - Works with multiple scenes (`UIWindowScene`) on iPhone/iPad (iOS 17+)\n\n---\n\n## Requirements\n\n- iOS 17.0+\n- Swift 6.0+\n- SwiftUI + UIKit\n\n---\n\n## Installation (Swift Package Manager)\n\n### Xcode\n\n1. `File → Add Packages…`\n2. Enter the repository URL:\n   ```\n   https://example.com/your-org/LucidBanner.git\n   ```\n3. Choose tag **0.0.1**\n4. Add **LucidBanner** to your target\n\n### Package.swift\n\n```swift\ndependencies: [\n    .package(url: \"https://example.com/your-org/LucidBanner.git\", from: \"0.0.1\")\n]\n```\n\n---\n\n## Quick Start\n\n```swift\nimport SwiftUI\nimport LucidBanner\n\nstruct ContentView: View {\n    @State private var token: Int = 0\n\n    private var currentWindowScene: UIWindowScene? {\n        UIApplication.shared.connectedScenes\n            .compactMap { $0 as? UIWindowScene }\n            .first { $0.activationState == .foregroundActive }\n    }\n\n    var body: some View {\n        VStack(spacing: 16) {\n            Button(\"Show Top Banner\") {\n                guard let scene = currentWindowScene else { return }\n\n                token = LucidBanner.shared.show(\n                    scene: scene,\n                    title: \"Upload started\",\n                    subtitle: \"Keep the app active for best performance\",\n                    systemImage: \"arrow.up.circle\",\n                    imageAnimation: .breathe,\n                    vPosition: .top,\n                    autoDismissAfter: 3.0,\n                    onTap: { token, stage in\n                        print(\"Banner tapped: token = \\(token), stage = \\(stage ?? \"nil\")\")\n                    }\n                ) { state in\n                    ToastBannerView(state: state)\n                }\n            }\n\n            Button(\"Update Progress\") {\n                LucidBanner.shared.update(\n                    progress: 0.66,\n                    stage: \"uploading\",\n                    for: token\n                )\n            }\n\n            Button(\"Dismiss\") {\n                LucidBanner.shared.dismiss(for: token)\n            }\n        }\n        .padding()\n    }\n}\n```\n\nSwiftUI banner example:\n\n```swift\nstruct ToastBannerView: View {\n    @ObservedObject var state: LucidBannerState\n\n    var body: some View {\n        HStack(spacing: 12) {\n            if let systemImage = state.systemImage {\n                Image(systemName: systemImage)\n                    .font(.system(size: 20, weight: .semibold))\n            }\n\n            VStack(alignment: .leading, spacing: 2) {\n                if let title = state.title {\n                    Text(title)\n                        .font(.headline)\n                }\n                if let subtitle = state.subtitle {\n                    Text(subtitle)\n                        .font(.subheadline)\n                        .foregroundStyle(.secondary)\n                }\n                if let footnote = state.footnote {\n                    Text(footnote)\n                        .font(.footnote)\n                        .foregroundStyle(.secondary)\n                }\n                if let progress = state.progress {\n                    ProgressView(value: progress)\n                        .progressViewStyle(.linear)\n                }\n            }\n\n            Spacer()\n        }\n        .padding(12)\n        .background(.regularMaterial, in: RoundedRectangle(cornerRadius: 14))\n        .shadow(radius: 12, y: 4)\n    }\n}\n```\n\n---\n\n## License\n\nMIT License. See `LICENSE` file.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmarinofaggiana%2Flucidbanner","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmarinofaggiana%2Flucidbanner","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmarinofaggiana%2Flucidbanner/lists"}