// @ts-nocheck
import React, { memo, useCallback, useMemo } from 'react';
import { View } from 'react-native';
import isEqual from 'lodash.isequal';
import { styles } from './styles';
const BottomSheetContainerComponent = _ref => {
  let {
    shouldMeasureHeight,
    onMeasureHeight,
    children,
    topInset = 0,
    bottomInset = 0
  } = _ref;
  //#region callbacks
  const handleOnLayout = useCallback(_ref2 => {
    let {
      nativeEvent: {
        layout: {
          height
        }
      }
    } = _ref2;
    onMeasureHeight(height);
  }, [onMeasureHeight]);
  //#endregion

  const containerStyle = useMemo(() => [styles.container, {
    top: topInset,
    bottom: bottomInset
  }], [bottomInset, topInset]);

  //#region render
  // 
  return /*#__PURE__*/React.createElement(View, {
    pointerEvents: "box-none",
    style: containerStyle,
    onLayout: shouldMeasureHeight ? handleOnLayout : undefined,
    children: children
  });
  //#endregion
};

const BottomSheetContainer = /*#__PURE__*/memo(BottomSheetContainerComponent, isEqual);
export default BottomSheetContainer;
//# sourceMappingURL=BottomSheetContainer.js.map