import { CallbackButtonTemplate } from '../keyboard'; import { ContextPathFunc, ConstOrPromise, ConstOrContextPathFunc } from '../generic-types'; import { SingleButtonOptions } from './basic'; export declare type FormatStateFunction = (context: Context, text: string, state: boolean, path: string) => ConstOrPromise; export interface ToggleOptions extends SingleButtonOptions { /** * Function returning the current state. */ readonly isSet: ContextPathFunc; /** * Function which is called when a user presses the button. */ readonly set: (context: Context, newState: boolean, path: string) => ConstOrPromise; /** * Format the button text which is visible to the user. */ readonly formatState?: FormatStateFunction; } export declare function generateToggleButton(text: ConstOrContextPathFunc, actionPrefix: string, options: ToggleOptions): ContextPathFunc;