class AnyFormattedText = '', description: str = '', separator: bool = False, handler: Callable[[], None] | None = None, children: list[MenuItem] | None = None, shortcut: AnyFormattedText = '', hidden: FilterOrBool = False, disabled: FilterOrBool = False, toggled: Filter | None = None, collapse_prefix: bool = False, collapse_suffix: bool = True)

A prompt-toolkit compatible menu item with more advanced capabilities.

It can use a function to generate formatted text to display, display a checkmark if a condition is true, and disable the handler if a condition is met.