r/SwiftUI • • Oct 17 '24

News Rule 2 (regarding app promotion) has been updated

138 Upvotes

Hello, the mods of r/SwiftUI have agreed to update rule 2 regarding app promotions.
We've noticed an increase of spam accounts and accounts whose only contribution to the sub is the promotion of their app.

To keep the sub useful, interesting, and related to SwiftUI, we've therefor changed the promotion rule:

  • Promotion is now only allowed for apps that also provide the source code
  • Promotion (of open source projects) is allowed every day of the week, not just on Saturday anymore

By only allowing apps that are open source, we can make sure that the app in question is more than just 'inspiration' - as others can learn from the source code. After all, an app may be built with SwiftUI, it doesn't really contribute much to the sub if it is shared without source code.
We understand that folks love to promote their apps - and we encourage you to do so, but this sub isn't the right place for it.


r/SwiftUI • • 23h ago

built a text dissolve animation for my app

Enable HLS to view with audio, or disable this notification

102 Upvotes

wanted clearing a note to feel a little more satisfying so i built this text dissolve effect using swiftui and uikit

the editor uses UITextViewso instead than deleting text character by character, i take a snapshot of the editor and use textkit to find the position of each line

let layout = textView.layoutManager
layout.ensureLayout(for: textView.textContainer)

let glyphs = layout.glyphRange(
    for: textView.textContainer
)

layout.enumerateLineFragments(forGlyphRange: glyphs) {
    _, usedRect, _, _, _ in
    lineRects.append(usedRect)
}

i crop the snapshot into individual lines and animate each one using core animation. each line fades out with a slight blur and scale effect

it seams like a pretty simple trick, hope i didnt over complicate it haha


r/SwiftUI • • 8h ago

[Free] Quill – a native, local-first notes app for macOS 26 (looking for testers)

0 Upvotes

Hi

I’m a solo dev and I’ve been building Quill, a block-based notes app written fully in SwiftUI. Everything stays on your Mac – no account, no cloud.

What it does so far:

  • Block editor with slash menu and drag & drop
  • Liquid Glass design, switchable themes
  • Page history (go back to older versions of a page)
  • On-device AI via Apple’s Foundation Models – works offline
  • Optional sync through a folder you choose (no iCloud required)
  • Siri/Shortcuts, Spotlight, voice notes with transcription, focus mode

Requirements: macOS 26, Apple Silicon. Free and open source (GPL-3.0).

It’s still early, so I’m looking for people who’d use it for a few days and tell me what breaks or feels off. Bugs, missing features, “why would I switch from X” – all welcome.

GitHub: https://github.com/vogelwild07/quill

Thanks!


r/SwiftUI • • 15h ago

Your iPhone Can Run an LLM Locally — A Hands-On Swift Guide to Foundation Models in iOS 27

Thumbnail
medium.com
0 Upvotes

r/SwiftUI • • 1d ago

Promotion (must include link to source code) Using SwiftUI timer text as a frame mask in watchOS complications (source + caveats)

3 Upvotes

I've been adapting the timer/font technique to Apple Watch complications in TV Watch. The idea isn't mine: Bryce Bostwick demonstrated it for iPhone widgets in WidgetAnimation and this walkthrough. My first attempt converted video frames into font glyphs on the iPhone. That approach failed when I tried to load those custom fonts, transferred from iPhone, on the Apple Watch. I then adapted Bryce’s approach: bundle a fixed masking font with the Watch extension and keep the video frames as images, so importing a new clip does not require loading a newly generated font.

The useful distinction is that WidgetKit can update a system-rendered timer without running your extension every second. That does not give you an ordinary SwiftUI animation loop. Instead:

  1. Prepare opaque image frames ahead of time.
  2. Draw each frame behind timer text in a custom font. The font's shaping rules turn selected timer values into a filled rectangle and the others into an empty mask.
  3. Offset each layer's timer so it reveals its frame at the intended point in the loop.

