@teamsparta/stack-bottom-sheet
Version:
stack bottom sheet
42 lines (39 loc) • 1.77 kB
TypeScript
import * as _emotion_react_types_jsx_namespace from '@emotion/react/types/jsx-namespace';
import { ThemeName } from '@teamsparta/stack-tokens';
import { DialogProps } from 'vaul';
type BottomSheetRootProps = DialogProps & {
/**
* 바텀시트 외부 클릭 시 모달을 닫을지 여부
* @default true
*/
closeOnInteractOutside?: boolean;
/**
* 테마 이름
*/
theme?: ThemeName;
/**
* 바텀시트 헤더 오른쪽에 닫기 버튼을 숨길지 여부
* @default false
*/
hideCloseButton?: boolean;
/**
* 컨텐츠 외부 영역 클릭이나 Grabber를 통해 바텀시트를 닫을지 여부
* @description true라면 `Grabber`가 자동으로 표시되며, false라면 `Grabber`가 표시되지 않습니다.
* false라면 `Grabber`, `CloseButton` 모두 표시되지 않습니다.
* @default true
*/
dismissible?: boolean;
/**
* `Grabber`를 통해서만 바텀시트를 닫을지 여부
* @default true
*/
handleOnly?: boolean;
/**
* vaul 라이브러리의 `dismissible` 속성
* @description 이 속성을 false로 설정하면 제어 컴포넌트 형태로 사용하거나, 새로고침을 통해서만 바텀시트를 닫을 수 있습니다.
* @default true
*/
VAUL_DISMISSIBLE?: boolean;
};
declare const BottomSheetRoot: ({ children, open: openFromProps, onOpenChange: onOpenChangeFromProps, defaultOpen: defaultOpenFromProps, closeOnInteractOutside, theme: themeFromProps, hideCloseButton, handleOnly, dismissible, repositionInputs, VAUL_DISMISSIBLE, ...restProps }: BottomSheetRootProps) => _emotion_react_types_jsx_namespace.EmotionJSX.Element;
export { BottomSheetRoot, type BottomSheetRootProps };