openExampleSentenceDialog method

Future<void> openExampleSentenceDialog(
  1. {required List<String> exampleSentences,
  2. required dynamic onSelect(
    1. List<String>
    ),
  3. dynamic onAppend(
    1. List<String>
    )?}
)

A helper function for opening an example sentence dialog.

Implementation

Future<void> openExampleSentenceDialog({
  required List<String> exampleSentences,
  required Function(List<String>) onSelect,
  Function(List<String>)? onAppend,
}) async {
  await showDialog(
    context: _navigatorKey.currentContext!,
    builder: (context) => ExampleSentencesDialogPage(
      exampleSentences: exampleSentences,
      onSelect: onSelect,
      onAppend: onAppend,
    ),
  );
}