Something went wrong. Try again.
Bluesky app fork with some witchin' additions 💫 forked from jollywhoppers.com/witchsky.app
Something went wrong. Try again.
12345678910111213141516171819202122232425262728293031323334353637import {type BottomSheetPopoverMode} from '../../../modules/bottom-sheet'
/** * Content-sized sheet measurement is needed on iPad to avoid measuring the * full-height canvas, and for iOS popovers (including their compact-width * sheet adaptations) so the presentation sizes itself to the dialog content. */export function shouldMeasureDialogContentHeight({ isIOS, isIPad, popover = 'never',}: { isIOS: boolean isIPad: boolean popover?: BottomSheetPopoverMode}) { return isIPad || (isIOS && popover !== 'never')}
/** * Returns the measured intrinsic height only for dialogs that opt into the * JavaScript measurement path. */export function getMeasuredDialogContentHeight({ shouldMeasureContentHeight, contentHeight, footerHeight,}: { shouldMeasureContentHeight: boolean contentHeight: number footerHeight: number}) { return shouldMeasureContentHeight && contentHeight > 0 ? contentHeight + footerHeight : undefined}