Show newer

i’m pleased to report you can make the iPhone simulator gay now

Man, NavigationSplitView is *still* broken in iOS 17 beta 7.

I reported back in May (FB12178616) that when in compact mode transitions become sporadic and stop working. This code is verbatim from Apple’s docs and it doesn't work.

This broke back in iOS 16.2. It seems nuts to me something so significant can stay broken for this long (and on a relatively new API?!)

gist.github.com/phillipcaudell

This doesn't seem that intuitive at first, but if you think about it, how would SwiftUI anticipate what action will be performed on your model?

In iOS 17 the animation has been improved considerably if you don't explicitly set the role, but for best results you still need to set it.

Show thread

I recently got downvoted into oblivion for explaining why someone's List animation was glitching, perhaps because the solution is so simple it seems stupid.

On the left is swipeAction with a Button. On the right is the exact same Button, but now the animation is smooth.

The difference? I set the Button's role to destructive. SwiftUI uses the role to infer what animation to use. gist.github.com/phillipcaudell

live scenes of me keeping all size classes and platforms working from a single target

As of beta 6 it seems to be reporting the wrong value if more than one row is selected on iPad.

I've filed a feedback for any Apple folk who see this 👉 FB13014204

Show thread

Happy to see iOS 17 now gives our views a way to respond to the List selection style.

By reading the backgroundProminence value in the environment our custom controls, say an unread indicator, can adjust their tint as not to be occluded by the background: gist.github.com/phillipcaudell

Blahhh, it also looks like toolbar customisations are reset when the view identity changes. It works on iPad so I’m not sure if it's intentional (plus seems like it would defeat the purpose of specifying a toolbar identifier?)

No customisation on the Mac for now then 😢

gist.github.com/phillipcaudell

Show thread

Here's a fun SwiftUI bug: customisable toolbars on the Mac won't persist changes if there's a searchable modifier in the view hierarchy. Remove search, works fine.

🤷‍♂️

gist.github.com/phillipcaudell (FB12999760)

I'm stumped on how to add an undo keyboard shortcut on iPad. I'm using the environment's UndoManager. On the Mac, Undo appears in the Edit menu and "just works”.

I tried adding my own button, but UIKit throws a messaging saying it's duplicate, so I assume there is one but it's hidden?

Any ideas would be very much appreciated!

I wrongly assumed the format panel used in Mail was a system control like it is on macOS; but alas it isn't!

It ended up being a lot of fun recreating it, including the silly stretching/rubber-banding when you pull it.

Show thread

Apologies for the slowdown in new beta builds/invites. I bit off way more than I could chew redoing the editor + iPad support 😅

That said I’m really pleased with how the new editor has turned out. I've added rich text formatting, inline attachments and document scanning.

New build coming soon 💌

Has anyone got openWindow to work on iPadOS from the Command menu? Console throws "Use of OpenWindowAction requires the SwiftUI App Lifecycle" (the whole app is). Button works fine when inside a View (and works on Mac)

Can anyone recommend a decent static site generator?

I used to use Jekyll, but maintaining a working Ruby installation is nigromancy I never mastered.

You haven't LIVED until you've spent an hour trying to wrestle your dog to get a wasp’s stinger out of their paw.

The good news is she's fine ❤️

The bad news is my face and arms are not.

It's a shame DocC doesn't yet support multiple targets; it would make splitting things up much easier.

At least it’s being discussed: forums.swift.org/t/combined-do

Show thread

Thinking of open-sourcing the framework used to build Big Mail/Big News. It recreates a bunch of ‘missing’ system UI components (toasts, menus, pickers, etc), and has some common patterns for navigation, styling, etc.

It's one package right now (BigSwiftUI) but I'm torn whether to split it up into smaller packages.

Anyone interested in a package like this? Split it up or no?

Show older
The Not So Big Company

The home of The Not So Big Company on Mastodon.