Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create bottom sheet with item binding #16

Merged
merged 2 commits into from
Mar 20, 2022

Conversation

4brunu
Copy link
Contributor

@4brunu 4brunu commented Mar 20, 2022

This PR fixes #13.

With this PR, it is now possible to show/hide the Botton sheet based on an item being nil or not.

@State var presentedLocation: Location?

.bottomSheet(item: $presentedLocation, height: 700) { place in
   SelectedBusinessSheet(selectedBusiness: place)
}

This is similar to https://developer.apple.com/documentation/swiftui/form/sheet(item:ondismiss:content:)

@weitieda weitieda merged commit b924a83 into weitieda:master Mar 20, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Unable to mimic .sheet usage for project.
2 participants