mirror of
https://github.com/hexastack/hexabot
synced 2025-06-26 18:27:28 +00:00
fix(frontend): add dialog extra props
This commit is contained in:
@@ -9,8 +9,12 @@
|
||||
import { DialogProps as MuiDialogProps } from "@mui/material";
|
||||
import { BaseSyntheticEvent } from "react";
|
||||
|
||||
interface ConfirmDialogExtraOptions {
|
||||
mode?: "click" | "selection";
|
||||
count?: number;
|
||||
}
|
||||
// context
|
||||
export interface OpenDialogOptions<R> {
|
||||
export interface OpenDialogOptions<R> extends ConfirmDialogExtraOptions {
|
||||
/**
|
||||
* A function that is called before closing the dialog closes. The dialog
|
||||
* stays open as long as the returned promise is not resolved. Use this if
|
||||
@@ -129,6 +133,7 @@ export interface DialogStackEntry<P, R> {
|
||||
payload: P;
|
||||
onClose: (result: R) => Promise<void>;
|
||||
resolve: (result: R) => void;
|
||||
msgProps: ConfirmDialogExtraOptions;
|
||||
}
|
||||
|
||||
export interface DialogProviderProps {
|
||||
|
||||
Reference in New Issue
Block a user