theluyuan 38ba663466
Some checks failed
Close stale issues and PRs / stale (push) Has been cancelled
init
2025-09-02 14:49:16 +08:00

22 lines
702 B
TypeScript

import { openDialog } from '../base/dialog/actions';
import { DisplayNamePrompt } from './components';
/**
* Signals to open a dialog with the {@code DisplayNamePrompt} component.
*
* @param {Object} params - Map containing the callbacks to be executed in the prompt:
* - onPostSubmit - The function to invoke after a successful submit of the dialog.
* - validateInput - The function to invoke after a change in the display name value.
* @returns {Object}
*/
export function openDisplayNamePrompt({ onPostSubmit, validateInput }: {
onPostSubmit?: Function;
validateInput?: Function;
}) {
return openDialog(DisplayNamePrompt, {
onPostSubmit,
validateInput
});
}