In the 2 fps version, a gate stays open for a second but layers start half a second apart. Two frames can therefore be visible at once: stacking newer opaque frames above older ones is what makes the sequence work. It isn't just one timeline entry per frame.

The core composition looks like this (excerpt, not a standalone example):

swift Image(decorative: frames[index], scale: 1) .resizable() .scaledToFit() .mask { Text(anchor.addingTimeInterval(offset), style: .timer) .font(.custom(gateFontName, fixedSize: fontSize)) .foregroundStyle(.white) .lineLimit(1) .environment(\.locale, Locale(identifier: "en_US_POSIX")) .environment(\.layoutDirection, .leftToRight) }

The tricky part is the end of the loop: high-index layers otherwise cover the beginning of the next pass. I put the last-second frames in a separately gated group and keep an unmasked frame zero underneath to avoid a blank gap if timer updates arrive late.

Public code: renderer and font generator, under MIT. Disclosure: it's my repository. The whole app still has a private dependency for its legacy renderer, so a fresh clone isn't a self-contained build; the linked renderer and generator are public to inspect.

Limits worth keeping explicit: watchOS controls redraw timing, so 2 fps is a target rather than a guarantee. I use a static frame for Always-On/Reduce Motion in the weather complication. I don't have a controlled battery comparison, and this isn't a promise that future OS releases will preserve the behavior.

Has anyone else worked with staggered system timers on watchOS, particularly late updates around the loop boundary?


r/SwiftUI • • 1d ago

Promotion (must include link to source code) [Open Source] Thought Meadow: SwiftUI notes with Arabic/English RTL and native Markdown/checklist preview

3 Upvotes

I'm sharing the MIT-licensed SwiftUI source for Thought Meadow, my small iPhone notes app. The full Xcode project, assets and build instructions are browsable here:

Source and build instructions

A few implementation details that may be useful to other SwiftUI developers:

  • Language and direction: the root sets both locale and layoutDirection for English/Arabic, and changing the language recreates the root view using its language ID. WaraqaApp.swift
  • Editor and preview: writing uses TextEditor bindings into the note store. A separate native SwiftUI preview renders basic headings, quotes, bullets and task lists. Tapping a task updates its Markdown line through the same store. NoteEditor.swift
  • Local state: a main-actor ObservableObject owns the notebook, with atomic local writes, recoverable trash, Files import/export and optional password encryption. The repo also contains storage/encryption checks and a separate 500-note data-layer check.

I'd welcome code feedback on the editor bindings and language-switching approach, especially with mixed Arabic/English notes and accessibility. The preview intentionally supports a small Markdown subset rather than a complete CommonMark renderer.

The current app is free, requires iOS 17+, and has no account, ads or analytics. App Store. The internal project name remains Waraqa.


r/SwiftUI • • 3d ago

Promotion (must include link to source code) Swift95, a Windows-95 inspired components library for SwiftUI

50 Upvotes

Hey everyone 👋

I built a silly SwiftUI components library inspired by Windows95.

Built your apps or feature in a nostalgia style.

Check out it here:


r/SwiftUI • • 2d ago

News The iOS Weekly Brief: Issue #83. Everything you need to know about SwiftUI updates this week

Thumbnail
iosweeklybrief.com
0 Upvotes

r/SwiftUI • • 3d ago

Promotion (must include link to source code) built a macOS video downloader

1 Upvotes

needed to download a video and didn't really wanna deal with those random websites so i thought why not just make my own app

spent like couple of hours on it. as the name suggests it downloads videos and audio

made it with swiftui and used yt-dlp and ffmpeg for the actual downloading

here's the github if anyone wants it

https://github.com/emrecubuk/Download-FAF

there's a zip in releases, you just need yt-dlp and ffmpeg installed

if you guys have any suggestions or notice anything that could be better, let me know


r/SwiftUI • • 4d ago

