Repository navigation
v0.106.0
A minor release: Select can present its sheet as the platform's own, and the sheet's options scroll properly on Android.
Added
-
Select —
sheetPropssets how thesheetpresentation draws its sheet.sheetProps.nativepresents the platform's own sheet, SwiftUI on iOS and Jetpack Compose on Android, so it gets the system's detents, dismiss gesture and material.snapPointssets the detents andnativeBackgroundpaints a solid surface instead of the translucent material. Only the container is the platform's: the options inside are still the select's own, so groups, disabled options andsearchablekeep working. In a sheet with detents the list fills the first one and scrolls inside it.sizegives the sheet a fixedhalforfullheight in either form. The native sheet needs the optional@expo/uipackage; without it the styled sheet is shown.SelectSheetPropsis exported. Requested by @MiddleKerb in #230.<Select value={value} onValueChange={setValue} title="Time zone" sheetProps={{ native: true, snapPoints: ['half', 'full'], nativeBackground: true }} > <Select.Item value="a" label="Option A" /> <Select.Item value="b" label="Option B" /> </Select>
Changed
- BottomSheet —
BottomSheet.Bodyturns off Android's overscroll effect by default. At the top of the list a pull moves the sheet, and the effect drew the content stretching inside a sheet that was already moving. PassoverScrollModeto bring it back.
Fixed
- Select — on Android, swiping over the options in the
sheetpresentation dragged the whole sheet up or down instead of scrolling the list. The options were in a plain scroller the sheet's drag knew nothing about, so whichever gesture started first kept the touch. They now scroll inBottomSheet.Body: the list scrolls until it reaches its top, and pulling down from there drags the sheet. Reported by @MiddleKerb in #231. - BottomSheet —
BottomSheet.Bodyand the sheet now agree about which drags belong to which:- A fast flick back up a scrolled list no longer closes the sheet, and the haptic no longer fires at the end of every scroll.
- An upward drag over the list scrolls it, rather than lifting the sheet as the list starts to move.
- While the sheet is being dragged, the list holds still instead of scrolling under it.
- On Android a scroll no longer stops when the finger moves outside the list.
Upgrading
npm install panelui-native@0.106.0Nothing changes for existing code. If you relied on Android's overscroll effect inside a BottomSheet.Body, pass overScrollMode="auto".