Merge remote-tracking branch 'origin/hailey/dialogs-pt1' into hailey/dialogs-pt6
This commit is contained in:
@@ -35,7 +35,6 @@ export function Outer({
|
|||||||
const insets = useSafeAreaInsets()
|
const insets = useSafeAreaInsets()
|
||||||
const closeCallbacks = React.useRef<(() => void)[]>([])
|
const closeCallbacks = React.useRef<(() => void)[]>([])
|
||||||
const {setDialogIsOpen} = useDialogStateControlContext()
|
const {setDialogIsOpen} = useDialogStateControlContext()
|
||||||
// @TODO DIALOG REFACTOR - can i get rid of this? seems pointless tbh
|
|
||||||
|
|
||||||
const callQueuedCallbacks = React.useCallback(() => {
|
const callQueuedCallbacks = React.useCallback(() => {
|
||||||
for (const cb of closeCallbacks.current) {
|
for (const cb of closeCallbacks.current) {
|
||||||
@@ -83,20 +82,12 @@ export function Outer({
|
|||||||
[open, close],
|
[open, close],
|
||||||
)
|
)
|
||||||
|
|
||||||
// @TODO DIALOG REFACTOR - what is this? rm i think?
|
|
||||||
// React.useEffect(() => {
|
|
||||||
// return () => {
|
|
||||||
// setDialogIsOpen(control.id, false)
|
|
||||||
// }
|
|
||||||
// }, [control.id, setDialogIsOpen])
|
|
||||||
|
|
||||||
const context = React.useMemo(() => ({close}), [close])
|
const context = React.useMemo(() => ({close}), [close])
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Portal>
|
<Portal>
|
||||||
<Context.Provider value={context}>
|
<Context.Provider value={context}>
|
||||||
<BlueskyBottomSheetView
|
<BlueskyBottomSheetView
|
||||||
// handleIndicatorStyle={{backgroundColor: t.palette.primary_500}} // @TODO DIALOG REFACTOR need to add this to lib!*/
|
|
||||||
ref={ref}
|
ref={ref}
|
||||||
topInset={30}
|
topInset={30}
|
||||||
bottomInset={insets.bottom}
|
bottomInset={insets.bottom}
|
||||||
|
|||||||
@@ -229,10 +229,6 @@ export const InnerFlatList = React.forwardRef<
|
|||||||
)
|
)
|
||||||
})
|
})
|
||||||
|
|
||||||
export function Handle() {
|
|
||||||
return null
|
|
||||||
}
|
|
||||||
|
|
||||||
export function Close() {
|
export function Close() {
|
||||||
const {_} = useLingui()
|
const {_} = useLingui()
|
||||||
const {close} = React.useContext(Context)
|
const {close} = React.useContext(Context)
|
||||||
|
|||||||
Reference in New Issue
Block a user