Post

Replies

Boosts

Views

Activity

Reply to Couple questions about NavigationSplitView in SwiftUI
Selection: You need maintain a @State variable for selection and pass it to List's selection parameter as a binding To restore selection state across app launches use @SceneStorage All you need is shown in the video link below, watch it slowly and understand the concepts Console Warnings onChange(of: UpdateTrigger) action tried to update multiple times per frame A NavigationLink is presenting a value of type "Category" but there is no matching navigation destination visible from the location of the link. The link cannot be activated. Feedback has been submitted for the above mentioned warnings and Apple Engineers are aware of this bug, so you can ignore it for now MacOS Sidebar You can tap on the sidebar button to open the sidebar I think there is an option in NavigationSplitView configuration, you need to check the documentation columnVisibility but I haven't mentioned to get it working Reference: Please watch https://developer.apple.com/wwdc22/10054 It has sample code to do exactly what you want (you can copy code by clicking on the code tab)
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Jun ’22
Reply to Bookmark or watch forum thread?
Thanks a lot Quinn!!! The following don't seem to be working for me: Upvoting an answer, shows as upvoted but when I signout the upvote doesn't show as upvoted Email notification as mentioned above don't work even selected Also it would be nice to have email notifications checked by default for the question you ask, as most people would expect that by default. IMHO improving the website can directly improve the engagement with in the developers as more people will use the forums and more questions would get asked and answered.
Jun ’22
Reply to Swift Concurrency (async let) - Cancellation
@Claude31 Thanks, that makes sense, had a skewed understanding, I think I understand better now, thanks!
Topic: Programming Languages SubTopic: Swift Tags:
Replies
Boosts
Views
Activity
Dec ’21
Reply to Drag (and drop) in SwiftUI List with children on macOS
Instead of onDrag you could do the following: Row(entry: $0) .itemProvider { //Return some NSItemProvider representing your row content }
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
Jan ’22
Reply to NavigationStack and NavigationSplitView Runtime warnings
Based on the Apple Engineer's response this is a bug, I have also filed feedback and mentioned it.
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
Jun ’22
Reply to How to set the holding priority with NavigationSplitView
Could you check https://developer.apple.com/documentation/swiftui/view/navigationsplitviewcolumnwidth(_:)
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
Jun ’22
Reply to Any xcode code samples for live activity on ios16?
I think it should be part of widgetkit. Might be worth checking out widget kit sessions in wwdc22
Replies
Boosts
Views
Activity
Jun ’22
Reply to Couple questions about NavigationSplitView in SwiftUI
Selection: You need maintain a @State variable for selection and pass it to List's selection parameter as a binding To restore selection state across app launches use @SceneStorage All you need is shown in the video link below, watch it slowly and understand the concepts Console Warnings onChange(of: UpdateTrigger) action tried to update multiple times per frame A NavigationLink is presenting a value of type "Category" but there is no matching navigation destination visible from the location of the link. The link cannot be activated. Feedback has been submitted for the above mentioned warnings and Apple Engineers are aware of this bug, so you can ignore it for now MacOS Sidebar You can tap on the sidebar button to open the sidebar I think there is an option in NavigationSplitView configuration, you need to check the documentation columnVisibility but I haven't mentioned to get it working Reference: Please watch https://developer.apple.com/wwdc22/10054 It has sample code to do exactly what you want (you can copy code by clicking on the code tab)
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
Jun ’22
Reply to Bookmark or watch forum thread?
Thanks a lot Quinn!!! The following don't seem to be working for me: Upvoting an answer, shows as upvoted but when I signout the upvote doesn't show as upvoted Email notification as mentioned above don't work even selected Also it would be nice to have email notifications checked by default for the question you ask, as most people would expect that by default. IMHO improving the website can directly improve the engagement with in the developers as more people will use the forums and more questions would get asked and answered.
Replies
Boosts
Views
Activity
Jun ’22
Reply to How to make sticky card like in Apple Music
I think What's new in SwiftUI talk explains this https://developer.apple.com/wwdc22/10052 (11:39) https://developer.apple.com/documentation/swiftui/radialgradient/presentationdetents(_:)
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
Jun ’22
Reply to NSSecureCoding allowed classes list
I have filed a feedback FB9793368 DTS has confirmed this is a bug, hope it gets fixed, fingers crossed
Replies
Boosts
Views
Activity
Jun ’22
Reply to Reset the detail view on NavigationSplitView 3-column when a new Sidebar item is selected, but no content item
Remove Selection Can you set selectedRecipe = nil, that should remove any selection of the recipe. Selection of recipe is driven by the state variable selectedRecipe so depending on the value different recipes Reference: https://developer.apple.com/documentation/swiftui/list
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
Jun ’22
Reply to Large overlay
Use a ZStack instead of overlay ZStack { Text("Hello, world!") .padding() Rectangle() .fill(.red) }
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
Jun ’22
Reply to List-like Selection for custom containers
I am not sure I understand your question correctly, contextMenu could be added to any custom view struct ContentView: View { var body: some View { Text("Hello, world!") .padding() .contextMenu { Button("aaa") {} } } }
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
Jun ’22
Reply to Is it possible to set default height proportions of embedded views in VSplitView (MacOS)
You could add .frame modifier to set any height
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
Jun ’22
Reply to Xcode Cloud not loading anymore
I am getting the "Could not load Xcode Cloud data" on macOS Monterey (12.5 Beta (21G5037d))
Replies
Boosts
Views
Activity
Jun ’22
Reply to Xcode Cloud Fails to build: Command exited with non-zero exit-code: 70
My scenario I had merged a lot of changes from a branch (pull request) I had also made changes to the swift package Problem Export archive for app-store distribution Command exited with non-zero exit-code: 70 Solution / Workaround Cleared DerivedData Cloned the project in a disk location
Replies
Boosts
Views
Activity
Jun ’22