Skip to content

Commit 2f0dac8

Browse files
Merge branch 'ammarahm-ed:master' into master
2 parents dfc25a8 + b28c080 commit 2f0dac8

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

src/hooks/use-scroll-handlers.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,7 @@ export function useScrollHandlers<T>(options?: DraggableNodeOptions) {
120120
timer.current = setTimeout(() => {
121121
const ref = resolveScrollRef(nodeRef);
122122
if (Platform.OS == 'web') {
123+
if (!ref) return;
123124
const rect = (ref as HTMLDivElement).getBoundingClientRect();
124125
(ref as HTMLDivElement).style.overflow = "auto";
125126
onMeasure(rect.x, rect.y, rect.width, rect.height, rect.left, rect.top);

src/types.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import {
55
LayoutRectangle,
66
TouchableOpacityProps,
77
ViewStyle,
8+
StyleProp,
89
} from 'react-native';
910
import EventManager from './eventmanager';
1011
import {Route} from './hooks/use-router';
@@ -182,7 +183,7 @@ export type ActionSheetProps<SheetId extends keyof Sheets = never> = {
182183
/**
183184
* Style the top indicator bar in ActionSheet.
184185
*/
185-
indicatorStyle?: ViewStyle;
186+
indicatorStyle?: StyleProp<ViewStyle>;
186187

187188
/**
188189
* Color of the overlay/backdrop.
@@ -206,7 +207,7 @@ export type ActionSheetProps<SheetId extends keyof Sheets = never> = {
206207
/**
207208
* Any custom styles for the container.
208209
* */
209-
containerStyle?: ViewStyle;
210+
containerStyle?: StyleProp<ViewStyle>;
210211

211212
/**
212213
* Control closing ActionSheet by touching on backdrop.

0 commit comments

Comments
 (0)