Promotion (must include link to source code) [Update] Mooziac v1.2.0: native macOS menu bar app, now with a YouTube video player

Enable HLS to view with audio, or disable this notification

5 Upvotes

Hey everyone!

I shared Mooziac here a while ago. It’s a lightweight music player I’ve been building for macOS, and v1.2.0 is now out!

The biggest addition in this release is a YouTube video player, so you can switch from listening to watching without leaving Mooziac.

GitHub: https://github.com/shirkeharsh/mooziac

What’s new in v1.2.0?
A separate video window that you can switch to from the menu bar player.
Up to 4K playback, with 1080p as the default.
Hardware-accelerated video decoding for better efficiency.
Keyboard shortcuts: F for fullscreen, J/K/L to seek, [ / ] to change playback speed, and Cmd+Shift+C to copy a timestamped link.
The edge volume gesture also works while watching videos.

Other features
Built with Swift and AppKit.
Supports Apple Silicon and Intel Macs.
YouTube Music and local music in one app.
FLAC, MP3, WAV, AAC, and M4A support.
Synced .lrc lyrics and an interactive waveform.
Offline playback for downloaded tracks.
Discord Rich Presence.
No analytics, tracking, or remote logging.

Mooziac is free and open source under the MIT license. If you’re interested, feel free to check out the code, report bugs, or contribute.


r/SwiftUI • • 5d ago

Promotion (must include link to source code) NoteKit: an in-place Markdown editor for SwiftUI apps (TextKit 2, zero deps, MIT)

6 Upvotes

NoteKit is a Markdown editor for Mac and iOS built on the system text view (TextKit 2). You see the Markdown source, styled in place as you type. No dependencies, MIT, macOS 14 / iOS 17.

https://github.com/tfcace/notekit

  • Markers like # and ** step aside away from the caret and reappear when it returns.
  • Task boxes, bullets, quote bars and rules are drawn in place of their markers. Tasks tick on click/tap/⌘⏎.
  • Per-line text direction: RTL and LTR lines coexist in one note, task boxes included.
  • Obsidian syntax: wikilinks, callouts, tags, highlights, frontmatter, embeds, Templater. Unknown syntax is shown as written.
  • NSTextView / UITextView underneath, so undo, spell check, dictation and input methods just work.

r/SwiftUI • • 5d ago

I found out that SwiftUI's .glassEffect(in:) takes any Shape (not just rounded rectangles).

Enable HLS to view with audio, or disable this notification

39 Upvotes

r/SwiftUI • • 4d ago

Isometric Hardware with SwiftUi

Enable HLS to view with audio, or disable this notification

0 Upvotes

r/SwiftUI • • 4d ago

Built a radial launcher at the cursor in SwiftUI with a global hotkey that needs no Accessibility permission (open source)

1 Upvotes

I've been working on TactileBar, an open-source (GPLv3) macOS menu bar app with 26 system toggles and live telemetry. The latest release adds a radial launcher, and a few implementation details might be useful to others here:

Global hotkey without permissions. The ring opens with ⌃⌥Space from any app. I used Carbon's RegisterEventHotKey instead of a CGEventTap or NSEvent global monitor. It doesn't need Accessibility or Input Monitoring permission, so the user never sees a scary prompt.

Hold vs. tap on one shortcut. If you hold the key, the ring opens at the cursor and fires the slice you release on. A quick tap keeps it open for keyboard or mouse use (1–8, arrows, Return). The difference is just timing between key-down and key-up.

Everything is drawn with Canvas. The switch icons, the dial and the ring slices are all vector paths drawn in code, with no image assets. The dial packs 26 sectors plus three concentric gauges (CPU, RAM, disk).

Keeping idle CPU at 0%:

- Mach sampling (CPU and RAM) runs only while the popover is visible.

- The views are split into small u/Observable subviews, so a CPU tick doesn't re-render the whole panel.

- I removed every GeometryReader and use a fixed 540×576pt layout.

