Add hidden property in PresentationDetent #30
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hello!
First of all, I appreciate about this repository a lot. It's my life saver.
I found two things that can be improve when I use it.
Firstly, there is no hidden(close) option. So, I used
.fraction(0)instead, but I'm not the only one who wanted hidden option(who my colleague).Although, Perhaps your purpose was make exactly the same thing of SwiftUI's
sheet, but I thought it isn't intuitive.Secondly, the
@State(or @Published) var isPresentedthat is outside ofBottomSheet, isn't change tofalseby swipe down action.When close
BottonSheet,isPresentedis stilltrue, and never open again next time.So, I added the
hiddenproperty and changed few lines.Please consider merging my PR if you don't mind.
Thank you once again.
ps. As my english writing skill, I have attached images that what's changed.
Before
before.MP4
After
after.MP4