import type { NonLinkButtonComponentBuilder, AdaptorButtonInteraction } from "../../adaptor"; import type { UseModalParam } from "../effect/useModal"; export type UseModalComponentParam = UseModalParam & { filter?: (interaction: Readonly) => boolean; }; export type UseModalComponentResult = [ result: Record | null, Button: NonLinkButtonComponentBuilder<{ customId: string; }> ]; /** * モーダルを開くボタンとモーダルの結果を返すrenderHook * @param onSubmit モーダルの結果が返ってきたときに実行されるハンドラ * @param title モーダルのタイトル * @param components モーダルに表示するコンポーネント * @param filter interactionに反応するかどうかのフィルタ falseを返すとdeferUpdateとonClickは実行されない * @returns [result, NonLinkButtonComponentBuilder] */ export declare const useModalComponent: ({ onSubmit, title, components, filter, }: UseModalComponentParam) => UseModalComponentResult; //# sourceMappingURL=useModalComponent.d.ts.map