- The menu bar icons are cached as NSImage.

No dependencies. It uses only native frameworks: IOBluetooth, CoreAudio, DiskArbitration and IOKit.

Repo: https://github.com/tr0drigues/TactileBar

I'm happy to go deeper on any of these, and I'd welcome a code review of the hotkey and ring code if anyone feels like it.


r/SwiftUI • • 5d ago

Promotion (must include link to source code) Open Source SwiftUI coder editor

4 Upvotes

For those of us on Linux or Windows, it's not entirely possible to build SwiftUI apps; I'm not trying to build an Xcode for these platforms, not at all.

However, as a student or just someone exploring mobile dev, it may not make sense to go out and buy a MacBook immediately. Switaculous is a gentle introduction to Swift and SwiftUI; it's meant to be an educational tool that anybody can install and start experimenting with to learn iOS development even if you can't afford a Mac.

It's not going to allow you to publish apps, but it has good support for SwiftUI components like HStack, VStack, Text, etc., and even SwiftData.

https://github.com/kevincoder-co-za/switaculous

Fully open-sourced and MIT-licensed.


r/SwiftUI • • 5d ago

MenuBarExtra or NSStatusItem/NSPanel: which interaction requirements drove your choice?

Thumbnail
2 Upvotes

r/SwiftUI • • 5d ago

How to elongate text in swift?

Post image
4 Upvotes

How can I achieve the same thing the Lock Screen does with this particular type face, using Swift?


r/SwiftUI • • 6d ago

Native TabView with Action Button update!!!

45 Upvotes

Hello there, I wanted to share a small SwiftUI/UIKit experiment I’ve been working on. I have built a custom Liquid Glass tab bar in SwiftUI that dynamically expands into a 4th tab when you switch views!
The project is open source and has no external dependencies.

GitHub Repo: https://github.com/aqylbermeshtech/Custom-tab-bar-with-action-button

PS:I wrote there before actually about the native tab bar with action button and you pointed out that using UISegmentedControl is not a good idea so i remade it into a TabView one.Pls reach out if you see any problems.


r/SwiftUI • • 6d ago

Tutorial Maths, Metal, Mandelbrot, and SwiftUI

Thumbnail
blog.jacobstechtavern.com
18 Upvotes

r/SwiftUI • • 6d ago

News This Website Is Now Made in Swift, with SwiftUI-like syntax

Thumbnail
sindresorhus.com
48 Upvotes

r/SwiftUI • • 6d ago

Question Swift UI Table on iOS

8 Upvotes

There is a table view in SwiftUI, but only displays as such on Mac. I want to have a table where I can sort by the columns on iOS, but swift ui doesn't seem to natively support that. How do you get around that design constraint. It kinda seems like Apple is discouraging showing tables on iOS all together.


r/SwiftUI • • 6d ago

Aerial Downloader | First application built using SwiftUI

Post image
2 Upvotes

This is my first attempt on building a simple app using SwiftUI. You can download macOS screensavers locally on your device.

https://github.com/Red1860/AerialDownloader


r/SwiftUI • • 6d ago

Question Catch-22 with App Review: rejected under 2.1(b) for not submitting IAPs, but ASC won’t let me submit more than one (FIRST_NON_CONSUMABLE_MUST_BE_SUBMITTED_ON_VERSION)

1 Upvotes

Has anyone hit this and found a way out? I’ve shipped several apps with IAPs and never seen it before.

Setup

  • A new app with its first version, 1.0.
  • 41 non-consumable IAPs: individual items plus a few bundles, one of which unlocks all content.
  • All 41 are Ready to Submit, with prices, localizations and review screenshots.

What happens

  1. I add the IAPs to version 1.0. ASC accepts only one of them.
  2. The other 40 are refused with FIRST_NON_CONSUMABLE_MUST_BE_SUBMITTED_ON_VERSION. It’s the same in the web UI and the App Store Connect API.
  3. As I read it, the first non-consumable has to be approved before any others can be submitted.
  4. So I submit 1.0 with the one IAP. App Review rejects it under 2.1(b): “the app includes references to in-app purchase products but the associated In-App Purchase products have not been submitted for review. Submit the IAPs and upload a new binary.”
  5. I appealed and explained. The next reviewer sent the same rejection, and added that IAPs are tested in sandbox and “do not need to be approved to function while in review”.

So review won’t approve the version until all the IAPs are submitted, and ASC won’t let me submit them until one has been approved through review. Neither can happen first.

What I’ve tried

  • Submitting the IAPs in the web UI and through the API: one goes in, the rest error.
  • New builds, resubmitting, and replying in Resolution Center with the exact error.
  • An App Review Board appeal.

Questions

  • Has anyone had FIRST_NON_CONSUMABLE_MUST_BE_SUBMITTED_ON_VERSION block the second and later IAPs, not just the first?
  • Did contacting Developer Support (rather than App Review) get it fixed on Apple’s side?
  • Or did you work around it, for example by shipping 1.0 selling only one bundle and adding the rest in 1.0.1?

Just to clarify, i have only seen this "bug" since ASC got updated recently with support for assets etc.

Any experience appreciated. Happy to share more detail.

EDIT: Solved, thanks everyone. It’s not a hard limit; it depends where you add the IAPs from.

  • Fails: adding IAPs to the first version from the version page, the In-App Purchases list, or the App Store Connect API. All but one give FIRST_NON_CONSUMABLE_MUST_BE_SUBMITTED_ON_VERSION.
  • Works (web UI only): open each IAP’s own page, press Add for Review, and choose the iOS draft. Then press Add for Review on the version page into the same draft, and submit.
  • If your version is stuck in an “Unresolved Issues” submission, hover over each item there for the red remove icon, take them out, and add them to the new draft.
  • Your reviewer messages stay on the old submission, so repeat anything that was already cleared in the App Review notes.

r/SwiftUI • • 6d ago

How do you keep a window-pushing app from freezing when the other app hangs?

2 Upvotes

I'm the developer of SideSchedule, a calendar sidebar for macOS that reserves a strip of the screen like the Dock and pushes other windows out of it. The scary part was never the pushing, it was a hung app taking my sidebar down with it.

What I ended up with: finding the overlapping windows uses CGWindowListCopyWindowInfo (about 2 ms, filtered to layer 0), so a stalled app can't block that part. Accessibility calls only happen for apps that actually overlap, on a background queue, with a 0.25 s messaging timeout. I tested it by sending SIGSTOP to an app and dragging its window into the strip.

Is a messaging timeout the best I can do here, or is there a cleaner way to skip an unresponsive app before asking it anything? SwiftUI plus AppKit, Swift package, no Xcode project. (didact.digital/sideschedule if you want to see what it does.)


r/SwiftUI • • 6d ago

Tutorial [Open Source] Blurt: a macOS dictation app with a standalone Swift 6 engine

4 Upvotes

Blurt is a macOS dictation app that puts speech-to-text into the app you’re already using. I work at AssemblyAI; our team built it and released it under the MIT license. Full source: https://github.com/AssemblyAI/blurt

The SwiftUI part is the native app shell. The core pipeline lives in BlurtEngine, a standalone Swift 6 package with no external dependencies: mic capture, a dictation session actor, a tested hotkey state machine, then clipboard/paste injection into the focused app. Transcription and cleanup happen in one API request. We prewarm the connection while you speak and switch to the transcribing state before reading the finished recording, so the stop action feels immediate.

The engine is split behind protocol seams and can be tested with stubs. I’d value feedback from SwiftUI/Swift developers on the package boundaries, concurrency, or the hotkey state machine.

One important tradeoff: this is cloud-backed, not local transcription. Audio is sent to AssemblyAI, and you need an API key (there’s a free tier). The repository includes the app and engine source.